Hi! I've made a patch to peercast makefile for linux in order to have it built with shared libraries.
Then I'll modify my package in order to build a libpeercast and libpeercast-dev that gnome peercast coul use for its package. The patch applies to peercast last trunk, and has been submitted to peercast upstream for an include. Romain -- If you are the big tree, We are the small axe, Ready to cut you down, Sharpen to cut you down....
--- trunk.orig/ui/linux/makefile 2005-06-10 15:34:32.000000000 +0200 +++ trunk/ui/linux/makefile 2005-06-15 01:56:14.000000000 +0200 @@ -1,5 +1,6 @@ CPPFLAGS = -DENABLE_BINRELOC -pthread -D__cplusplus -D_UNIX -D_REENTRANT $(INCLUDES) LDFLAGS = -pthread +LDSOFLAGS = -shared -Wl,-soname #CPPFLAGS = -static -pthread -D__cplusplus -D_UNIX -D_LINUX_STATIC -D_REENTRANT $(INCLUDES) #LDFLAGS = -static -pthread @@ -10,15 +11,14 @@ INCLUDES = -I../../core -I../../core/common -# Library and include paths. -LIBS = - TARGET = peercast CORE = ../../core SRCHTML = ../html HTML = html +LIBSONAME = libpeercast.so.1 +LIBOBJ = libpeercast.so.1.0 CORESOURCE = $(CORE)/unix/usys.cpp \ $(CORE)/unix/usocket.cpp \ @@ -73,7 +73,7 @@ tar -czf $(TAR) $(HTML) $(TARGET) clean: - rm -f $(LINUXOBJ) $(COREOBJ) $(TARGET) + rm -f $(LINUXOBJ) $(COREOBJ) $(TARGET) ${LIBOBJ} %.o: %.cpp $(CC) $(INCLUDES) $(CPPFLAGS) -c $< -o $@ @@ -85,8 +85,9 @@ echo > $(DEPENDFILE) $(CC) $(INCLUDES) $(CPPFLAGS) -MD $(CORESOURCE) $(LINUXSOURCE) >> $(DEPENDFILE) -$(TARGET): $(LINUXOBJ) $(COREOBJ) - $(LD) $(LDFLAGS) -o $@ $(LINUXOBJ) $(COREOBJ) $(LIBS) +$(TARGET): $(COREOBJ) $(LINUXOBJ) + $(LD) $(LDSOFLAGS),${LIBSONAME} -o ${LIBOBJ} $(COREOBJ) -lc + $(LD) $(LDFLAGS) -o $@ $(LINUXOBJ) $(LIBOBJ) -ldl include $(DEPENDFILE) --- trunk.orig/ui/linux/install.sh 2005-06-10 15:34:32.000000000 +0200 +++ trunk/ui/linux/install.sh 2005-06-15 02:11:02.000000000 +0200 @@ -22,21 +22,27 @@ insdir=$PREFIX/sbin sharedir=$PREFIX/share/peercast -libdir=$PREFIX/lib/peercast +libdir=$PREFIX/lib +peercastlibdir=$libdir/peercast kdedir=$KDEPREFIX/share/services echo "Doing the install.." echo "- Peercast bin and file." -mkdir -p $sharedir $libdir $insdir $libdir $kdedir +mkdir -p $sharedir $insdir $peercastlibdir $kdedir cp -f ./peercast $insdir +cp -f ./libpeercast.so.1.* $libdir +echo "Please, make sure that the directory for shared library is listed in known by ldconfig" +echo "Else, use this command: export LD_LIBRARY_PATH=$libdir:\$LD_LIBRARY_PATH" +echo "Before launching peercast." +/sbin/ldconfig -n $libdir cp -rf ./../html $sharedir chmod +x $insdir/peercast echo "- installing peercast protocol handler." echo "-> peercast:// handling scripts" -cp -rf ./scripts $libdir +cp -rf ./scripts $peercastlibdir echo "* Setting correct prefix for scripts" rm -f $libdir/scripts/peercast_khandler.sh cat ./scripts/peercast_khandler.sh | sed -e s#/usr/local#$PREFIX# > $libdir/scripts/peercast_khandler.sh
pgpPDC8tPHPyu.pgp
Description: PGP signature