This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |
| Other format: | [Raw text] | |
On Thu, Aug 24, 2017 at 3:19 AM, Uros Bizjak <ubizjak@gmail.com> wrote: > Hello! > > Following carchive gotools tests fail in gccgo testsuite: > > FAIL: TestCgoCallbackGC > FAIL: TestInstall > FAIL: TestEarlySignalHandler > FAIL: TestSignalForwarding > FAIL: TestSignalForwardingExternal > FAIL: TestOsSignal > FAIL: TestSigaltstack > FAIL: TestPIE > > The problem can be seen from the gotools log dump: > > === RUN TestInstall > FAIL: TestInstall > carchive_test.go:160: [gcc -fPIC -m64 -pthread > -fmessage-length=0 > -fdebug-prefix-map=/tmp/go-build828417309=/tmp/go-build > -gno-record-gcc-switches -funwind-tables -I pkg/gccgo_linux_amd64_fPIC > -o ./testp1 main.c main_unix.c pkg/gccgo_linux_amd64_fPIC/liblibgo.a > -lgo] > carchive_test.go:162: > pkg/gccgo_linux_amd64_fPIC/liblibgo.a(a.out.a.o): In function > `__go_init_main': > /tmp/go-build/libgo/_obj/_cgo_gotypes.go:3: undefined > reference to `runtime.registerGCRoots' > pkg/gccgo_linux_amd64_fPIC/liblibgo.a(a.out.a.o): In > function `__go_init_main': > > /home/uros/gcc-build/gotools/carchive-test-dir/misc/cgo/testcarchive/src/libgo/libgo.go:18: > undefined reference to `runtime.writeBarrier' > > /home/uros/gcc-build/gotools/carchive-test-dir/misc/cgo/testcarchive/src/libgo/libgo.go:18: > undefined reference to `runtime.writebarrierptr' > pkg/gccgo_linux_amd64_fPIC/liblibgo.a(a.out.a.o): In > function `gostart': > > /home/uros/gcc-build/x86_64-pc-linux-gnu/libgo/../../../git/gcc/libgo/runtime/go-libmain.c:111: > undefined reference to `runtime.schedinit' > > /home/uros/gcc-build/x86_64-pc-linux-gnu/libgo/../../../git/gcc/libgo/runtime/go-libmain.c:112: > undefined reference to `runtime.main' > collect2: error: ld returned 1 exit status > carchive_test.go:163: exit status 1 > > The compiler in carchive_test.go:160 is called with the following command: > > gcc -fPIC -m64 -pthread -fmessage-length=0 > -fdebug-prefix-map=/tmp/go-build828417309=/tmp/go-build > -gno-record-gcc-switches -funwind-tables -I pkg/gccgo_linux_amd64_fPIC > -o ./testp1 main.c main_unix.c pkg/gccgo_linux_amd64_fPIC/liblibgo.a > -lgo > > Please note that with -lgo, the default system-wide libgo shared > library is linked in. However, the test expects newly compiled library > from the libgo build directory. Manually adding correct -L path to the > above command builds functional executable. > > (The system-wide library in the above example is installed from the > current gcc-7 branch). Thanks. I have committed this patch which should fix the problem. Bootstrapped and tested on x86_64-pc-linux-gnu. Ian 2017-08-30 Ian Lance Taylor <iant@google.com> * configure.ac: Substitute GOC_FOR_TARGET and GCC_FOR_TARGET. * Makefile.am (MOSTLYCLEANFILES): Add check-gcc. (check-gccgo): Create via a temporary file. (check-gcc): New target. (CHECK_ENV): Set CC. (ECHO_ENV): Report CC. (check-go-tool): Depend on check-gcc. (check-runtime, check-cgo-test, check-carchive-test): Likewise. * configure, Makefile.in: Rebuild.
Attachment:
patch.txt
Description: Text document
| Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
|---|---|---|
| Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |