aboutsummaryrefslogtreecommitdiff
path: root/devel/asmutils
diff options
context:
space:
mode:
authorAlexey Dokuchaev <danfe@FreeBSD.org>2005-01-26 10:40:28 +0000
committerAlexey Dokuchaev <danfe@FreeBSD.org>2005-01-26 10:40:28 +0000
commitb86efc59a4614a0709960642323a25dd33b7a1e7 (patch)
treed6314c6eaaa9fd114b3d193134c49ceabd924008 /devel/asmutils
parent00023e91a0fd9d1187a1f06bf0d3e0ce4c651609 (diff)
downloadports-b86efc59a4614a0709960642323a25dd33b7a1e7.tar.gz
ports-b86efc59a4614a0709960642323a25dd33b7a1e7.zip
- Fix build and install on 4.X/5.X/-CURRENT
- Utilize REINPLACE - Tidy up Makefile - Take maintainership
Notes
Notes: svn path=/head/; revision=127407
Diffstat (limited to 'devel/asmutils')
-rw-r--r--devel/asmutils/Makefile25
-rw-r--r--devel/asmutils/files/patch-lib_testm.c26
2 files changed, 37 insertions, 14 deletions
diff --git a/devel/asmutils/Makefile b/devel/asmutils/Makefile
index c950a73b034b..308262c7469f 100644
--- a/devel/asmutils/Makefile
+++ b/devel/asmutils/Makefile
@@ -1,17 +1,16 @@
-# New ports collection makefile for: asmutils
-# Date created: 22 January 2001
-# Whom: George Reid <greid@ukug.uk.freebsd.org>
+# New ports collection makefile for: asmutils
+# Date created: 22 January 2001
+# Whom: George Reid <greid@ukug.uk.freebsd.org>
#
# $FreeBSD$
#
PORTNAME= asmutils
PORTVERSION= 0.17
-PORTREVISION= 0
CATEGORIES= devel
MASTER_SITES= http://linuxassembly.org/asmutils/
-MAINTAINER= ports@FreeBSD.org
+MAINTAINER= danfe@FreeBSD.org
COMMENT= A set of UNIX utilities written in assembly language
BUILD_DEPENDS= nasm:${PORTSDIR}/devel/nasm
@@ -19,6 +18,7 @@ BUILD_DEPENDS= nasm:${PORTSDIR}/devel/nasm
ONLY_FOR_ARCHS= i386
USE_GMAKE= yes
+USE_REINPLACE= yes
INSTALLS_SHLIB= yes
LDCONFIG_DIRS= ${PREFIX}/lib/asmutils
@@ -34,15 +34,12 @@ PORTDOCS= Asmutils-HOWTO.html acknowledgements.html endorsements.html \
history.html index.html s-contrib.html s-debug.html \
s-include.html s-layout.html s-optimize.html
-.include <bsd.port.pre.mk>
-
-.if ${OSVERSION} >= 502119
-BROKEN= "Does not install on FreeBSD >= 5.x"
-.endif
-
post-patch:
- @(${SED} -e 's,%%KERNEL%%,${OSREL:S/.//g},g' ${WRKSRC}/MCONFIG > ${WRKDIR}/foo \
- && ${MV} ${WRKDIR}/foo ${WRKSRC}/MCONFIG)
+ @${REINPLACE_CMD} -e 's,%%KERNEL%%,${OSREL:S/.//g},g' ${WRKSRC}/MCONFIG
+ @${REINPLACE_CMD} -e 's,m386,march=i386,' ${WRKSRC}/lib/Makefile
+
+# Stripping binaries will break install
+.undef STRIP
do-install:
${MKDIR} ${PREFIX}/bin/asmutils
@@ -68,4 +65,4 @@ do-install:
.endfor
.endif
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>
diff --git a/devel/asmutils/files/patch-lib_testm.c b/devel/asmutils/files/patch-lib_testm.c
new file mode 100644
index 000000000000..f677332c498e
--- /dev/null
+++ b/devel/asmutils/files/patch-lib_testm.c
@@ -0,0 +1,26 @@
+--- lib/testm.c.orig Fri Jul 20 14:02:56 2001
++++ lib/testm.c Wed Jan 26 15:35:47 2005
+@@ -16,10 +16,22 @@
+ # define __USE_BSD 1
+ # define __USE_XOPEN 1
+ # define __USE_SVID 1
+-#include <math.h>
+ #include <stdio.h>
+ #include <stdlib.h>
+ #include <assert.h>
++
++#define M_LOG2E 1.4426950408889634074 /* log 2e */
++#define M_LOG10E 0.43429448190325182765 /* log 10e */
++#define M_LN2 0.69314718055994530942 /* log e2 */
++#define M_LN10 2.30258509299404568402 /* log e10 */
++#define M_E 2.7182818284590452354 /* e */
++#define M_PI 3.14159265358979323846 /* pi */
++#if __FreeBSD_version < 501103
++extern char __infinity[];
++#define HUGE_VAL (*(double *) __infinity)
++#else
++#define HUGE_VAL __builtin_huge_val()
++#endif
+
+ #ifndef NAN
+ #define NAN (0./0.)