From 5f891a829d627e96a5d11a4ebdf833e47ddfa902 Mon Sep 17 00:00:00 2001 From: Baptiste Daroussin Date: Mon, 22 Nov 2021 10:36:38 +0100 Subject: ports-mgmt/portconfig: new port portconfig is a dialog4ports replacement based on libbsddialog. Note this version is build as semi static: libbsddialog and libncurses has been linked statically and the binary remaind dynamic --- ports-mgmt/Makefile | 1 + ports-mgmt/portconfig/Makefile | 20 ++++++++++++++ ports-mgmt/portconfig/distinfo | 3 ++ ports-mgmt/portconfig/files/patch-Makefile | 44 ++++++++++++++++++++++++++++++ ports-mgmt/portconfig/pkg-descr | 3 ++ 5 files changed, 71 insertions(+) create mode 100644 ports-mgmt/portconfig/Makefile create mode 100644 ports-mgmt/portconfig/distinfo create mode 100644 ports-mgmt/portconfig/files/patch-Makefile create mode 100644 ports-mgmt/portconfig/pkg-descr diff --git a/ports-mgmt/Makefile b/ports-mgmt/Makefile index 5335572f8524..c60dd0df16f2 100644 --- a/ports-mgmt/Makefile +++ b/ports-mgmt/Makefile @@ -40,6 +40,7 @@ SUBDIR += port-maintenance-tools SUBDIR += portal SUBDIR += portconf + SUBDIR += portconfig SUBDIR += portdowngrade SUBDIR += portest SUBDIR += portfind diff --git a/ports-mgmt/portconfig/Makefile b/ports-mgmt/portconfig/Makefile new file mode 100644 index 000000000000..fb4dc4a14ffd --- /dev/null +++ b/ports-mgmt/portconfig/Makefile @@ -0,0 +1,20 @@ +PORTNAME= portconfig +PORTVERSION= 0.0.0.g20211122 +CATEGORIES= ports-mgmt + +MAINTAINER= bapt@FreeBSD.org +COMMENT= Utility to set up FreeBSD port options + +LICENSE= BSD2CLAUSE + +USE_GITLAB= yes +GL_ACCOUNT= alfix +GL_COMMIT= 49d968fbd5f8285b53f3527708e45544dd456c48 + +USES= localbase:ldflags +BUILD_DEPENDS= ${LOCALBASE}/lib/libbsddialog.a:devel/bsddialog + +PLIST_FILES= bin/${PORTNAME} + +.include + diff --git a/ports-mgmt/portconfig/distinfo b/ports-mgmt/portconfig/distinfo new file mode 100644 index 000000000000..ce5f3365f263 --- /dev/null +++ b/ports-mgmt/portconfig/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1637570379 +SHA256 (alfix-portconfig-49d968fbd5f8285b53f3527708e45544dd456c48_GL0.tar.gz) = 853f0675094bb3e286b2f35bd634bf7861e6c238a6ea81fd41d57f6c2c9e122f +SIZE (alfix-portconfig-49d968fbd5f8285b53f3527708e45544dd456c48_GL0.tar.gz) = 201781 diff --git a/ports-mgmt/portconfig/files/patch-Makefile b/ports-mgmt/portconfig/files/patch-Makefile new file mode 100644 index 000000000000..a941e545f7ae --- /dev/null +++ b/ports-mgmt/portconfig/files/patch-Makefile @@ -0,0 +1,44 @@ +--- Makefile.orig 2021-11-20 16:29:49 UTC ++++ Makefile +@@ -6,23 +6,22 @@ + OUTPUT= portconfig + SOURCES= portconfig.c + OBJECTS= ${SOURCES:.c=.o} +-LIBPATH= ${.CURDIR}/bsddialog/lib + LIBBSDDIALOG= ${LIBPATH}/libbsddialog.so + +-CFLAGS= -Wall -I${LIBPATH} +-LDFLAGS= -Wl,-rpath=${LIBPATH} -L${LIBPATH} -lbsddialog ++CFLAGS+= -Wall ++LDFLAGS+= -L/usr/lib -Wl,-Bstatic -v -Wl,-whole-archive -lbsddialog -Wl,-no-whole-archive -lformw -lncursesw -ltinfow -Wl,-Bdynamic -Wl,--export-dynamic + +-BINDIR= /usr/local/bin ++BINDIR= ${PREFIX}/bin + MAN= ${OUTPUT}.1 + GZIP= gzip -cn +-MANDIR= /usr/local/share/man/man1 ++MANDIR= ${PREFIX}/share/man/man1 + + INSTALL= install + RM= rm -f + + all : ${OUTPUT} + +-${OUTPUT}: ${LIBBSDDIALOG} ${OBJECTS} ++${OUTPUT}: ${OBJECTS} + ${CC} ${LDFLAGS} ${OBJECTS} -o ${.PREFIX} + + ${LIBBSDDIALOG}: +@@ -36,9 +35,9 @@ ${LIBBSDDIALOG}: + ${CC} ${CFLAGS} -c ${.IMPSRC} -o ${.TARGET} + + install: +- ${INSTALL} -s -m 555 ${OUTPUT} ${BINDIR} +- ${GZIP} ${MAN} > ${MAN}.gz +- ${INSTALL} -m 444 ${MAN}.gz ${MANDIR} ++ ${INSTALL} -s -m 555 ${OUTPUT} ${DESTDIR}${BINDIR} ++ #${GZIP} ${MAN} > ${MAN}.gz ++ #${INSTALL} -m 444 ${MAN}.gz ${MANDIR} + + unistall: + ${RM} ${BINDIR}/${OUTPUT} diff --git a/ports-mgmt/portconfig/pkg-descr b/ports-mgmt/portconfig/pkg-descr new file mode 100644 index 000000000000..e33644fa4d5b --- /dev/null +++ b/ports-mgmt/portconfig/pkg-descr @@ -0,0 +1,3 @@ +Utility to set up FreeBSD ports options + +WWW: https://gitlab.com/alfix/portconfig -- cgit v1.2.3