1
0
mirror of https://git.FreeBSD.org/ports.git synced 2025-01-04 06:15:24 +00:00

- cleanup configure stage

- fix side effects in Makefile
This commit is contained in:
Dirk Meyer 2013-09-03 19:04:16 +00:00
parent 441b298aae
commit 9d82b16ff9
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=326201
2 changed files with 60 additions and 12 deletions

View File

@ -43,8 +43,8 @@ OPTIONS_DEFINE= DOCS
post-extract:
@${CP} ${WRKSRC}/conf.h.dist ${WRKSRC}/conf.h
post-patch:
@${REINPLACE_CMD} \
pre-configure:
${REINPLACE_CMD} \
-e "s=/usr/local/news/lib/bin/config=${NEWSBIN}/config=" \
-e "s=/usr/local/news/cnewsbin=${NEWSBIN}=" \
-e "s=/usr/local/news/lib=${NEWSCTL}=" \
@ -53,17 +53,13 @@ post-patch:
-e "s=/usr/local/bin=${PREFIX}/bin=" \
-e "s=/usr/local/sbin=${PREFIX}/sbin=" \
-e "s=/usr/local/man=${PREFIX}/man=" \
${WRKSRC}/Makefile ${WRKSRC}/conf.h
# Try to fix parallel builds (-jX)
@${REINPLACE_CMD} \
-E 's=cd (.+); (\$$\(MAKE\))=\2 -C \1=' \
${WRKSRC}/Makefile
${WRKSRC}/conf.h
post-install:
${INSTALL_DATA} ${WRKSRC}/overview.fmt ${NEWSCTL}/overview.fmt
.if ${PORT_OPTIONS:MDOCS}
@${MKDIR} ${DOCSDIR}
${INSTALL_DATA} ${DOCSFILES1:S=^=${WRKSRC}/=} ${DOCSDIR}
${MKDIR} ${DOCSDIR}
${INSTALL_DATA} ${DOCSFILES1:S=^=${WRKSRC}/=} ${DOCSDIR}/
.for i in ${DOCSFILES2}
${INSTALL_DATA} ${WRKSRC}/${i}/README ${DOCSDIR}/${i}-README
.endfor

View File

@ -1,5 +1,5 @@
--- Makefile.orig Tue Jan 9 08:30:24 1996
+++ Makefile Thu Dec 5 09:59:23 2002
--- Makefile.orig 1996-01-09 08:30:24.000000000 +0100
+++ Makefile 2013-09-03 20:32:47.000000000 +0200
@@ -4,7 +4,7 @@
# The program that knows how to deal with makefiles. [Uncomment if needed.]
# MAKE=make
@ -17,10 +17,62 @@
+#ETCDIR = /usr/local/sbin
# Where nntpxmit and nntpxfer is going to live
-BINDIR = /usr/local/bin
+#BINDIR = /usr/local/news/cnewsbin
+#BINDIR = /usr/local/libexec/cnews
# Where manual pages live
-MANDIR = /usr/local/man
+#MANDIR = /usr/local/man
#
LIBS = $(DBLIBS) $(RESLIB) $(NETLIBS) $(KVMLIB)
SUBMAKEFLAGS="LIBS=${LIBS}" "CFLAGS=${CFLAGS}" "ETCDIR=${ETCDIR}" "BINDIR=${BINDIR}" "MANDIR=${MANDIR}"
@@ -42,11 +42,11 @@
all: make_$(TYPE)
make_server: /nowhere
- cd server; $(MAKE) $(MFLAGS) $(SUBMAKEFLAGS)
- cd support; $(MAKE) $(MFLAGS) $(SUBMAKEFLAGS)
- cd doc; $(MAKE) $(MFLAGS) $(SUBMAKEFLAGS)
- cd xmit; $(MAKE) $(MFLAGS) $(SUBMAKEFLAGS)
- cd xfer; $(MAKE) $(MFLAGS) $(SUBMAKEFLAGS)
+ $(MAKE) -C server $(MFLAGS) $(SUBMAKEFLAGS)
+ $(MAKE) -C support $(MFLAGS) $(SUBMAKEFLAGS)
+ $(MAKE) -C doc $(MFLAGS) $(SUBMAKEFLAGS)
+ $(MAKE) -C xmit $(MFLAGS) $(SUBMAKEFLAGS)
+ $(MAKE) -C xfer $(MFLAGS) $(SUBMAKEFLAGS)
server: make_server
@@ -59,25 +59,25 @@
install: install_$(TYPE)
install_server:
- cd server; $(MAKE) $(MFLAGS) $(SUBMAKEFLAGS) install
- cd support; $(MAKE) $(MFLAGS) $(SUBMAKEFLAGS) install
- cd doc; $(MAKE) $(MFLAGS) $(SUBMAKEFLAGS) install
- cd xmit; $(MAKE) $(MFLAGS) $(SUBMAKEFLAGS) install
- cd xfer; $(MAKE) $(MFLAGS) $(SUBMAKEFLAGS) install
+ $(MAKE) -C server $(MFLAGS) $(SUBMAKEFLAGS) install
+ $(MAKE) -C support $(MFLAGS) $(SUBMAKEFLAGS) install
+ $(MAKE) -C doc $(MFLAGS) $(SUBMAKEFLAGS) install
+ $(MAKE) -C xmit $(MFLAGS) $(SUBMAKEFLAGS) install
+ $(MAKE) -C xfer $(MFLAGS) $(SUBMAKEFLAGS) install
install_msgidd:
- cd server; $(MAKE) $(MFLAGS) $(SUBMAKEFLAGS) install_msgidd
+ $(MAKE) -C server $(MFLAGS) $(SUBMAKEFLAGS) install_msgidd
clean:
- rm -f .[a-z]* *.CKP *.BAK *~ ; for i in $(DISTDIRS); do cd $$i; $(MAKE) $(MFLAGS) clean; cd ..; done
+ rm -f .[a-z]* *.CKP *.BAK *~ ; for i in $(DISTDIRS); do $(MAKE) -C $$i $(MFLAGS) clean; done
check:
- for i in $(DISTDIRS); do cd $$i; $(MAKE) $(MFLAGS) check; cd ..; done
+ for i in $(DISTDIRS); do $(MAKE) -C $$i $(MFLAGS) check; done
distrib: check
mkdir ../nntp.dist
cp -rp $(DIST) ../nntp.dist
- cd ../nntp.dist; for i in $(DISTDIRS); do cd $$i; $(MAKE) $(MFLAGS) distrib; cd ..; done
+ cd ../nntp.dist; for i in $(DISTDIRS); do $(MAKE) -C $$i $(MFLAGS) distrib; done
server: /nowhere