Port to amd64 (note: requires ld-elf.so bugfix to actually work)
This commit is contained in:
parent
00c9059f38
commit
123c710bd5
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=95747
4 changed files with 71 additions and 15 deletions
|
@ -28,8 +28,6 @@ MAKE_ENV= DIST=${WRKSRC}/dist
|
|||
|
||||
LIBS= libnspr4.so.1 libplc4.so.1 libplds4.so.1
|
||||
|
||||
NOT_FOR_ARCHS= amd64
|
||||
|
||||
do-install:
|
||||
${MKDIR} ${PREFIX}/include/nspr
|
||||
${TAR} -C ${WRKSRC}/dist/include --dereference -cf - . | \
|
||||
|
|
|
@ -1,19 +1,15 @@
|
|||
--- ../pr/include/md/_freebsd.cfg.orig Wed Jan 2 16:06:24 2002
|
||||
+++ ../pr/include/md/_freebsd.cfg Sun Jan 12 13:37:33 2003
|
||||
@@ -91,7 +91,7 @@
|
||||
#define PR_ALIGN_OF_DOUBLE 4
|
||||
--- ../pr/include/md/_freebsd.cfg Wed Jan 2 13:06:24 2002
|
||||
+++ ../pr/include/md/_freebsd.cfg Sat Dec 13 13:22:20 2003
|
||||
@@ -92,5 +92,5 @@
|
||||
#define PR_ALIGN_OF_POINTER 4
|
||||
|
||||
-#elif defined(__alpha)
|
||||
+#elif defined(__alpha__)
|
||||
|
||||
#define IS_LITTLE_ENDIAN 1
|
||||
#undef IS_BIG_ENDIAN
|
||||
@@ -137,6 +137,98 @@
|
||||
#define PR_ALIGN_OF_FLOAT 4
|
||||
#define PR_ALIGN_OF_DOUBLE 8
|
||||
@@ -139,4 +139,144 @@
|
||||
#define PR_ALIGN_OF_POINTER 8
|
||||
+
|
||||
|
||||
+#elif defined(__sparc64__)
|
||||
+#undef IS_LITTLE_ENDIAN
|
||||
+#define IS_BIG_ENDIAN 1
|
||||
|
@ -105,6 +101,54 @@
|
|||
+
|
||||
+#define PR_BYTES_PER_WORD_LOG2 3
|
||||
+#define PR_BYTES_PER_DWORD_LOG2 3
|
||||
|
||||
+
|
||||
+#elif defined(__amd64__)
|
||||
+#define IS_LITTLE_ENDIAN 1
|
||||
+#undef IS_BIG_ENDIAN
|
||||
+#define IS_64
|
||||
+
|
||||
+#define PR_BYTES_PER_BYTE 1
|
||||
+#define PR_BYTES_PER_SHORT 2
|
||||
+#define PR_BYTES_PER_INT 4
|
||||
+#define PR_BYTES_PER_INT64 8
|
||||
+#define PR_BYTES_PER_LONG 8
|
||||
+#define PR_BYTES_PER_FLOAT 4
|
||||
+#define PR_BYTES_PER_DOUBLE 8
|
||||
+#define PR_BYTES_PER_WORD 8
|
||||
+#define PR_BYTES_PER_DWORD 8
|
||||
+
|
||||
+#define PR_BITS_PER_BYTE 8
|
||||
+#define PR_BITS_PER_SHORT 16
|
||||
+#define PR_BITS_PER_INT 32
|
||||
+#define PR_BITS_PER_INT64 64
|
||||
+#define PR_BITS_PER_LONG 64
|
||||
+#define PR_BITS_PER_FLOAT 32
|
||||
+#define PR_BITS_PER_DOUBLE 64
|
||||
+#define PR_BITS_PER_WORD 64
|
||||
+
|
||||
+#define PR_BITS_PER_BYTE_LOG2 3
|
||||
+#define PR_BITS_PER_SHORT_LOG2 4
|
||||
+#define PR_BITS_PER_INT_LOG2 5
|
||||
+#define PR_BITS_PER_INT64_LOG2 6
|
||||
+#define PR_BITS_PER_LONG_LOG2 6
|
||||
+#define PR_BITS_PER_FLOAT_LOG2 5
|
||||
+#define PR_BITS_PER_DOUBLE_LOG2 6
|
||||
+#define PR_BITS_PER_WORD_LOG2 6
|
||||
+
|
||||
+#define PR_ALIGN_OF_SHORT 2
|
||||
+#define PR_ALIGN_OF_INT 4
|
||||
+#define PR_ALIGN_OF_LONG 8
|
||||
+#define PR_ALIGN_OF_INT64 8
|
||||
+#define PR_ALIGN_OF_FLOAT 4
|
||||
+#define PR_ALIGN_OF_DOUBLE 8
|
||||
+#define PR_ALIGN_OF_POINTER 8
|
||||
+#define PR_ALIGN_OF_WORD 8
|
||||
+
|
||||
+#define PR_BYTES_PER_WORD_LOG2 3
|
||||
+#define PR_BYTES_PER_DWORD_LOG2 3
|
||||
+
|
||||
+#define HAVE_LONG_LONG
|
||||
+#define HAVE_ALIGNED_DOUBLES
|
||||
+#define HAVE_ALIGNED_LONGLONGS
|
||||
#else
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
--- ../pr/include/md/_freebsd.h.orig Sat Feb 16 02:12:55 2002
|
||||
+++ ../pr/include/md/_freebsd.h Sun Jan 12 03:10:59 2003
|
||||
@@ -40,14 +40,19 @@
|
||||
--- ../pr/include/md/_freebsd.h Thu Jan 16 08:16:27 2003
|
||||
+++ ../pr/include/md/_freebsd.h Sat Dec 13 13:22:20 2003
|
||||
@@ -40,14 +40,21 @@
|
||||
#if __FreeBSD__ >= 2
|
||||
#include <osreldate.h> /* for __FreeBSD_version */
|
||||
#endif
|
||||
|
@ -18,6 +18,8 @@
|
|||
+#define _PR_SI_ARCHITECTURE "sparc"
|
||||
+#elif defined(__ia64__)
|
||||
+#define _PR_SI_ARCHITECTURE "ia64"
|
||||
+#elif defined(__amd64__)
|
||||
+#define _PR_SI_ARCHITECTURE "amd64"
|
||||
#else
|
||||
#error "Unknown CPU architecture"
|
||||
#endif
|
||||
|
|
12
devel/nspr/files/patch-..::pr::src::io::prprf.c
Normal file
12
devel/nspr/files/patch-..::pr::src::io::prprf.c
Normal file
|
@ -0,0 +1,12 @@
|
|||
--- ../pr/src/io/prprf.c Thu Jan 23 09:03:22 2003
|
||||
+++ ../pr/src/io/prprf.c Thu Oct 16 23:14:36 2003
|
||||
@@ -52,5 +52,8 @@
|
||||
** and requires array notation.
|
||||
*/
|
||||
-#if (defined(LINUX) && defined(__powerpc__)) || \
|
||||
+#if defined(__amd64__)
|
||||
+#include <stdarg.h>
|
||||
+#define VARARGS_ASSIGN(foo, bar) va_copy((foo), (bar))
|
||||
+#elif (defined(LINUX) && defined(__powerpc__)) || \
|
||||
(defined(LINUX) && defined(__s390__)) || \
|
||||
(defined(LINUX) && defined(__s390x__)) || \
|
Loading…
Reference in a new issue