aboutsummaryrefslogtreecommitdiff
path: root/chinese
diff options
context:
space:
mode:
authorYen-Ming Lee <leeym@FreeBSD.org>2003-06-26 09:43:59 +0000
committerYen-Ming Lee <leeym@FreeBSD.org>2003-06-26 09:43:59 +0000
commitbf4ce1913ba1e9790891e8bf2993dcc93fd9e2d1 (patch)
treea3ac48af30e23672a4d5f40ac44f49a972b43152 /chinese
parent9d799867da226627a4e393a8caab5fb8457ab707 (diff)
downloadports-bf4ce1913ba1e9790891e8bf2993dcc93fd9e2d1.tar.gz
ports-bf4ce1913ba1e9790891e8bf2993dcc93fd9e2d1.zip
Notes
Diffstat (limited to 'chinese')
-rw-r--r--chinese/gbfs/Makefile46
-rw-r--r--chinese/gbfs/distinfo2
-rw-r--r--chinese/gbfs/files/gbfs.sh15
-rw-r--r--chinese/gbfs/pkg-plist1
4 files changed, 33 insertions, 31 deletions
diff --git a/chinese/gbfs/Makefile b/chinese/gbfs/Makefile
index a5dbb6ab8ba3..37217e793196 100644
--- a/chinese/gbfs/Makefile
+++ b/chinese/gbfs/Makefile
@@ -6,7 +6,7 @@
#
PORTNAME= gbfs
-PORTVERSION= 1.1
+PORTVERSION= 1.3
CATEGORIES= chinese
MASTER_SITES= ftp://freebsd.sinica.edu.tw/pub/statue/gbfs/
@@ -18,6 +18,7 @@ NO_PACKAGE= "Different versions definitely cause crash"
SYSDIR= /usr/src/sys
KMODDIR= ${PREFIX}/modules
PLIST_SUB= MSDOSFSKO=${MSDOSFSKO}
+USE_REINPLACE= yes
.include <bsd.port.pre.mk>
@@ -27,48 +28,43 @@ MSDOSFSKO= msdosfs.ko
MSDOSFSKODIR= ${SYSDIR}/modules/msdosfs
MSDOSFSPATCH= msdosfs.diff.5
CD9660PATCH= cd9660.diff.5
+NTFSDIR= ${SYSDIR}/fs/ntfs
+NTFSPATCH= ntfs.diff.5
.else
MSDOSFSDIR= ${SYSDIR}/msdosfs
MSDOSFSKO= msdos.ko
MSDOSFSKODIR= ${SYSDIR}/modules/msdos
MSDOSFSPATCH= msdosfs.diff
CD9660PATCH= cd9660.diff
+NTFSDIR= ${SYSDIR}/ntfs
+NTFSPATCH= ntfs.diff
.endif
-pre-extract:
- @if [ ! -d /sys -o ! -d /usr/src/sys ]; then \
- ${ECHO_CMD} "****************************************" ; \
- ${ECHO_CMD} " You need to extract kernel source tree" ; \
- ${ECHO_CMD} " before you build this package..." ; \
- ${ECHO_CMD} "****************************************" ; \
- ${FALSE} ; \
- fi
+.if !exists (${SYSDIR})
+IGNORE= "You need to extract kernel source tree before you build this package"
+.endif
do-extract:
- @${MKDIR} ${WRKDIR}/msdos ${WRKDIR}/cd9660
- @${CP} -R ${MSDOSFSDIR}/*.[ch] ${WRKDIR}/msdos
- @${CP} ${MSDOSFSKODIR}/Makefile ${WRKDIR}/msdos/Makefile.ori
- @${CP} -R ${SYSDIR}/isofs/cd9660/*.[ch] ${WRKDIR}/cd9660
- @${CP} ${SYSDIR}/modules/cd9660/Makefile ${WRKDIR}/cd9660/Makefile.ori
+ @${MKDIR} ${WRKDIR}/msdos ${WRKDIR}/cd9660 ${WRKDIR}/ntfs
+ @${CP} ${MSDOSFSDIR}/* ${MSDOSFSKODIR}/Makefile ${WRKDIR}/msdos
+ @${CP} ${SYSDIR}/isofs/cd9660/* ${SYSDIR}/modules/cd9660/Makefile ${WRKDIR}/cd9660
+ @${CP} ${NTFSDIR}/* ${SYSDIR}/modules/ntfs/Makefile ${WRKDIR}/ntfs
@(cd ${WRKDIR}; ${TAR} xzf ${DISTDIR}/${DISTFILES} )
- @${SED} -e 's,@@PREFIX@@,${PREFIX},' ${FILESDIR}/gbfs.sh > ${WRKDIR}/gbfs.sh
+ @${REINPLACE_CMD} -e "/^\.PATH/d" ${WRKDIR}/*/Makefile
do-patch:
- (cd ${WRKDIR}/msdos; ${PATCH} --quiet < ${WRKDIR}/${MSDOSFSPATCH} )
- @${SED} -e "/^\.PATH/d" ${WRKDIR}/msdos/Makefile.ori > ${WRKDIR}/msdos/Makefile
- (cd ${WRKDIR}/cd9660; ${PATCH} --quiet < ${WRKDIR}/${CD9660PATCH} )
- @${SED} -e "/^\.PATH/d" ${WRKDIR}/cd9660/Makefile.ori > ${WRKDIR}/cd9660/Makefile
+ @(cd ${WRKDIR}/msdos; ${PATCH} --quiet < ${WRKDIR}/${MSDOSFSPATCH} )
+ @(cd ${WRKDIR}/cd9660; ${PATCH} --quiet < ${WRKDIR}/${CD9660PATCH} )
+ @(cd ${WRKDIR}/ntfs; ${PATCH} --quiet < ${WRKDIR}/${NTFSPATCH} )
do-build:
@(cd ${WRKDIR}/msdos; make all)
@(cd ${WRKDIR}/cd9660; make all)
-
-pre-install:
- @${MKDIR} ${KMODDIR}
+ @(cd ${WRKDIR}/ntfs; make all)
do-install:
- @${INSTALL_SCRIPT} ${WRKDIR}/gbfs.sh ${PREFIX}/etc/rc.d
- @${INSTALL_SCRIPT} ${WRKDIR}/msdos/${MSDOSFSKO} ${KMODDIR}/${MSDOSFSKO}
- @${INSTALL_SCRIPT} ${WRKDIR}/cd9660/cd9660.ko ${KMODDIR}/cd9660.ko
+ @${MKDIR} ${KMODDIR}
+ @${INSTALL_SCRIPT} ${FILESDIR}/gbfs.sh ${PREFIX}/etc/rc.d
+ @${INSTALL_SCRIPT} ${WRKDIR}/*/*.ko ${KMODDIR}
.include <bsd.port.post.mk>
diff --git a/chinese/gbfs/distinfo b/chinese/gbfs/distinfo
index 84bebb3b190f..5b757d5905e6 100644
--- a/chinese/gbfs/distinfo
+++ b/chinese/gbfs/distinfo
@@ -1 +1 @@
-MD5 (gbfs-1.1.tar.gz) = 4e3c765d052062edeb42446147536f31
+MD5 (gbfs-1.3.tar.gz) = 1b466f67a58ce5dc4c9f64129800a385
diff --git a/chinese/gbfs/files/gbfs.sh b/chinese/gbfs/files/gbfs.sh
index c03bc56ac5a2..10846dab4f37 100644
--- a/chinese/gbfs/files/gbfs.sh
+++ b/chinese/gbfs/files/gbfs.sh
@@ -1,21 +1,26 @@
#!/bin/sh
+if ! PREFIX=$(expr $0 : "\(/.*\)/etc/rc\.d/$(basename $0)\$"); then
+ echo "$0: Cannot determine the PREFIX" >&2
+ exit 1
+fi
+
case "$1" in
start)
- if [ -x @@PREFIX@@/modules/cd9660.ko ]; then
+ if [ -x ${PREFIX}/modules/cd9660.ko ]; then
echo -n ' GB-cd9660'
kldload /usr/local/modules/cd9660.ko
fi
- if [ -x @@PREFIX@@/modules/msdos.ko ]; then
+ if [ -x ${PREFIX}/modules/msdos.ko ]; then
echo -n ' GB-msdos'
kldload /usr/local/modules/msdos.ko
fi
# msdosfs.ko instead of msdos.ko after FreeBSD 5.0-CURRENT
- if [ -x @@PREFIX@@/modules/msdosfs.ko ]; then
+ if [ -x ${PREFIX}/modules/msdosfs.ko ]; then
echo -n ' GB-msdosfs'
kldload /usr/local/modules/msdosfs.ko
fi
- if [ -x @@PREFIX@@/modules/ntfs.ko ]; then
+ if [ -x ${PREFIX}/modules/ntfs.ko ]; then
echo -n ' GB-ntfs'
kldload /usr/local/modules/ntfs.ko
fi
@@ -27,7 +32,7 @@ stop)
kldunload -v -n ntfs && echo -n ' GB-ntfs'
;;
*)
- echo "Usage: big5fs.sh {start|stop}" >&2
+ echo "Usage: gbfs.sh {start|stop}" >&2
exit 1
;;
esac
diff --git a/chinese/gbfs/pkg-plist b/chinese/gbfs/pkg-plist
index 797b9b91ff64..ec0161f0ffd3 100644
--- a/chinese/gbfs/pkg-plist
+++ b/chinese/gbfs/pkg-plist
@@ -1,4 +1,5 @@
etc/rc.d/gbfs.sh
modules/cd9660.ko
modules/%%MSDOSFSKO%%
+modules/ntfs.ko
@unexec rmdir %D/modules 2>/dev/null || true