aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authordanfe <danfe@FreeBSD.org>2007-07-03 00:07:07 +0800
committerdanfe <danfe@FreeBSD.org>2007-07-03 00:07:07 +0800
commit42b6a336f0da4e474afc91ac5cf6d2f9a55c8836 (patch)
tree949af0139f3edd3fa6d11d5d3e98199959b51ecf
parentf27e6a84f44f114c6ad8ca2a8ef7cad72dbab5a6 (diff)
downloadfreebsd-ports-graphics-42b6a336f0da4e474afc91ac5cf6d2f9a55c8836.tar.gz
freebsd-ports-graphics-42b6a336f0da4e474afc91ac5cf6d2f9a55c8836.tar.zst
freebsd-ports-graphics-42b6a336f0da4e474afc91ac5cf6d2f9a55c8836.zip
- Fix yet another PREFIX vs. LOCALBASE issue
- Simplify port logic and plist handling - Do not install yet another copy of GPL
-rw-r--r--graphics/linplasma/Makefile32
-rw-r--r--graphics/linplasma/files/patch-Makefile2
2 files changed, 11 insertions, 23 deletions
diff --git a/graphics/linplasma/Makefile b/graphics/linplasma/Makefile
index 266a422d914..0bd23735394 100644
--- a/graphics/linplasma/Makefile
+++ b/graphics/linplasma/Makefile
@@ -7,6 +7,7 @@
PORTNAME= linplasma
PORTVERSION= 1.0
+PORTREVISION= 1
CATEGORIES= graphics
MASTER_SITES= ${MASTER_SITE_SUNSITE}
MASTER_SITE_SUBDIR= apps/graphics/hacks/svgalib
@@ -16,38 +17,25 @@ COMMENT= Sinus plasma, an SVGAlib demo
LIB_DEPENDS= vga.1:${PORTSDIR}/graphics/svgalib
-ALL_TARGET= ${PORTNAME}
-DOCFILES= README GPL
-DOCDIR= share/doc/${PORTNAME}/
ONLY_FOR_ARCHS= i386
-PLIST= ${WRKDIR}/pkg-plist
+
+ALL_TARGET= ${PORTNAME}
WRKSRC= ${WRKDIR}/${PORTNAME}
+PLIST_FILES= bin/linplasma
+PORTDOCS= README
post-patch:
- @${REINPLACE_CMD} -e "s:%%PREFIX%%:${PREFIX}:g" ${WRKSRC}/Makefile
- @${REINPLACE_CMD} -e "s:PI:M_PI:g" ${WRKSRC}/linplasma.c
+ @${REINPLACE_CMD} -e "s:PI:M_PI:" ${WRKSRC}/linplasma.c
@${REINPLACE_CMD} -e \
"s:(int)palptr = (int:palptr = (unsigned char *:" \
${WRKSRC}/linplasma.c
-pre-install:
- ${ECHO_CMD} "bin/linplasma" > ${PLIST}
-.if !defined(NOPORTDOCS)
-.for i in ${DOCFILES}
- ${ECHO_CMD} -n ${DOCDIR} >> ${PLIST}
- ${ECHO_CMD} ${i} >> ${PLIST}
-.endfor
- ${ECHO_CMD} -n "@dirrm " >> ${PLIST}
- ${ECHO_CMD} ${DOCDIR} >> ${PLIST}
-.endif
-
do-install:
- ${INSTALL} -c -g wheel -o root -m 4755 ${WRKSRC}/linplasma ${PREFIX}/bin
+ ${INSTALL_PROGRAM} ${WRKSRC}/linplasma ${PREFIX}/bin
+ ${CHMOD} +s ${PREFIX}/bin/linplasma
.if !defined(NOPORTDOCS)
- ${MKDIR} ${PREFIX}/${DOCDIR}
-.for i in ${DOCFILES}
- ${INSTALL_DATA} ${WRKSRC}/${i} ${PREFIX}/${DOCDIR}
-.endfor
+ @${MKDIR} ${DOCSDIR}
+ ${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}
.endif
.include <bsd.port.mk>
diff --git a/graphics/linplasma/files/patch-Makefile b/graphics/linplasma/files/patch-Makefile
index da0bc0f23e4..393430b3ab4 100644
--- a/graphics/linplasma/files/patch-Makefile
+++ b/graphics/linplasma/files/patch-Makefile
@@ -9,7 +9,7 @@
-# optimize a lot
-CFLAGS=-O3
-+CFLAGS += -L%%PREFIX%%/lib -I%%PREFIX%%/include
++CFLAGS += -L${LOCALBASE}/lib -I${LOCALBASE}/include
LIBS=-lvga -lvgagl -lm