git: e11a5e37c452 - main - german/unix-connect: config by enviroment, use @sample

From: Dirk Meyer <dinoex_at_FreeBSD.org>
Date: Sat, 12 Apr 2025 15:06:39 UTC
The branch main has been updated by dinoex:

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

commit e11a5e37c4526d22fec2d06a2b25cf24852329ed
Author:     Dirk Meyer <dinoex@FreeBSD.org>
AuthorDate: 2025-04-12 15:06:29 +0000
Commit:     Dirk Meyer <dinoex@FreeBSD.org>
CommitDate: 2025-04-12 15:06:29 +0000

    german/unix-connect: config by enviroment, use @sample
---
 german/unix-connect/Makefile                | 28 +++++++-----
 german/unix-connect/files/patch-Makefile    | 70 ++++++++++++++---------------
 german/unix-connect/files/patch-Makefile.in |  6 +--
 german/unix-connect/pkg-descr               |  5 ---
 german/unix-connect/pkg-plist               | 38 ++++++++--------
 5 files changed, 74 insertions(+), 73 deletions(-)

diff --git a/german/unix-connect/Makefile b/german/unix-connect/Makefile
index 487610a04f85..4e3fd0fe88f8 100644
--- a/german/unix-connect/Makefile
+++ b/german/unix-connect/Makefile
@@ -9,38 +9,40 @@ MAINTAINER=	dinoex@FreeBSD.org
 COMMENT=	Mail and news gateway for Zconnect
 WWW=		https://www.dinoex.de/unix-connect.html
 
-BUILD_DEPENDS=	lrz:comms/lrzsz
-
-LICENSE_COMB=	multi
 LICENSE=	GPLv2 BSD3CLAUSE
+LICENSE_COMB=	multi
 
-MANUAL_PACKAGE_BUILD=	needs hostname
+.if !defined(UC_GATEWAY_HOSTNAME) || !defined(UC_GATEWAY_DOMAIN)
+IGNORE=		needs UC_GATEWAY_HOSTNAME and UC_GATEWAY_DOMAIN
+.endif
+
+BUILD_DEPENDS=	lrz:comms/lrzsz
 
 USES=		fakeroot gperf
 
-WRKSRC=		${WRKDIR}/${DISTNAME}
 GNU_CONFIGURE=	yes
-.if !defined(INSTALL_AS_USER)
-CONFIGURE_ARGS+=--with-user=news
-CONFIGURE_ARGS+=--with-group=dialer
-.else
 CONFIGURE_ARGS+=--with-user=`id -u -n`
 CONFIGURE_ARGS+=--with-group=`id -g -n`
-.endif
 CONFIGURE_ARGS+=--with-execdir=${PREFIX}/libexec/uconnect
 CONFIGURE_ARGS+=--with-confdir=${PREFIX}/etc/uconnect
 CONFIGURE_ARGS+=--with-spooldir=/var/spool/uconnect
+CONFIGURE_ARGS+=--with-sys=${UC_GATEWAY_HOSTNAME}
+CONFIGURE_ARGS+=--with-domain=${UC_GATEWAY_DOMAIN}
+CONFIGURE_ARGS+=--with-path=/sbin:/bin:/usr/sbin:/usr/bin:${LOCALBASE}/sbin:${LOCALBASE}/bin
 CONFIGURE_ARGS+=--enable-testing
