pkgsrc/sysutils/cpuburn/patches/patch-aa
abs 957792d48d Updated cpuburn to 1.4nb2
Nuke -nostdlib and play some define games to ensure we have a 'main'
	instead of '_start', so the binary includes the NetBSD ELF note and
	runs correctly.
2002-09-17 17:02:30 +00:00

18 lines
448 B
Text

$NetBSD: patch-aa,v 1.2 2002/09/17 17:02:30 abs Exp $
--- Makefile.orig Sat Jun 16 04:39:17 2001
+++ Makefile
@@ -1,3 +1,12 @@
+OPSYS!= uname -s
+# On NetBSD -nostdlib will exclude the ELF note that tags binaries as native.
+.if (${OPSYS} == NetBSD)
+COMPILEFLAGS=-D_main=main -DWINDOWS
+.else
+COMPILEFLAGS=-nostdlib
+.endif
+
all : burnP5 burnP6 burnK6 burnK7 burnBX burnMMX
+
.S:
- gcc -s -nostdlib -o $@ $<
+ gcc -s ${COMPILEFLAGS} -o $@ $<