Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 23 Nov 2021 13:58:41 GMT
From:      Baptiste Daroussin <bapt@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: 56641e180807 - main - devel/bsddialog: new port
Message-ID:  <202111231358.1ANDwfui085964@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by bapt:

URL: https://cgit.FreeBSD.org/ports/commit/?id=56641e180807833e6b073277d0bf70eea43f5300

commit 56641e180807833e6b073277d0bf70eea43f5300
Author:     Baptiste Daroussin <bapt@FreeBSD.org>
AuthorDate: 2021-11-22 09:33:43 +0000
Commit:     Baptiste Daroussin <bapt@FreeBSD.org>
CommitDate: 2021-11-23 13:58:36 +0000

    devel/bsddialog: new port
    
    bsddialog is an effort to provide a bsd 2 clause alternative to
    libdialog.
---
 devel/Makefile                           |  1 +
 devel/bsddialog/Makefile                 | 15 ++++++++
 devel/bsddialog/distinfo                 |  3 ++
 devel/bsddialog/files/patch-Makefile     | 37 ++++++++++++++++++++
 devel/bsddialog/files/patch-lib_Makefile | 60 ++++++++++++++++++++++++++++++++
 devel/bsddialog/pkg-descr                |  4 +++
 devel/bsddialog/pkg-plist                |  6 ++++
 7 files changed, 126 insertions(+)

diff --git a/devel/Makefile b/devel/Makefile
index 09095e62564a..061d03835630 100644
--- a/devel/Makefile
+++ b/devel/Makefile
@@ -296,6 +296,7 @@
     SUBDIR += busybee
     SUBDIR += byacc
     SUBDIR += byaccj
+    SUBDIR += bsddialog
     SUBDIR += c2mdoc
     SUBDIR += caf
     SUBDIR += calibrator
