Update to the latest commit

- Point MASTER_SITES to FreeBSD's servers as we seem to have to host the
  distfile on our own (I wasn't able to find a way to get a tarball from
  upstream servers). Also, add a "regenerate-distfile" target to ease
  the process of updating the distfile in the future.
- Update MAKE_ARGS: setting CC there is no longer needed.
- Remove config.mk patches: it is sufficient for the sake of the port to
  just remove the include statement from the Makefile.

Changelog:
https://git.suckless.org/quark/log.html

Reported by:	BieHDC
This commit is contained in:
Mateusz Piotrowski 2019-10-20 12:10:52 +00:00
parent d48cca8e1e
commit 503bc183b1
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=514890
3 changed files with 21 additions and 21 deletions

View File

@ -1,11 +1,11 @@
# $FreeBSD$
PORTNAME= quark
DISTVERSION= g20180403
DISTVERSION= g20190923
CATEGORIES= www
MASTER_SITES= https://git.suckless.org/quark/snapshot/
MASTER_SITES= https://people.freebsd.org/~0mp/distfiles/
PKGNAMESUFFIX= -server
DISTNAME= quark-ba38b0969f542e6e7d3f01ba500189a81ca32355
DISTNAME= ${PKGNAME}
MAINTAINER= 0mp@FreeBSD.org
COMMENT= Small and simple HTTP GET/HEAD-only web server for static content
@ -15,7 +15,7 @@ LICENSE_FILE= ${WRKSRC}/LICENSE
CONFLICTS_INSTALL= quark
MAKE_ARGS= CC=${CC} MANPREFIX=${PREFIX}/man
MAKE_ARGS= MANPREFIX=${PREFIX}/man
PLIST_FILES= bin/quark \
man/man1/quark.1.gz
@ -27,10 +27,15 @@ PLIST_FILES= bin/quark \
CFLAGS+= -D_WITH_DPRINTF
.endif
COMMIT_HASH= 3c7049e9063edebbd1934178f263f9f3c9b8ddf5
pre-everything::
@${ECHO_MSG} "You can build quark with your own config.h using the QUARK_CONF knob:"
@${ECHO_MSG} "make QUARK_CONF=/path/to/quark/config.h install clean"
do-patch:
${REINPLACE_CMD} -e '/^include config.mk$$/d' ${WRKSRC}/Makefile
post-patch:
.if defined(QUARK_CONF)
@${ECHO_MSG} "Creating config.h from ${QUARK_CONF}"
@ -40,4 +45,13 @@ post-patch:
post-install:
@${STRIP_CMD} ${STAGEDIR}${PREFIX}/bin/quark
regenerate-distfile:
${RM} -r -- ${PKGNAME}
git clone -n https://git.suckless.org/quark ${PKGNAME}
git -C ${PKGNAME} checkout ${COMMIT_HASH}
${RM} -r -- ${PKGNAME}/.git
${TAR} -czf ${PKGNAME}.tar.gz ${PKGNAME}
scp ${PKGNAME}.tar.gz 0mp@freefall.freebsd.org:~/public_html/distfiles
${RM} -r -- ${PKGNAME} ${PKGNAME}.tar.gz
.include <bsd.port.mk>

View File

@ -1,3 +1,3 @@
TIMESTAMP = 1525286635
SHA256 (quark-ba38b0969f542e6e7d3f01ba500189a81ca32355.tar.gz) = 33764d0179cc803b99487a9eac67a0e46c555c394ede636f0868a37464a4251f
SIZE (quark-ba38b0969f542e6e7d3f01ba500189a81ca32355.tar.gz) = 13256
TIMESTAMP = 1571571885
SHA256 (quark-server-g20190923.tar.gz) = 3c50e52d8e6f8f939cd02e3a94368a22c3f723606b7c486bb30cec8f1dc09b5e
SIZE (quark-server-g20190923.tar.gz) = 14101

View File

@ -1,14 +0,0 @@
--- config.mk.orig 2018-04-02 23:23:00 UTC
+++ config.mk
@@ -8,9 +8,8 @@ PREFIX = /usr/local
MANPREFIX = $(PREFIX)/share/man
# flags
-CPPFLAGS = -DVERSION=\"$(VERSION)\" -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=700 -D_BSD_SOURCE
-CFLAGS = -std=c99 -pedantic -Wall -Wextra -Os
-LDFLAGS = -s
+CPPFLAGS += -DVERSION=\"$(VERSION)\" -D_DEFAULT_SOURCE -D_XOPEN_SOURCE=700 -D_BSD_SOURCE
+CFLAGS += -std=c99 -pedantic -Wall -Wextra
# compiler and linker
CC = cc