aboutsummaryrefslogtreecommitdiff
path: root/misc/free42
diff options
context:
space:
mode:
authorYuri Victorovich <yuri@FreeBSD.org>2018-07-12 05:07:41 +0000
committerYuri Victorovich <yuri@FreeBSD.org>2018-07-12 05:07:41 +0000
commit5fae1e2882185d329d415be6fe8736a3e05154a5 (patch)
treeac92b8710b8098e3285ae6ddfd0e3e62279abc4b /misc/free42
parentbf1feb7b592c3a309aad8d295e25c416ad6ab838 (diff)
downloadports-5fae1e2882185d329d415be6fe8736a3e05154a5.tar.gz
ports-5fae1e2882185d329d415be6fe8736a3e05154a5.zip
misc/free42: Add another supported variant of the same program: free42dec
Requested by: Bas Rothuizen <basber@xs4all.nl> (user; via e-mail)
Notes
Notes: svn path=/head/; revision=474484
Diffstat (limited to 'misc/free42')
-rw-r--r--misc/free42/Makefile26
-rw-r--r--misc/free42/files/patch-gtk_IntelRDFPMathLib20U1_LIBRARY_float128_architecture.h11
-rw-r--r--misc/free42/pkg-plist6
3 files changed, 29 insertions, 14 deletions
diff --git a/misc/free42/Makefile b/misc/free42/Makefile
index a55c052199e5..d1386de0e881 100644
--- a/misc/free42/Makefile
+++ b/misc/free42/Makefile
@@ -2,6 +2,7 @@
PORTNAME= free42
DISTVERSION= 2.0.21
+PORTREVISION= 1
CATEGORIES= misc
MASTER_SITES= http://thomasokken.com/free42/upstream/
DISTNAME= ${PORTNAME}-nologo-${DISTVERSION}
@@ -23,26 +24,35 @@ LIB_DEPENDS= libfontconfig.so:x11-fonts/fontconfig \
USES= dos2unix gmake localbase pkgconfig tar:tgz
USE_GNOME= atk cairo gdkpixbuf2 glib20 gtk20 pango
USE_XORG= x11 xmu
-DOS2UNIX_FILES= gtk/IntelRDFPMathLib20U1/LIBRARY/float128/op_system.h
+DOS2UNIX_FILES= gtk/IntelRDFPMathLib20U1/LIBRARY/float128/op_system.h gtk/IntelRDFPMathLib20U1/LIBRARY/float128/architecture.h
CXXFLAGS+= -Wno-c++11-narrowing -Wno-constant-conversion # to accommodate some code breaking with clang-50
BUILD_WRKSRC= ${WRKSRC}/gtk
+VARIANTS= bin dec
+
+.for v in ${VARIANTS}
+PLIST_FILES+= bin/${PORTNAME}${v}
+.endfor
+
post-extract:
@cd ${BUILD_WRKSRC} && tar xvfz ../inteldecimal/IntelRDFPMathLib20U1.tar.gz
post-patch:
- @${REINPLACE_CMD} -e 's|snprintf(free42dirname, FILENAMELEN, "%s/\.free42", home)|strcpy(free42dirname, "${DATADIR}")|' \
- ${BUILD_WRKSRC}/shell_main.cc
+ @${REINPLACE_CMD} -e 's|(free42dirname)|("${DATADIR}/skins")|' \
+ ${BUILD_WRKSRC}/shell_skin.cc
do-build:
- @cd ${BUILD_WRKSRC} && \
+.for v in ${VARIANTS}
+ @${CP} -r ${BUILD_WRKSRC} ${BUILD_WRKSRC}-${v}
+ @cd ${BUILD_WRKSRC}-${v} && \
${SETENV} ${MAKE_ENV} ${MAKE_CMD} cleaner && \
- ${SETENV} ${MAKE_ENV} ${MAKE_CMD}
- # TODO do we need decimal fp arithmetic?: ${MAKE_CMD} BCD_MATH=1 SKIN_SYS_DIR="${DATADIR}"
+ ${SETENV} ${MAKE_ENV} ${v:S/dec/BCD_MATH=1/:S/bin//} ${MAKE_CMD}
+.endfor
do-install:
- ${INSTALL_PROGRAM} ${BUILD_WRKSRC}/free42bin ${STAGEDIR}${PREFIX}/bin/
- @cd ${WRKSRC} && ${COPYTREE_SHARE} skins ${STAGEDIR}${DATADIR}
+.for v in ${VARIANTS}
+ ${INSTALL_PROGRAM} ${BUILD_WRKSRC}-${v}/free42${v} ${STAGEDIR}${PREFIX}/bin/
+.endfor
.include <bsd.port.mk>
diff --git a/misc/free42/files/patch-gtk_IntelRDFPMathLib20U1_LIBRARY_float128_architecture.h b/misc/free42/files/patch-gtk_IntelRDFPMathLib20U1_LIBRARY_float128_architecture.h
new file mode 100644
index 000000000000..91cc9fc65619
--- /dev/null
+++ b/misc/free42/files/patch-gtk_IntelRDFPMathLib20U1_LIBRARY_float128_architecture.h
@@ -0,0 +1,11 @@
+--- gtk/IntelRDFPMathLib20U1/LIBRARY/float128/architecture.h.orig 2018-07-12 01:32:53 UTC
++++ gtk/IntelRDFPMathLib20U1/LIBRARY/float128/architecture.h
+@@ -364,7 +364,7 @@
+
+
+
+-#elif (defined(_M_IX86) || defined(ix86) || defined(IX86) || defined(ia32) )
++#elif (defined(_M_IX86) || defined(ix86) || defined(IX86) || defined(ia32) || defined(__i386__))
+
+ # undef vax
+ # undef mips
diff --git a/misc/free42/pkg-plist b/misc/free42/pkg-plist
deleted file mode 100644
index 347cdc09568f..000000000000
--- a/misc/free42/pkg-plist
+++ /dev/null
@@ -1,6 +0,0 @@
-bin/free42bin
-share/free42/skins/Ehrling42sl.gif
-share/free42/skins/Ehrling42sl.layout
-share/free42/skins/README.txt
-share/free42/skins/Standard.gif
-share/free42/skins/Standard.layout