aboutsummaryrefslogtreecommitdiffstats
path: root/lang/fpc
diff options
context:
space:
mode:
authoracm <acm@FreeBSD.org>2008-01-07 05:20:12 +0800
committeracm <acm@FreeBSD.org>2008-01-07 05:20:12 +0800
commit108f3f095e47463a3b0534ec24149a91aae62fcb (patch)
treec6ddbd1d915f6adfe2972abbd1597f4fa178b91a /lang/fpc
parent9870f39b2f9a521be49e598513843de39a8911a5 (diff)
downloadfreebsd-ports-gnome-108f3f095e47463a3b0534ec24149a91aae62fcb.tar.gz
freebsd-ports-gnome-108f3f095e47463a3b0534ec24149a91aae62fcb.tar.zst
freebsd-ports-gnome-108f3f095e47463a3b0534ec24149a91aae62fcb.zip
- Add a better way to install fpc.cfg config file, now lazarus will compile
without problems :) - Bump PORTREVISION PR : 119385 Submitted by : bsam
Diffstat (limited to 'lang/fpc')
-rw-r--r--lang/fpc/Makefile5
-rw-r--r--lang/fpc/files/patch-compiler-utils_samplecfg11
-rw-r--r--lang/fpc/pkg-plist6
3 files changed, 19 insertions, 3 deletions
diff --git a/lang/fpc/Makefile b/lang/fpc/Makefile
index cfc84faf71d8..312cf13e388f 100644
--- a/lang/fpc/Makefile
+++ b/lang/fpc/Makefile
@@ -7,7 +7,7 @@
PORTNAME= fpc
PORTVERSION= 2.2.0
-PORTREVISION?= 0
+PORTREVISION?= 1
CATEGORIES?= lang
MASTER_SITES= ftp://ftp.freepascal.org/pub/fpc/dist/source-${PORTVERSION}/:source \
ftp://planetmirror.com/pub/fpc/dist/source-${PORTVERSION}/:source \
@@ -107,6 +107,9 @@ post-install:
if [ -e "${PREFIX}/bin/ppc386" ]; then ${RM} -f "${PREFIX}/bin/ppc386"; fi
${LN} -s "${PREFIX}/lib/fpc/${PORTVERSION}/ppc386" "${PREFIX}/bin"
${SH} "${PREFIX}/lib/fpc/${PORTVERSION}/samplecfg" "${PREFIX}/lib/fpc/${PORTVERSION}" "${PREFIX}/etc"
+ @if [ ! -f ${PREFIX}/etc/fpc.cfg ]; then \
+ ${CP} ${PREFIX}/etc/fpc.cfg.sample ${PREFIX}/etc/fpc.cfg; \
+ fi
@${CAT} ${PKGMESSAGE}
.else
diff --git a/lang/fpc/files/patch-compiler-utils_samplecfg b/lang/fpc/files/patch-compiler-utils_samplecfg
new file mode 100644
index 000000000000..134c4253b9a1
--- /dev/null
+++ b/lang/fpc/files/patch-compiler-utils_samplecfg
@@ -0,0 +1,11 @@
+--- compiler/utils/samplecfg 2008-01-06 01:17:24.468239657 +0300
++++ compiler/utils/samplecfg 2008-01-06 01:36:20.388869514 +0300
+@@ -72,7 +72,7 @@
+ # Detect if we have write permission in root.
+ if [ -w $sysdir ] ; then
+ echo Write permission in $sysdir.
+- thefile=$sysdir/fpc.cfg
++ thefile=$sysdir/fpc.cfg.sample
+ else
+ echo No write premission in $sysdir.
+ thefile=$HOME/.fpc.cfg
diff --git a/lang/fpc/pkg-plist b/lang/fpc/pkg-plist
index b997824ac432..dff90d83c318 100644
--- a/lang/fpc/pkg-plist
+++ b/lang/fpc/pkg-plist
@@ -1,6 +1,8 @@
-@comment $FreeBSD: /tmp/pcvs/ports/lang/fpc/pkg-plist,v 1.8 2007-09-18 06:53:23 acm Exp $
+@comment $FreeBSD: /tmp/pcvs/ports/lang/fpc/pkg-plist,v 1.9 2008-01-06 21:20:11 acm Exp $
-@unexec rm -f %D/etc/fpc.cfg > /dev/null 2>&1 || true
+@unexec if cmp -s %D/etc/fpc.cfg.sample %D/etc/fpc.cfg; then rm -f %D/etc/fpc.cfg; fi
+etc/fpc.cfg.sample
+@exec if [ ! -f %D/etc/fpc.cfg ] ; then cp -p %D/%F %B/fpc.cfg; fi
bin/fpc
bin/fpcmkcfg
bin/fpcsubst