lsmbclient compilation error
#1
Hello, I am trying to install XBMC on a Debian Lenny machine, I use the las svn tree:

Code:
svn co http://xbmc.svn.sourceforge.net/svnroot/xbmc/branches/linuxport/

When I try to make ./configure I have this error:

Code:
...
checking for main in -lsmbclient... no
configure: error: Could not find a required library. Please see the README for your platform.

I search for "lsmbclient" package and I didn't have nothing.

Can someone help me?

Thanks for all.
Reply
#2
Read the README like the error message says. You're missing a dependency.
Reply
#3
Thanks, I installed "libsmbclient-dev" and now is working, thanks.
Reply
#4
Hello again, I make "make" and I have some errors:

Quote:...
/home/lazkano/Desktop/XBMC/linuxport/XBMC/xbmc/FileSystem/FileSmb.cpp:276: undefined reference to `smbc_urlencode'
collect2: ld returned 1 exit status
make: *** [xbmc.bin] Error 1

I don't know what else install.

I search for Debian official repository, but there are not last version. Where can I find svn version repository?

Thanks for all.
Reply
#5
Your libsmbclient is broken, same deal with the one in the intrepid repos. You'll have to install it from source.
Reply
#6
Thanks for your help. Is it necesary to compile by hand the libsmbclient package?

I compile XBMC one month ago from SVN and works great.

I prefer to install from repository.

Thanks again.
Reply
#7
jlazkano Wrote:Thanks for your help. Is it necesary to compile by hand the libsmbclient package?

Yup, it appears this is the only way to get it to work. I use a debian 5 system for my PVR and have recently come across this issue.

Samba isn't /tooo/ bad though, as it by default installed in /usr/local/samba which means you can have it co-existing with the debian package without too much issue.

I compiled samba from source, version 3.4.0. (Unpack it, change to 'samba-3.4.0/source3', then './configure && make', and 'sudo make install')

Then update XBMC to the latest svn build, and cd to the xbmc/XBMC folder:-

In order to get it to configure using the correct version of samba you'll need to tell the dynamic linker to prefer the libsmbclient in /usr/local/samba/lib over the debian install one, so at the console type:-

$ export LD_LIBRARY_PATH="/usr/local/samba/lib:$LD_LIBRARY_PATH"

Then you'll need to configure XBMC:-

$ CPPFLAGS="-I/usr/local/samba/include -L/usr/local/samba/lib" ./configure

That should allow it to configure, so you can then run 'make' (note, I've never had sucess using parallel build to build XBMC, so don't use a -j argument.) In my experience at the moment this will allow the build to get all the way to the final linking stage, which will still fail with the error above. The way I fixed this was to execute the final build step manually.

When it fails, just above the error you will have a very very large g++ command, you should copy and paste this command onto the command line, but then at the begining, before the '-O2' argument, add '-L/usr/local/samba/lib' (Make sure this is in the same console session as above, otherwise you'll also need to retype the 'export' line too.)

This tells gcc to look in the correct place to link against the compiled smbclient lib, not the debian installed one. You should find this command completes sucessfully. If it does, then type 'make' to complete the rest of the build process. You should then be able to 'sudo make install' without issues.

The only additional thing to be aware of is when you run XBMC you will need to tell it where to find the new libsmbclient.so, the least intrusive way of doing this is starting XBMC via a shellscript, I use the following:-

#! /bin/sh

LD_LIBRARY_PATH="/usr/local/samba/lib:$LD_LIBRARY_PATH" /usr/local/share/xbmc/xbmc.bin


NB: The LD_LIBRARY_PATH bit is all one line.

This works for me ok.

Hope that's some use Big Grin

Ian

PS, for what it's worth, the gcc command I mentioned above for me was:

g++ -L/usr/local/samba/lib -O2 -O2 -g -D_DEBUG -Wall -o xbmc.bin -Wl,--whole-archive guilib/guilib.a guilib/common/gui_common.a guilib/tinyXML/tinyxml.a xbmc/xbmc.a xbmc/cdrip/cdrip.a xbmc/cores/cores.a xbmc/cores/DllLoader/dllloader.a xbmc/cores/DllLoader/exports/exports.a xbmc/cores/DllLoader/exports/util/exports_utils.a xbmc/cores/dvdplayer/DVDPlayer.a xbmc/cores/dvdplayer/DVDCodecs/DVDCodecs.a xbmc/cores/dvdplayer/DVDCodecs/Audio/Audio.a xbmc/cores/dvdplayer/DVDCodecs/Overlay/Overlay.a xbmc/cores/dvdplayer/DVDCodecs/Video/Video.a xbmc/cores/dvdplayer/DVDDemuxers/DVDDemuxers.a xbmc/cores/dvdplayer/DVDInputStreams/DVDInputStreams.a xbmc/cores/dvdplayer/DVDSubtitles/DVDSubtitles.a xbmc/cores/paplayer/paplayer.a xbmc/cores/AudioRenderers/audiorenderers.a xbmc/cores/VideoRenderers/VideoRenderer.a xbmc/cores/VideoRenderers/VideoShaders/VideoShaders.a xbmc/cores/ExternalPlayer/ExternalPlayer.a xbmc/FileSystem/filesystem.a xbmc/FileSystem/MusicDatabaseDirectory/musicdatabasedirectory.a xbmc/FileSystem/VideoDatabaseDirectory/videodatabasedirectory.a xbmc/karaoke/karaoke.a xbmc/lib/libcmyth/libcmyth.a xbmc/lib/libhts/libhts.a xbmc/lib/libPython/python.a xbmc/lib/libPython/xbmcmodule/xbmcmodule.a xbmc/lib/libRTMP/librtmp.a xbmc/lib/libscrobbler/scrobbler.a xbmc/lib/libRTV/librtv-i486-linux.a xbmc/lib/libshout/libshout-i486-linux.a xbmc/lib/libUPnP/libupnp-i486-linux.a xbmc/lib/libXBMS/libxbms-i486-linux.a xbmc/lib/libXDAAP/libxdaap-i486-linux.a xbmc/lib/libGoAhead/libGoAhead-i486-linux.a xbmc/lib/sqLite/sqllite.a xbmc/lib/UnrarXLib/UnrarXLib.a xbmc/linux/linux.a xbmc/screensavers/screensaver.a xbmc/settings/settings.a xbmc/utils/utils.a xbmc/visualizations/visualization.a xbmc/xbox/xbox.a -Wl,--no-whole-archive -lXrandr -lavahi-client -lavahi-common -lfaac -lpulse -lhal-storage -ldbus-1 -lcurl -lXinerama -lXmu -lXtst -lXt -lmms -ljasper -lenca -lresolv -ldl -lSDL_mixer -lSDL_image -lSDL -lsmbclient -lz -lsamplerate -lcdio -llzo2 -lpthread -lpcre -ljpeg -lpng12 -lrt -lasound -lmysqlclient -lsqlite3 -lfribidi -lbz2 -lfontconfig -lfreetype -lvorbisfile -lvorbisenc -lvorbis -logg -lmad -lGLU -lGLEW -lGL -rdynamic
Reply

Logout Mark Read Team Forum Stats Members Help
lsmbclient compilation error0