summaryrefslogtreecommitdiff
path: root/pkgtools
diff options
context:
space:
mode:
authorgrant <grant>2003-04-27 16:42:29 +0000
committergrant <grant>2003-04-27 16:42:29 +0000
commitecd84a5f056703115e851394a6258310b7df09ba (patch)
treeef0c6cdce8f95af2faa9b7adbc181264576f8b9d /pkgtools
parent0524fca9c5642b7a1f354b0199182a19b934740e (diff)
downloadpkgsrc-ecd84a5f056703115e851394a6258310b7df09ba.tar.gz
work around the need for rpl_malloc (induced by config.h), since we
don't need a GNU compatible malloc() here. a GNU compatible malloc() is still used in libnbcompat.a if it is required. fixes build on (at least) Tru64.
Diffstat (limited to 'pkgtools')
-rw-r--r--pkgtools/libnbcompat/files/bits.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/pkgtools/libnbcompat/files/bits.c b/pkgtools/libnbcompat/files/bits.c
index b0d2ebf469c..efffc275214 100644
--- a/pkgtools/libnbcompat/files/bits.c
+++ b/pkgtools/libnbcompat/files/bits.c
@@ -33,7 +33,7 @@
#include "config.h"
#if 0
-__RCSID("$Id: bits.c,v 1.1.1.1 2003/03/31 05:02:23 grant Exp $");
+__RCSID("$Id: bits.c,v 1.2 2003/04/27 16:42:29 grant Exp $");
#endif
#include <stdio.h>
#include <string.h>
@@ -57,6 +57,15 @@ __RCSID("$Id: bits.c,v 1.1.1.1 2003/03/31 05:02:23 grant Exp $");
} \
}
+/*
+ * work around rpl_malloc from config.h, since we don't need the
+ * replacement malloc() here
+ */
+#if ! HAVE_MALLOC
+#undef malloc
+void *malloc();
+#endif
+
#ifndef HAVE___ATTRIBUTE__
#define __attribute__(x)
#endif
@@ -118,7 +127,7 @@ int main(int argc, char **argv)
}
fprintf(f, "/* %s -- this file was generated by\n", fn);
fprintf(f, " %*s %s */\n\n", (int)strlen(fn), "",
- "$Id: bits.c,v 1.1.1.1 2003/03/31 05:02:23 grant Exp $");
+ "$Id: bits.c,v 1.2 2003/04/27 16:42:29 grant Exp $");
fprintf(f, "#ifndef %s\n", hb);
fprintf(f, "#define %s\n", hb);
fprintf(f, "\n");