Re: [gdome]Static linking of libraries



The error which comes now is as follows 

"error while loading shared libraries: libgdome.so.0
cannot open shared object file: No such file or
directory" 

Here is my makefile (with comments added). 

GDOME_LIBS= \
    -L/home/myProj/gdome2-0.8.0/lib \
    -L/usr/local/lib \
    -L/usr/lib \
# I assume the line below is linking statically.
# I tried reversing the order of libraries too. But
the
# error says that it is still referring on the shared 
# library
    -lgdome -lxml2 -lglib -lz -lpthread -lm

GDOME_INCLUDEDIR=\
    -I/home/myProj/gdome2-0.8.0/include \
    -I/home/myProj/gdome2-0.8.0/include/libgdome \
    -I/usr/include/glib-1.2 \
    -I/usr/lib/glib/include \
    -I/usr/local/include/libxml2

INSTALLDIR = $/home/myProj/gdome2-0.8.0/test/bin

CFLAGS =  $(OSFLAGS) $(GDOME_INCLUDEDIR)

TARGET    = $(INSTALLDIR)/testgdome

OBJECTS   = \
        testgdome.o

all:        $(TARGET)

$(TARGET):  $(OBJECTS)
        $(CC) -o $@ $(OBJECTS) $(GDOME_LIBS)

clean:
        rm -f a.out core *~ \#* *.bak $(TARGET) $(OBJECTS)

__________________________________
Do you Yahoo!?
Yahoo! Finance: Get your refund fast by filing online.
http://taxes.yahoo.com/filing.html



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