[Asterisk-Dev] SOLVED! Question about compiling a module for
Asterisk with CPP stuff
Leo Moll
leo at yeasoft.com
Fri Feb 4 14:17:57 MST 2005
Thank you all for trying to help me. In the meantime I'm solved the
problem and I must confess that I'm quite ashamed...
Do you note? The makefile produces two executable files: nlsTest (that's
my test console program for the function library) and app_say_pattern.so
(the application for asterisk). In the build directive for the .so
module, the $(LDFLAGS) are missing. So the stdc++ library is not linked
to my module and "new" (mangled name _Znaj) is not found.
Sorry for disturbing you... my only poor excuse is that I wrote the mail
on 02:07am and I was too tired to realize that....
Leo Moll wrote:
> In the log file I got the following error:
>
> [...]
> Here you can see an excerpt from my Makefile:
>
> CFLAGS+=-ggdb
> LDFLAGS+=-lstdc++
>
> all: nlsLib app_say_pattern.so
>
> nlsLib: nlsEngine.o nlsUtils.o nlsParser.o
> $(CC) $(CFLAGS) $(LDFLAGS) nlsEngine.o nlsUtils.o nlsParser.o -o
> nlsTest
>
> CFLAGS+=-fPIC -I$(ASTERISKINC) -DAST_CONFIG_DIR=\"$(AST_CONFIG_DIR)\"
>
> app_say_pattern.so: nlsEngine.o nlsParser.o nlsUtils.o app_say_pattern.o
> $(CC) -shared -Xlinker -x -o $@ nlsEngine.o nlsUtils.o
> app_say_pattern.o
>
>
>
> Does anyone here have an idea what I'm doing wrong? Any help would be
> greatly appreciated.
>
> Thank you in advance!
> _______________________________________________
> Asterisk-Dev mailing list
> Asterisk-Dev at lists.digium.com
> http://lists.digium.com/mailman/listinfo/asterisk-dev
> To UNSUBSCRIBE or update options visit:
> http://lists.digium.com/mailman/listinfo/asterisk-dev
More information about the asterisk-dev
mailing list