+
 CFLAGS+=	-g
 CFLAGS:=	${CFLAGS:S/-O[0-9]*//g}	# gcc generates broken code in uwsmtp
 
+WRKSRC=		${WRKDIR}/${DISTNAME}
+
 DOC1=	README INSTALL TODO ChangeLog ChangeLog.configure
 
 OPTIONS_DEFINE=	DOCS
+OPTIONS_DEFAULT=SENDMAIL CNEWS
 OPTIONS_SINGLE=	MAIL NEWS
 OPTIONS_SINGLE_MAIL=	SENDMAIL POSTFIX QMAIL SMAIL NO_MAIL
 OPTIONS_SINGLE_NEWS=	CNEWS INN NO_NEWS
-OPTIONS_DEFAULT=SENDMAIL CNEWS
 NO_OPTIONS_SORT=yes
 OPTIONS_SUB=	yes
 SENDMAIL_DESC=	build mail scripts for sendmail
@@ -63,6 +65,10 @@ NO_NEWS_CONFIGURE_ON=	--with-news=no
 pre-install:
 	${MKDIR} ${STAGEDIR}/var/spool
 
+post-install:
+	${MV} ${STAGEDIR}${PREFIX}/etc/uconnect/systems.sample.sample \
+		${STAGEDIR}${PREFIX}/etc/uconnect/systems.sample
+
 post-install-CNEWS-on:
 	${INSTALL_SCRIPT} ${WRKSRC}/mail-and-news/cnews/viazconnect \
 		${STAGEDIR}${PREFIX}/libexec/uconnect/
diff --git a/german/unix-connect/files/patch-Makefile b/german/unix-connect/files/patch-Makefile
index 04f9505210d0..f8210bfa3cd0 100644
--- a/german/unix-connect/files/patch-Makefile
+++ b/german/unix-connect/files/patch-Makefile
@@ -1,17 +1,17 @@
---- etc/Makefile.orig	2000-02-06 21:00:07.000000000 +0100
-+++ etc/Makefile	2013-11-29 05:40:51.000000000 +0100
-@@ -18,7 +18,7 @@
+--- etc/Makefile.orig	2000-02-06 20:00:07 UTC
++++ etc/Makefile
+@@ -18,7 +18,7 @@ install:
  install:
  	for i in $(FILES); do \
  	if test ! -f $(ETCDIR)/$$i; then \
 -		$(INSTALL_DATA) $$i $(ETCDIR); \
-+		$(INSTALL_DATA) $$i $(DESTDIR)$(ETCDIR); \
++		$(INSTALL_DATA) $$i $(DESTDIR)$(ETCDIR)/$$i.sample; \
  	fi; done
  
  uninstall:
---- gate/Makefile.orig	2001-05-23 08:58:13.000000000 +0200
-+++ gate/Makefile	2013-11-29 05:41:23.000000000 +0100
-@@ -48,11 +48,11 @@
+--- gate/Makefile.orig	2001-05-23 06:58:13 UTC
++++ gate/Makefile
+@@ -48,11 +48,11 @@ install:	all
  all:	$(PROGS)
  
  install:	all
@@ -26,9 +26,9 @@
  
  clean:
  	-rm -f $(CLEANFILES) $(PROGS) $(TPROGS)
---- shell/Makefile.orig	2001-05-23 08:55:45.000000000 +0200
-+++ shell/Makefile	2013-11-29 05:50:46.000000000 +0100
-@@ -71,13 +71,13 @@
+--- shell/Makefile.orig	2001-05-23 06:55:45 UTC
++++ shell/Makefile
+@@ -71,13 +71,13 @@ install: $(FILES)
  install: $(FILES)
  	for i in $(FILESKEEP) ; do \
  		if [ ! -e $(BINDIR)/$$i ] ; then \
@@ -45,9 +45,9 @@
  
  clean:
  	-rm -f $(CLEANFILES)
---- online/Makefile.orig	2001-05-23 08:55:47.000000000 +0200
-+++ online/Makefile	2013-11-29 05:44:29.000000000 +0100
-@@ -52,10 +52,10 @@
+--- online/Makefile.orig	2001-05-23 06:55:47 UTC
++++ online/Makefile
+@@ -52,10 +52,10 @@ install:	all
  all:	$(PROGS)
  
  install:	all
@@ -60,9 +60,9 @@
  
  clean:
  	-rm -f $(CLEANFILES) $(PROGS)
---- rsmtp/Makefile.orig	2000-01-14 22:42:19.000000000 +0100
-+++ rsmtp/Makefile	2013-11-29 05:50:02.000000000 +0100
-@@ -19,20 +19,20 @@
+--- rsmtp/Makefile.orig	2000-01-14 21:42:19 UTC
++++ rsmtp/Makefile
+@@ -19,20 +19,20 @@ BINMIN	= \
  	bsmtp
  
  BINMIN	= \
@@ -88,7 +88,7 @@
  
  clean:
  	-rm -f $(CLEANFILES) $(TARMIN)
-@@ -47,20 +47,20 @@
+@@ -47,20 +47,20 @@ bsmtp:	bsmtp.o
  
  # install rules
  
@@ -119,9 +119,9 @@
  	$(INSTALL_PROGRAM) rsmtp $@
  
  # end of makefile
---- mail-and-news/inn/Makefile.orig	2000-01-15 21:51:30.000000000 +0100
-+++ mail-and-news/inn/Makefile	2013-11-29 05:52:39.000000000 +0100
-@@ -7,10 +7,10 @@
+--- mail-and-news/inn/Makefile.orig	2000-01-15 20:51:30 UTC
++++ mail-and-news/inn/Makefile
+@@ -7,10 +7,10 @@ install: $(FILES)
  all: $(FILES)
  
  install: $(FILES)
@@ -134,9 +134,9 @@
  
  clean:
  	-rm -f $(CLEANFILES)
---- mail-and-news/postfix/Makefile.orig	2002-04-07 13:07:30.000000000 +0200
-+++ mail-and-news/postfix/Makefile	2013-11-29 05:53:11.000000000 +0100
-@@ -7,10 +7,10 @@
+--- mail-and-news/postfix/Makefile.orig	2002-04-07 11:07:30 UTC
++++ mail-and-news/postfix/Makefile
+@@ -7,10 +7,10 @@ install: $(FILES)
  all: $(FILES) README ucpf.pl
  
  install: $(FILES)
@@ -149,9 +149,9 @@
  
  clean:
  	-rm -f $(CLEANFILES)
---- mail-and-news/qmail/Makefile.orig	2000-01-15 22:06:49.000000000 +0100
-+++ mail-and-news/qmail/Makefile	2013-11-29 05:53:27.000000000 +0100
-@@ -7,10 +7,10 @@
+--- mail-and-news/qmail/Makefile.orig	2000-01-15 21:06:49 UTC
++++ mail-and-news/qmail/Makefile
+@@ -7,10 +7,10 @@ install: $(FILES)
  all: $(FILES)
  
  install: $(FILES)
@@ -164,9 +164,9 @@
  
  clean:
  	-rm -f $(CLEANFILES)
---- mail-and-news/sendmail/Makefile.orig	2001-03-27 07:59:06.000000000 +0200
-+++ mail-and-news/sendmail/Makefile	2013-11-29 05:53:48.000000000 +0100
-@@ -41,10 +41,10 @@
+--- mail-and-news/sendmail/Makefile.orig	2001-03-27 05:59:06 UTC
++++ mail-and-news/sendmail/Makefile
+@@ -41,10 +41,10 @@ install: $(FILES)
  all: RSMTP $(FILES) uconnect.m4
  
  install: $(FILES)
@@ -179,9 +179,9 @@
  
  clean:
  	-rm -f $(CLEANFILES)
---- mail-and-news/smail/Makefile.orig	2001-03-27 07:59:06.000000000 +0200
-+++ mail-and-news/smail/Makefile	2013-11-29 05:54:03.000000000 +0100
-@@ -41,10 +41,10 @@
+--- mail-and-news/smail/Makefile.orig	2001-03-27 05:59:06 UTC
++++ mail-and-news/smail/Makefile
+@@ -41,10 +41,10 @@ install: $(FILES)
  all: $(FILES)
  
  install: $(FILES)
@@ -194,9 +194,9 @@
  
  clean:
  	-rm -f $(CLEANFILES)
---- tools/Makefile.orig	2001-05-23 08:55:42.000000000 +0200
-+++ tools/Makefile	2013-11-29 05:51:27.000000000 +0100
-@@ -44,10 +44,10 @@
+--- tools/Makefile.orig	2001-05-23 06:55:42 UTC
++++ tools/Makefile
+@@ -44,10 +44,10 @@ install:	all
  all:	$(PROGS)
  
  install:	all
diff --git a/german/unix-connect/files/patch-Makefile.in b/german/unix-connect/files/patch-Makefile.in
index 557e779114c7..99c7e88f6a91 100644
--- a/german/unix-connect/files/patch-Makefile.in
+++ b/german/unix-connect/files/patch-Makefile.in
@@ -1,6 +1,6 @@
---- Makefile.in.orig	2001-10-01 20:27:36.000000000 +0200
-+++ Makefile.in	2014-10-28 22:21:15.000000000 +0100
-@@ -55,12 +55,12 @@
+--- Makefile.in.orig	2001-10-01 18:27:36 UTC
++++ Makefile.in
+@@ -55,12 +55,12 @@ install:
  
  install:
  	for dir in $(TARGETDIRS); do \
diff --git a/german/unix-connect/pkg-descr b/german/unix-connect/pkg-descr
index 763d46e3f835..21e0a574312a 100644
--- a/german/unix-connect/pkg-descr
+++ b/german/unix-connect/pkg-descr
@@ -18,8 +18,3 @@ vermieden werden koennen.
 
 LICENSE: GPL2 or later
 LICENSE: BSD (rsmtp)
-
-FTP: ftp://unix-connect.sf.net/pub/unix-connect/
-FTP: ftp://ftp.dinoex.org/pub/unix-connect/
-
-See also: https://sourceforge.net/projects/unix-connect/
diff --git a/german/unix-connect/pkg-plist b/german/unix-connect/pkg-plist
index 1a1afd9b5dcc..206c3f95ded2 100644
--- a/german/unix-connect/pkg-plist
+++ b/german/unix-connect/pkg-plist
@@ -1,23 +1,31 @@
-libexec/uconnect/januslogin
-libexec/uconnect/receiver
-libexec/uconnect/zcall
-libexec/uconnect/uuwnews
-libexec/uconnect/uuwsmtp
-libexec/uconnect/uursmtp
-libexec/uconnect/zconsplit
+@sample etc/uconnect/alias.sample
+@sample etc/uconnect/approved.sample
+@sample etc/uconnect/autoeintrag.zconnect.sample
+@sample etc/uconnect/config.sample
+@sample etc/uconnect/myself.zconnect.sample
+etc/uconnect/systems.sample
+@sample etc/uconnect/xprogs.sample
+@sample etc/uconnect/zconnecthosts.sample
 libexec/uconnect/anruf
 libexec/uconnect/auspack
+libexec/uconnect/bsmtp
+libexec/uconnect/cron.d.hourly
 libexec/uconnect/einpack
 libexec/uconnect/import
+libexec/uconnect/januslogin
 libexec/uconnect/list-systems
+libexec/uconnect/logrotate.d.entry
 libexec/uconnect/prearc
-libexec/uconnect/uumlist
-libexec/uconnect/bsmtp
 libexec/uconnect/rcsmtp
+libexec/uconnect/receiver
 libexec/uconnect/rgsmtp
 libexec/uconnect/rsmtp
-libexec/uconnect/cron.d.hourly
-libexec/uconnect/logrotate.d.entry
+libexec/uconnect/uumlist
+libexec/uconnect/uursmtp
+libexec/uconnect/uuwnews
+libexec/uconnect/uuwsmtp
+libexec/uconnect/zcall
+libexec/uconnect/zconsplit
 @(news,dialer,4555) libexec/uconnect/uurnews
 %%SENDMAIL%%libexec/uconnect/mail.uuconnect
 %%SENDMAIL%%libexec/uconnect/zbatchsmtp
@@ -27,14 +35,6 @@ libexec/uconnect/logrotate.d.entry
 %%SMAIL%%libexec/uconnect/zbatchsmtp
 %%CNEWS%%libexec/uconnect/viazconnect
 %%INN%%libexec/uconnect/send-zcon
-etc/uconnect/alias
-etc/uconnect/approved
-etc/uconnect/autoeintrag.zconnect
-etc/uconnect/config
-etc/uconnect/myself.zconnect
-etc/uconnect/systems.sample
-etc/uconnect/xprogs
-etc/uconnect/zconnecthosts
 @owner news
 @group dialer
 @dir etc/uconnect