On 2007/03/25 22:01, Vlad Glagolev wrote:
> Hmm.. sorry for that but I have only i386 machine.. and also boehm-gc
> is a very difficult "thing" to setup with obsd especially on other
> platforms than i386..

yes, agreed - the version in-tree builds but I'm not sure it works very
well on those arch either (w3m is marked BROKEN for amd64/sparc64 but it's
possible <probable?> that it's actually a gc problem).

the patch for patch_mach_dep_c is missing a |, and the character
following is 0xa0; fixing this gets gc building on sparc64 ..

00000170  29 20 7c 7c 20 64 65 66  69 6e 65 64 28 46 52 45  |) || defined(FRE|
00000180  45 42 53 44 29 20 7c a0  64 65 66 69 6e 65 64 28  |EBSD) | defined(|
00000190  5f 5f 45 4c 46 5f 5f 29  0a 20 20 20 20 20 20 20  |__ELF__).       |

-#   if defined(SVR4) || defined(NETBSD) || defined(FREEBSD)
+#   if defined(SVR4) || defined(NETBSD) || defined(FREEBSD) | defined(__ELF__)

...but if I install it and then try and build w3m, the build fails like this:

cc  -I. -I. -O2 -pipe -I./libwc  -I/usr/include/openssl -I/usr/local/include 
-DHAVE_CONFIG_H -DAUXBIN_DIR=\"/usr/local/libexec/w3m\"  
-DCGIBIN_DIR=\"/usr/local/libexec/w3m/cgi-bin\" 
-DHELP_DIR=\"/usr/local/share/w3m\"  -DETC_DIR=\"/etc\" -DCONF_DIR=\"/etc/w3m\" 
 -DRC_DIR=\"~/.w3m\"  -DLOCALEDIR=\"/usr/local/share/locale\" -o mktable 
mktable.o dummy.o -L/usr/local/lib -L. -lindep -L/usr/local/lib -lintl 
-L/usr/local/lib -liconv -lm  -L/usr/local/lib -lgc
./libindep.a(Str.o)(.text+0xff0): In function `Sprintf':
: warning: vsprintf() is often misused, please use vsnprintf()
/usr/local/lib/libintl.so.3.0: warning: strcpy() is almost always misused, 
please use strlcpy()
/usr/local/lib/libgc.so.1.2: warning: sprintf() is often misused, please use 
snprintf()
sort funcname.tab | nawk -f ./functable.awk > functable.tab
./mktable 100 functable.tab > functable.c
GC Warning: GC_get_nprocs() returned -1
Segmentation fault (core dumped) 
*** Error code 139

GNU gdb 6.3
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB.  Type "show warranty" for details.
This GDB was configured as "sparc64-unknown-openbsd4.1"...
Core was generated by `mktable'.
Program terminated with signal 11, Segmentation fault.
Reading symbols from /usr/local/lib/libintl.so.3.0...done.
Loaded symbols for /usr/local/lib/libintl.so.3.0
Reading symbols from /usr/local/lib/libiconv.so.4.0...done.
Loaded symbols for /usr/local/lib/libiconv.so.4.0
Reading symbols from /usr/lib/libm.so.2.3...done.
Loaded symbols for /usr/lib/libm.so.2.3
Reading symbols from /usr/local/lib/libgc.so.1.2...done.
Loaded symbols for /usr/local/lib/libgc.so.1.2
Reading symbols from /usr/lib/libc.so.40.3...done.
Loaded symbols for /usr/lib/libc.so.40.3
Reading symbols from /usr/lib/libpthread.so.7.0...done.
Loaded symbols for /usr/lib/libpthread.so.7.0
Reading symbols from /usr/libexec/ld.so...done.
Loaded symbols for /usr/libexec/ld.so
#0  0x00000000437948c4 in GC_mark_from () from /usr/local/lib/libgc.so.1.2
(gdb) bt
#0  0x00000000437948c4 in GC_mark_from () from /usr/local/lib/libgc.so.1.2
#1  0x0000000043793c28 in GC_mark_some () from /usr/local/lib/libgc.so.1.2
#2  0x0000000043786c84 in GC_stopped_mark () from /usr/local/lib/libgc.so.1.2
#3  0x0000000043786600 in GC_try_to_collect_inner () from 
/usr/local/lib/libgc.so.1.2
#4  0x00000000437998ac in GC_init_inner () from /usr/local/lib/libgc.so.1.2
#5  0x0000000043790f3c in GC_generic_malloc_inner () from 
/usr/local/lib/libgc.so.1.2
#6  0x0000000043791230 in GC_generic_malloc () from /usr/local/lib/libgc.so.1.2
#7  0x00000000437917c8 in GC_malloc () from /usr/local/lib/libgc.so.1.2
#8  0x0000000000101d88 in Strnew_charp (p=0xffffffffffff3456 "functable.tab") 
at Str.c:66
#9  0x0000000000101258 in main (argc=3, argv=0xffffffffffff2f88, 
envp=0xffffffffffff2fa8) at mktable.c:55

(I didn't work out how to get line numbers for the libgc functions yet).

.....

back over to amd64, I just tried building again and didn't use portslogger
this time, seems I forgot to redirect stderr before (oops) so I missed this:

cc -DPACKAGE_NAME=\"gc\" -DPACKAGE_TARNAME=\"gc\" -DPACKAGE_VERSION=\"6.8\" 
"-DPACKAGE_STRING=\"gc 6.8\"" -DPACKAGE_BUGREPORT=\"[EMAIL PROTECTED]" 
-DGC_VERSION_MAJOR=6 -DGC_VERSION_MINOR=8 -DPACKAGE=\"gc\" -DVERSION=\"6.8\" 
-DSTDC_HEADERS=1 -DHAVE_SYS_TYPES_H=1 -DHAVE_SYS_STAT_H=1 -DHAVE_STDLIB_H=1 
-DHAVE_STRING_H=1 -DHAVE_MEMORY_H=1 -DHAVE_STRINGS_H=1 -DHAVE_INTTYPES_H=1 
-DHAVE_STDINT_H=1 -DHAVE_UNISTD_H=1 -DHAVE_DLFCN_H=1 -DSILENT=1 -DNO_SIGNALS=1 
-DNO_EXECUTE_PERMISSION=1 -DALL_INTERIOR_POINTERS=1 -DJAVA_FINALIZATION=1 
-DGC_GCJ_SUPPORT=1 -DATOMIC_UNCOLLECTABLE=1 -DKEEP_BACK_PTRS=1 -DDBG_HDRS_ALL=1 
-I./include -fexceptions -DGC_PTHREADS -DSIG_SUSPEND=SIGUSR2 -fexceptions -MT 
os_dep.lo -MD -MP -MF .deps/os_dep.Tpo -c os_dep.c  -fPIC -DPIC -o 
.libs/os_dep.o
os_dep.c: In function `GC_get_stack_base':
os_dep.c:1095: error: `result' undeclared (first use in this function)
os_dep.c:1095: error: (Each undeclared identifier is reported only once
os_dep.c:1095: error: for each function it appears in.)
os_dep.c: In function `GC_register_data_segments':
os_dep.c:1483: error: `DATASTART' undeclared (first use in this function)
*** Error code 1

I haven't traced this through yet though.

Reply via email to