Page 1 of 1

Adding extras libraries to VLC

Posted: 05 Oct 2007 14:35
by robcan12345
Hi,
I have compiled vlc 0.8.4 for winCE and it works correctly. I have to add some libraries to add SIP functionality to VLC. I have installed these libraries in /usr/local/sip/lib, and header files are in /usr/local/sip/include. The names are pjlib.a and pjlib_util.a;
I show you the configuration script:

#!bin/bash
./bootstrap &&
PATH=/usr/local/wince/cross-tools/bin:$PATH \
CFLAGS="-D__stdcall= -D_OFF_T_ -I/usr/local/wince/cross-tools/include" \
CFLAGS="$CFLAGS -I/usr/local/wince/contrib-xscale/include -I/usr/local/sip/include" \
LDFLAGS="-L/usr/local/wince/cross-tools/lib -L/usr/local/wince/contrib-xscale/lib -L/usr/local/sip/lib" \
LDLIBS="-lpjlib -lpjlib_util" \
CC="arm-wince-pe-gcc -mcpu=xscale" \
./configure --host=arm-wince-pe --target=arm-wince-pe \
--build=i686-linux --prefix=/usr/local/wince/cross-tools \
--disable-sdl --disable-gtk --disable-dvdnav --disable-dvdread \
--disable-nls --disable-sout --disable-vlm --disable-wxwindows \
--disable-a52 --disable-libmpeg2 --disable-freetype --disable-fribidi \
--disable-mad --disable-plugins --enable-optimize-memory \
--with-freetype-config-path=/usr/local/wince/contrib-xscale/bin \
--with-fribidi-config-path=/usr/local/wince/contrib-xscale/bin \
--enable-tremor --enable-faad

When i execute make, the compiler find only header files, but it give me e message "Undefined reference to..." for every function i add to the code.
How can i do to link these libraries? I have tried also to add .a files in extra/contrib/lib directories!
Please help me!!!

Re: Adding extras libraries to VLC

Posted: 06 Oct 2007 16:36
by RĂ©mi Denis-Courmont
you need to modify configure.ac to add whatever appropriate LDFLAGS to the appropriate plugin (VLC_ADD_LDFLAGS).

Re: Adding extras libraries to VLC

Posted: 08 Oct 2007 06:06
by Jean-Baptiste Kempf
Cool, are you going to contribute that ?

Re: Adding extras libraries to VLC

Posted: 08 Oct 2007 11:47
by robcan12345
VLC_ADD_LDFLAGS has 2 parameters; the second is the name of the library; but the first? i have not understood!!!!!

Re: Adding extras libraries to VLC

Posted: 08 Oct 2007 17:27
by robcan12345
I have tried, but i receive always the message:

/DEFAULTLIB:"coredll.lib" /DEFAULTLIB:"corelibc.lib" unrecognized

Please tell me something

Re: Adding extras libraries to VLC

Posted: 09 Oct 2007 03:36
by funman
VLC_ADD_LDFLAGS([dvd dvdcss vcd cdda vcdx cddax],[-ldvd])

the first argument is the list of modules you want to add LDFLAGS to (linker dynamic flags)
the second is the argument you pass to the linker when building them

Re: Adding extras libraries to VLC

Posted: 11 Oct 2007 11:01
by junkie_crew
Have you managed to make it work on a real target ?

I have also compiled vlc-0.8.4 for WinCE but the executable I have got cannot run neither on an emulator nor on a smartphone...
Could you give me/us a HOWTO file with the things to modify and the compiler configurations ?

Thanks !

Re: Adding extras libraries to VLC

Posted: 11 Oct 2007 14:12
by robcan12345
I have posted my configuration file; you can copy and use it (delete -L/usr/sip/lib)! I have tried the executable on a pocket pc (Model compaq h3970) and it works correctly!

Re: Adding extras libraries to VLC

Posted: 11 Oct 2007 14:31
by junkie_crew
What about ffmpeg ? Did you cross compile it also for WinCE ? I have tried once, but I could not manage to do that... Would it be possible that you post this too ?

Re: Adding extras libraries to VLC

Posted: 13 Oct 2007 12:02
by robcan12345
I have taken all necessary libraries from this link:

http://download.videolan.org/pub/testin ... in.tar.bz2

In this package all libraries are already compiled (included ffmpeg [libavcodec.a]).
The content of this package have to be copied in ..../vlc-0.8.4/extras/contrib.

Re: Adding extras libraries to VLC

Posted: 13 Oct 2007 12:14
by robcan12345
I have tried to modify configure.ac but the result is the same!!!
I have created an example library and it is located in /usr/librerquad/lib and headers are in /usr/librerquad/include. The name is libquadutil.a
I have added CFLAGS="-I/usr/librerquad/include" and LFLAGS="-L/usr/librerquad/lib -lquadutil" in the configuration script.
I have added a call to function 'quadrato',located in the library, in the file /modules/gui/wince/interface.cpp

The result of compilation is:
Warning: .drective '/DEFAULTLIB:"coredll.lib" /DEFAULTLIB:"corelibc.dll" ' unrecognized
Warning: .drective '/DEFAULTLIB:"coredll.lib" /DEFAULTLIB:"corelibc.dll" ' unrecognized
Warning: .drective '/DEFAULTLIB:"coredll.lib" /DEFAULTLIB:"corelibc.dll" ' unrecognized
./modules/gui/wince/libwince.a(libwince_a-interface.o):interface.cpp:(.text+0x16d4): undefined reference to 'quadrato(int)'
collect2: ld returned 1 exit status

PLEASE HELP ME!!!!!!!

Re: Adding extras libraries to VLC

Posted: 15 Oct 2007 16:41
by robcan12345
Someone can help me? please,is very important for me!!!

Re: Adding extras libraries to VLC

Posted: 11 Feb 2009 04:11
by wssoh85
Hi, I wanna ask that is the adding of PJSIP library into vlc has success? Is VLC able to support for sip now?

I also need the guide to add in SIp library in VLC.

Anyone please help.

Thanks

Re: Adding extras libraries to VLC

Posted: 11 Feb 2009 09:22
by Jean-Baptiste Kempf
Hi, I wanna ask that is the adding of PJSIP library into vlc has success? Is VLC able to support for sip now?

I also need the guide to add in SIp library in VLC.

Anyone please help.

Thanks
Now, it doesn't support it, but it could. VLC as a SIP client or a SIP server?

Re: Adding extras libraries to VLC

Posted: 11 Feb 2009 14:08
by wssoh85
Hi, I wanna VLC to be a client.

I decide to use the pjsip library as my sip library, but the problem is I do not know the proper way to include a new library into the vlc. my problem is how to modify Makefile and configure.ac

Thanks for you reply .:)

Re: Adding extras libraries to VLC

Posted: 11 Feb 2009 15:16
by xtophe
read HACKING at the root of the sources