bug-guile
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GIT version: missing linking flag


From: Hans Aberg
Subject: Re: GIT version: missing linking flag
Date: Fri, 21 Jan 2011 18:59:16 +0100

On 21 Jan 2011, at 17:02, Ludovic Courtès wrote:

Can you post the exact link command line and error message?


$ make
gcc parser.o lexer.o driver.o guile++.o guile.o exception.o tuple.o
guile-config link` -lstdc++ -o guile++

This line was mangled by your mailer, I think (missing backquote,
newline inserted).

By your mailer, I would think: when I send it to myself, it comes out right.

Furthermore, if you’re linking C++ code, then you should link with g+ +,
not gcc, and omit -lstdc++.

I do not think it matters: the linker typically supplied by the platform, is a C linker on UNIX, and gcc mangles the names of C++ into it C.

By contrast, g++ compiles also C files as C++.

Undefined symbols:
 "_GC_register_finalizer_no_order", referenced from:
     _make_c_exception in exception.o
     _make_exception in exception.o
     _make_tuple in tuple.o
ld: symbol(s) not found

Oooh, I finally got your point about SCM_NEWSMOB.  It introduces a
direct dependency from your app on libgc, which can require -lgc,
depending on the linker.

Right.

I’ll look into it.  I think the GC_REGISTER_FINALIZER_NO_ORDER call
should be buried in a function akin to scm_i_new_smob_with_mark_proc.

If it is needed at all, by the comment in gc/gc.h something that it is for Java code.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]