Support STAGEDIR.
This commit is contained in:
parent
44bb90dcdf
commit
ed16820e8c
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=333203
@ -12,11 +12,8 @@ MAINTAINER= ports@FreeBSD.org
|
||||
COMMENT= Archiver & backup program w/ builtin compression
|
||||
|
||||
ALL_TARGET= ${PORTNAME}
|
||||
MAN1= afio.1
|
||||
OPTIONS_DEFINE= DOCS EXAMPLES
|
||||
PORTDOCS= README SCRIPTS
|
||||
|
||||
NO_STAGE= yes
|
||||
post-patch:
|
||||
@${REINPLACE_CMD} -e 's|^CC=.*$$|CC=${CC}|' \
|
||||
${WRKSRC}/Makefile
|
||||
@ -25,19 +22,16 @@ post-patch:
|
||||
|
||||
post-install:
|
||||
.if ${PORT_OPTIONS:MDOCS}
|
||||
@${MKDIR} ${DOCSDIR}
|
||||
${INSTALL_MAN} ${WRKSRC}/README ${WRKSRC}/SCRIPTS ${DOCSDIR}
|
||||
@${MKDIR} ${STAGEDIR}${DOCSDIR}
|
||||
${INSTALL_MAN} ${WRKSRC}/README ${WRKSRC}/SCRIPTS ${STAGEDIR}${DOCSDIR}
|
||||
.endif
|
||||
.if ${PORT_OPTIONS:MEXAMPLES}
|
||||
@${MKDIR} ${EXAMPLESDIR}
|
||||
${INSTALL_SCRIPT} ${FILESDIR}/afiodump.example ${EXAMPLESDIR}
|
||||
${INSTALL_DATA} ${WRKSRC}/script1/DONTDUMP ${EXAMPLESDIR}
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/script2/* ${EXAMPLESDIR}
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/script3/* ${EXAMPLESDIR}
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/script4/* ${EXAMPLESDIR}
|
||||
PLIST_SUB+= PORTEXAMPLES=""
|
||||
.else
|
||||
PLIST_SUB+= PORTEXAMPLES="@comment "
|
||||
@${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
|
||||
${INSTALL_SCRIPT} ${FILESDIR}/afiodump.example ${STAGEDIR}${EXAMPLESDIR}
|
||||
${INSTALL_DATA} ${WRKSRC}/script1/DONTDUMP ${STAGEDIR}${EXAMPLESDIR}
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/script2/* ${STAGEDIR}${EXAMPLESDIR}
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/script3/* ${STAGEDIR}${EXAMPLESDIR}
|
||||
${INSTALL_SCRIPT} ${WRKSRC}/script4/* ${STAGEDIR}${EXAMPLESDIR}
|
||||
.endif
|
||||
|
||||
.include <bsd.port.mk>
|
||||
|
62
sysutils/afio/files/patch-Makefile
Normal file
62
sysutils/afio/files/patch-Makefile
Normal file
@ -0,0 +1,62 @@
|
||||
--- Makefile.orig 2003-12-21 18:23:51.000000000 +0800
|
||||
+++ Makefile 2013-11-08 09:56:31.000000000 +0800
|
||||
@@ -28,7 +28,7 @@ SHELL=/bin/sh
|
||||
c = -DHAVEMEMCMP
|
||||
## Define DEFFMTCMD to being how to format the media you use the most
|
||||
## This is the DEFault FoRMat CoManD.
|
||||
-d = -DDEFFMTCMD='"fdformat /dev/fd0H1440"'
|
||||
+d = -DDEFFMTCMD='"/usr/sbin/fdformat -f 1440 /dev/fd0"'
|
||||
## Define LONGZFILE if you want .Z to be tagged on the end of a 14 char
|
||||
## file name (or longer for BSD) in the archive when the file is compressed
|
||||
#e = -DLONGZFILE
|
||||
@@ -39,7 +39,7 @@ e2 = -DHAVE_LCHOWN
|
||||
|
||||
## Define PRG_COMPRESS to get something other than `gzip'.
|
||||
# you need to edit compfile.c (-G option) if you change this line.
|
||||
-f = -DPRG_COMPRESS='"gzip"'
|
||||
+f = -DPRG_COMPRESS='"/usr/bin/gzip"'
|
||||
|
||||
## Define HAVEFNMATCH if you want to use the gnu fnmatch() routine for
|
||||
# -y -Y -w -W matching.
|
||||
@@ -49,6 +49,11 @@ f = -DPRG_COMPRESS='"gzip"'
|
||||
|
||||
g = -DHAVEFNMATCH
|
||||
|
||||
+## Define HAVE_PARAM_H if your system has sys/param.h. This is used for BSD
|
||||
+# detection.
|
||||
+
|
||||
+h = -DHAVE_PARAM_H
|
||||
+
|
||||
# fnmatch() is in the gnu C library, so it is directly available on
|
||||
# Linux. If your system (e.g. SCO) does not have the gnu C library,
|
||||
# unpack the archive gnu.fnmatch.tar.gz and uncomment the following
|
||||
@@ -71,11 +76,14 @@ LARGEFILEFLAGS=-D_FILE_OFFSET_BITS=64 -D
|
||||
MW=
|
||||
#MW=-Wtraditional -Wcast-qual -Wcast-align -Wconversion -pedantic -Wlong-long -Wimplicit -Wuninitialized -W -Wshadow -Wsign-compare -Wstrict-prototypes -Wmissing-declarations
|
||||
|
||||
-CFLAGS1 = -Wall -Wstrict-prototypes -s -O2 -fomit-frame-pointer ${LARGEFILEFLAGS} ${MW}
|
||||
+#CFLAGS1 = -Wall -Wstrict-prototypes -s -O2 -fomit-frame-pointer ${LARGEFILEFLAGS} ${MW}
|
||||
+CFLAGS1 = -fomit-frame-pointer -fno-strength-reduce
|
||||
|
||||
-CC=gcc
|
||||
+#CC=gcc
|
||||
+#CC=cc
|
||||
|
||||
-CFLAGS = ${CFLAGS1} $1 $2 $3 $4 $5 $6 $7 $8 $9 $a $b $c $d $e ${e2} $f $g $I
|
||||
+#CFLAGS = ${CFLAGS1} $1 $2 $3 $4 $5 $6 $7 $8 $9 $a $b $c $d $e ${e2} $f $g $I
|
||||
+CFLAGS += ${CFLAGS1} $1 $2 $3 $4 $5 $6 $7 $8 $9 $a $b $c $d $e $f $g $h $I
|
||||
LDFLAGS =
|
||||
|
||||
afio : afio.o compfile.o exten.o match.o $M
|
||||
@@ -88,8 +96,9 @@ clean:
|
||||
cd regtest; /bin/sh regtest.clean
|
||||
|
||||
install: afio
|
||||
- cp afio /usr/local/bin
|
||||
- cp afio.1 /usr/share/man/man1
|
||||
+ install -cs -o root -g wheel afio ${DESTDIR}${PREFIX}/bin
|
||||
+ install -c -o root -g wheel afio.1 ${DESTDIR}${PREFIX}/man/man1
|
||||
+
|
||||
|
||||
# generate default list of -E extensions from manpage
|
||||
# note: on sun, I had to change awk command below to nawk or gawk
|
@ -1,136 +0,0 @@
|
||||
*** Makefile.orig Sun Dec 21 05:23:51 2003
|
||||
--- Makefile Sat Jan 21 17:34:53 2006
|
||||
***************
|
||||
*** 26,56 ****
|
||||
#b = -UUNIXPC
|
||||
## Define HAVEMEMCMP if you have memcmp otherwise assumes bcmp
|
||||
c = -DHAVEMEMCMP
|
||||
## Define DEFFMTCMD to being how to format the media you use the most
|
||||
## This is the DEFault FoRMat CoManD.
|
||||
! d = -DDEFFMTCMD='"fdformat /dev/fd0H1440"'
|
||||
## Define LONGZFILE if you want .Z to be tagged on the end of a 14 char
|
||||
## file name (or longer for BSD) in the archive when the file is compressed
|
||||
#e = -DLONGZFILE
|
||||
|
||||
## Define HAVE_LCHOWN is the system has an lchown call (like chown but does
|
||||
## not follow symlinks)
|
||||
e2 = -DHAVE_LCHOWN
|
||||
|
||||
## Define PRG_COMPRESS to get something other than `gzip'.
|
||||
# you need to edit compfile.c (-G option) if you change this line.
|
||||
! f = -DPRG_COMPRESS='"gzip"'
|
||||
|
||||
## Define HAVEFNMATCH if you want to use the gnu fnmatch() routine for
|
||||
# -y -Y -w -W matching.
|
||||
# If it is not defined, a primitive replacement match routine is used that
|
||||
# only supports patterns of the form "cccc" and "cccc*". Make sure that
|
||||
# you change the manual page in this case.
|
||||
|
||||
g = -DHAVEFNMATCH
|
||||
|
||||
# fnmatch() is in the gnu C library, so it is directly available on
|
||||
# Linux. If your system (e.g. SCO) does not have the gnu C library,
|
||||
# unpack the archive gnu.fnmatch.tar.gz and uncomment the following
|
||||
# two lines:
|
||||
|
||||
--- 26,61 ----
|
||||
#b = -UUNIXPC
|
||||
## Define HAVEMEMCMP if you have memcmp otherwise assumes bcmp
|
||||
c = -DHAVEMEMCMP
|
||||
## Define DEFFMTCMD to being how to format the media you use the most
|
||||
## This is the DEFault FoRMat CoManD.
|
||||
! d = -DDEFFMTCMD='"/usr/sbin/fdformat -f 1440 /dev/fd0"'
|
||||
## Define LONGZFILE if you want .Z to be tagged on the end of a 14 char
|
||||
## file name (or longer for BSD) in the archive when the file is compressed
|
||||
#e = -DLONGZFILE
|
||||
|
||||
## Define HAVE_LCHOWN is the system has an lchown call (like chown but does
|
||||
## not follow symlinks)
|
||||
e2 = -DHAVE_LCHOWN
|
||||
|
||||
## Define PRG_COMPRESS to get something other than `gzip'.
|
||||
# you need to edit compfile.c (-G option) if you change this line.
|
||||
! f = -DPRG_COMPRESS='"/usr/bin/gzip"'
|
||||
|
||||
## Define HAVEFNMATCH if you want to use the gnu fnmatch() routine for
|
||||
# -y -Y -w -W matching.
|
||||
# If it is not defined, a primitive replacement match routine is used that
|
||||
# only supports patterns of the form "cccc" and "cccc*". Make sure that
|
||||
# you change the manual page in this case.
|
||||
|
||||
g = -DHAVEFNMATCH
|
||||
|
||||
+ ## Define HAVE_PARAM_H if your system has sys/param.h. This is used for BSD
|
||||
+ # detection.
|
||||
+
|
||||
+ h = -DHAVE_PARAM_H
|
||||
+
|
||||
# fnmatch() is in the gnu C library, so it is directly available on
|
||||
# Linux. If your system (e.g. SCO) does not have the gnu C library,
|
||||
# unpack the archive gnu.fnmatch.tar.gz and uncomment the following
|
||||
# two lines:
|
||||
|
||||
***************
|
||||
*** 69,83 ****
|
||||
|
||||
# even more warnings flags..
|
||||
MW=
|
||||
#MW=-Wtraditional -Wcast-qual -Wcast-align -Wconversion -pedantic -Wlong-long -Wimplicit -Wuninitialized -W -Wshadow -Wsign-compare -Wstrict-prototypes -Wmissing-declarations
|
||||
|
||||
! CFLAGS1 = -Wall -Wstrict-prototypes -s -O2 -fomit-frame-pointer ${LARGEFILEFLAGS} ${MW}
|
||||
|
||||
! CC=gcc
|
||||
|
||||
! CFLAGS = ${CFLAGS1} $1 $2 $3 $4 $5 $6 $7 $8 $9 $a $b $c $d $e ${e2} $f $g $I
|
||||
LDFLAGS =
|
||||
|
||||
afio : afio.o compfile.o exten.o match.o $M
|
||||
${CC} ${LDFLAGS} afio.o compfile.o exten.o match.o $M -o afio
|
||||
|
||||
--- 74,91 ----
|
||||
|
||||
# even more warnings flags..
|
||||
MW=
|
||||
#MW=-Wtraditional -Wcast-qual -Wcast-align -Wconversion -pedantic -Wlong-long -Wimplicit -Wuninitialized -W -Wshadow -Wsign-compare -Wstrict-prototypes -Wmissing-declarations
|
||||
|
||||
! #CFLAGS1 = -Wall -Wstrict-prototypes -s -O2 -fomit-frame-pointer ${LARGEFILEFLAGS} ${MW}
|
||||
! CFLAGS1 = -fomit-frame-pointer -fno-strength-reduce
|
||||
|
||||
! #CC=gcc
|
||||
! CC=cc
|
||||
|
||||
! #CFLAGS = ${CFLAGS1} $1 $2 $3 $4 $5 $6 $7 $8 $9 $a $b $c $d $e ${e2} $f $g $I
|
||||
! CFLAGS += ${CFLAGS1} $1 $2 $3 $4 $5 $6 $7 $8 $9 $a $b $c $d $e $f $g $h $I
|
||||
LDFLAGS =
|
||||
|
||||
afio : afio.o compfile.o exten.o match.o $M
|
||||
${CC} ${LDFLAGS} afio.o compfile.o exten.o match.o $M -o afio
|
||||
|
||||
***************
|
||||
*** 86,97 ****
|
||||
rm -f regtest/cmpstat regtest/makesparse
|
||||
rm -f regtest/statsize regtest/statsize64
|
||||
cd regtest; /bin/sh regtest.clean
|
||||
|
||||
install: afio
|
||||
! cp afio /usr/local/bin
|
||||
! cp afio.1 /usr/share/man/man1
|
||||
|
||||
# generate default list of -E extensions from manpage
|
||||
# note: on sun, I had to change awk command below to nawk or gawk
|
||||
# to get it to work.
|
||||
exten_default.h : afio.1
|
||||
--- 94,106 ----
|
||||
rm -f regtest/cmpstat regtest/makesparse
|
||||
rm -f regtest/statsize regtest/statsize64
|
||||
cd regtest; /bin/sh regtest.clean
|
||||
|
||||
install: afio
|
||||
! install -cs -o root -g wheel afio ${PREFIX}/bin
|
||||
! install -c -o root -g wheel afio.1 ${PREFIX}/man/man1
|
||||
!
|
||||
|
||||
# generate default list of -E extensions from manpage
|
||||
# note: on sun, I had to change awk command below to nawk or gawk
|
||||
# to get it to work.
|
||||
exten_default.h : afio.1
|
@ -1,4 +1,7 @@
|
||||
bin/afio
|
||||
man/man1/afio.1.gz
|
||||
%%PORTDOCS%%%%DOCSDIR%%/README
|
||||
%%PORTDOCS%%%%DOCSDIR%%/SCRIPTS
|
||||
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/DONTDUMP
|
||||
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/README
|
||||
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/afiodump.example
|
||||
@ -12,3 +15,4 @@ bin/afio
|
||||
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/x.dot
|
||||
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/x.home
|
||||
%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%
|
||||
%%PORTDOCS%%@dirrm %%DOCSDIR%%
|
||||
|
Loading…
Reference in New Issue
Block a user