diff --git a/devel/bsddialog/Makefile b/devel/bsddialog/Makefile
new file mode 100644
index 000000000000..328aecbbb126
--- /dev/null
+++ b/devel/bsddialog/Makefile
@@ -0,0 +1,15 @@
+PORTNAME=	bsddialog
+PORTVERSION=	0.0.0.g20211122
+CATEGORIES=	devel
+
+MAINTAINER=	bapt@FreeBSD.org
+COMMENT=	Text User Interface Widgets
+
+LICENSE=	BSD2CLAUSE
+
+USE_GITLAB=	yes
+GL_ACCOUNT=	alfix
+GL_COMMIT=	b1d013a1c1a996ca9f6fce96c9dbc73773a8dc42
+
+.include <bsd.port.mk>
+
diff --git a/devel/bsddialog/distinfo b/devel/bsddialog/distinfo
new file mode 100644
index 000000000000..cdc4c65621dc
--- /dev/null
+++ b/devel/bsddialog/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1637570596
+SHA256 (alfix-bsddialog-b1d013a1c1a996ca9f6fce96c9dbc73773a8dc42_GL0.tar.gz) = f8cea3f70234ac49539d6c358e7af5e8e96331f40440eea0cb56851db4b50d97
+SIZE (alfix-bsddialog-b1d013a1c1a996ca9f6fce96c9dbc73773a8dc42_GL0.tar.gz) = 46830
diff --git a/devel/bsddialog/files/patch-Makefile b/devel/bsddialog/files/patch-Makefile
new file mode 100644
index 000000000000..32c94b200ada
--- /dev/null
+++ b/devel/bsddialog/files/patch-Makefile
@@ -0,0 +1,37 @@
+--- Makefile.orig	2021-11-22 01:09:04 UTC
++++ Makefile
+@@ -7,15 +7,15 @@ OUTPUT=  bsddialog
+ SOURCES= bsddialog.c
+ OBJECTS= ${SOURCES:.c=.o}
+ LIBPATH= ${.CURDIR}/lib
+-LIBBSDDIALOG= ${LIBPATH}/libbsddialog.so
++LIBBSDDIALOG= ${LIBPATH}/libbsddialog.a
+ 
+-CFLAGS= -Wall -I${LIBPATH}
+-LDFLAGS= -Wl,-rpath=${LIBPATH} -L${LIBPATH} -lbsddialog
++CFLAGS+= -Wall -I${LIBPATH}
++LDFLAGS+= -L${LIBPATH} -lbsddialog
+ 
+-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
+@@ -36,9 +36,10 @@ ${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}
++	${MAKE} -C ${LIBPATH} install
++	#${GZIP} ${MAN} > ${MAN}.gz
++	#${INSTALL} -m 444 ${MAN}.gz ${DESTDIR}${MANDIR}
+ 
+ unistall:
+ 	${RM} ${BINDIR}/${OUTPUT}
diff --git a/devel/bsddialog/files/patch-lib_Makefile b/devel/bsddialog/files/patch-lib_Makefile
new file mode 100644
index 000000000000..a915d7a81b16
--- /dev/null
+++ b/devel/bsddialog/files/patch-lib_Makefile
@@ -0,0 +1,60 @@
+--- lib/Makefile.orig	2021-11-22 01:09:04 UTC
++++ lib/Makefile
+@@ -6,6 +6,7 @@
+ VERSION = 0.1
+ LIBRARY = bsddialog
+ LIBRARY_SO = lib${LIBRARY:=.so}
++LIBRARY_A = lib${LIBRARY:=.a}
+ HEADERS = bsddialog.h bsddialog_theme.h
+ SOURCES = barbox.c editorbox.c formbox.c lib_util.c menubox.c textbox.c \
+ 	timebox.c commandbox.c filebox.c infobox.c libbsddialog.c messagebox.c \
+@@ -13,8 +14,8 @@ SOURCES = barbox.c editorbox.c formbox.c lib_util.c me
+ OBJECTS= ${SOURCES:.c=.o}
+ FBSDFLAGS= -O2 -pipe -std=gnu99 -Wno-format-zero-length \
+ 	-fstack-protector-strong -Qunused-arguments
+-CFLAGS = -I/usr/local/include -fPIC -Wall -Wextra ${FBSDFLAGS}
+-LDFLAGS = -fstack-protector-strong -shared -Wl,-x -Wl,--fatal-warnings \
++CFLAGS += -fPIC -Wall -Wextra ${FBSDFLAGS}
++LDFLAGS += -fstack-protector-strong -shared -Wl,-x -Wl,--fatal-warnings \
+ 	-Wl,--warn-shared-textrel -Wl,-soname,${LIBRARY_SO}.${VERSION} 
+ 
+ INSTALL_PREFIX=/usr/local
+@@ -43,11 +44,18 @@ RM= rm -f
+ #all : man ${LIBRARY}
+ all : ${LIBRARY}
+ 
+-${LIBRARY}: ${OBJECTS}
++${LIBRARY}: ${LIBRARY_SO} ${LIBRARY_A}
++
++${LIBRARY_SO}.${VERSION}: ${OBJECTS}
+ 	${CC} ${LDFLAGS} ${.ALLSRC} -o ${LIBRARY_SO}.${VERSION}
+-	# LN for devel
++
++${LIBRARY_SO}: ${LIBRARY_SO}.${VERSION}
+ 	${LN} ${LIBRARY_SO}.${VERSION} ${LIBRARY_SO}
+ 
++${LIBRARY_A}: ${OBJECTS}
++	${AR} cr ${.TARGET} ${OBJECTS}
++	${RANLIB} ${.TARGET}
++
+ .c.o:
+ 	${CC} ${CFLAGS} -c ${.IMPSRC} -o ${.TARGET}
+ 
+@@ -59,11 +67,12 @@ clean:
+ 
+ 
+ install:
+-	${CP} ${LIBRARY}.h ${INSTALL_PREFIX}/include
+-	${CP} ${LIBRARY_SO}.${VERSION} ${INSTALL_PREFIX}/lib/
+-	${LN} ${INSTALL_PREFIX}/lib/${LIBRARY_SO}.${VERSION} ${INSTALL_PREFIX}/lib/${LIBRARY_SO}
+-	${LDCONFIG} ${INSTALL_PREFIX}/lib
+-	${CP} ${LIBRARY}.3.gz ${INSTALL_PREFIX}/man/man3/
++	${INSTALL} -m 644 ${HEADERS} ${DESTDIR}${INSTALL_PREFIX}/include
++	${INSTALL} -m 644 -s ${LIBRARY_SO}.${VERSION} ${DESTDIR}${INSTALL_PREFIX}/lib/
++	${INSTALL} -l rs ${DESTDIR}${INSTALL_PREFIX}/lib/${LIBRARY_SO}.${VERSION} ${DESTDIR}${INSTALL_PREFIX}/lib/${LIBRARY_SO}
++	${INSTALL} -m 644 ${LIBRARY_A} ${DESTDIR}/${INSTALL_PREFIX}/lib
++	#${LDCONFIG} ${INSTALL_PREFIX}/lib
++	#${CP} ${LIBRARY}.3.gz ${INSTALL_PREFIX}/man/man3/
+ 
+ unistall:
+ 	${RM} ${INSTALL_PREFIX}/include/${LIBRARY}.h
diff --git a/devel/bsddialog/pkg-descr b/devel/bsddialog/pkg-descr
new file mode 100644
index 000000000000..5c77f861bf10
--- /dev/null
+++ b/devel/bsddialog/pkg-descr
@@ -0,0 +1,4 @@
+Utility (bsddialog(1)) and library (libbsddialog) to build scripts and tools
+with TUI Widgets.
+
+WWW: https://gitlab.com/alfix/bsddialog
diff --git a/devel/bsddialog/pkg-plist b/devel/bsddialog/pkg-plist
new file mode 100644
index 000000000000..ca755224b1c9
--- /dev/null
+++ b/devel/bsddialog/pkg-plist
@@ -0,0 +1,6 @@
+bin/bsddialog
+include/bsddialog.h
+include/bsddialog_theme.h
+lib/libbsddialog.a
+lib/libbsddialog.so
+lib/libbsddialog.so.0.1



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202111231358.1ANDwfui085964>