I replaced ‘-KPIC’ with ‘-fPIC’ in all instances in the files that you listed.
Start from a new build/; configure … ; make —> still get the same error. Then after the above failure, I noticed: libtool —config | grep pic_flag pic_flag= “ -KPIC -DPIC” libtool —config | grep CC CC=“cc” So, something is not right with these configuration variables. I am not familiar with libtool. And I tried to set export CC=gcc export pic_flag=“ -fPIC -DPIC” These did not help. Any suggestions ? hp > On Jun 29, 2016, at 8:43 PM, George Neuner <[email protected]> wrote: > > > On 6/29/2016 6:00 PM, [email protected] <mailto:[email protected]> wrote: >> I downloaded racket 6.5 sources >> to a Sun's Sparc machine running Solaris (SunOS 5.11) >> gcc version = 4.8.1 >> >> in the build directory, I did these two steps: >> ../configure --prefix=/a/path --enable-shared >> make >> >> --> It exited with the following error message: >> >> cd sgc; make ../libmzgc.la >> make[7]: Entering ... build/racket/sgc' >> libtool --mode=compile ... -o sgc.lo >> mkdir .libs >> gcc -Wall ... -KPIC -DPIC -c .../sgc.c -o .libs/sgc.o >> gcc: error: unrecognized command line option '-KPIC' >> ... >> >> I tried to look for where the option '-KPIC' was located in >> the Makefiles --> but I could not find it. >> >> Any idea what happened and how I can proceed ? >> >> thanks >> HP > > Back in the 90's I worked with SunOS5/Solaris, but this is a new one for me. > :-) > > A little searching turned up that -KPIC / -Kpic tells the Sun C compiler to > produce position independent code - the case of the flag determines the > maximum size of the global offset table. The equivalent GCC flags are > -fPIC / -fpic ... you *might* be able to get away with fixing up the > makefile(s), if there are no other CC specific options. Otherwise, you can > try changing the configuration files [below] in the sections pertaining to > Solaris and/or SunOS, and then run configure again to start over. > > A grep of the [full] 6.5 release sources found the -KPIC option referenced > in the following files: > > racket-6.5\src\foreign\libffi\configure > racket-6.5\src\foreign\libffi\m4\libtool.m4 > racket-6.5\src\lt\aclocal.m4 > racket-6.5\src\lt\configure > racket-6.5\src\racket\gc\configure > racket-6.5\src\racket\gc\doc\README.DGUX386 > racket-6.5\src\racket\gc\libtool.m4 > > > Obviously the Racket build maintainers will have to fix this at the > configuration level. > > Hope this helps, > George -- You received this message because you are subscribed to the Google Groups "Racket Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.

