[squid-users] Editing Makefile.am to include static libraries
squid3 at treenet.co.nz
Mon Mar 16 06:07:46 UTC 2015
On 16/03/2015 6:36 p.m., Priya Agarwal wrote:
> I am now linking the libraries during ./configure with LDFLAGS, LIBS and
> CXXFLAGS options (Makefile.am is same as it was) Compile is failing
> main.o: In function `of_init':
> undefined reference to `of_init_path(char const*)'
> collect2: error: ld returned 1 exit status
> powerpc-fsl_networking-linux-libtool: link: rm -f ".libs/squidS.o"
> Does it mean I haven't linked the the library that has of_init() [But I
> think I have done that as ./configure passed and libraries are even visible
> in log]
> Or I need to link something else?
Close. It means that the libraries listed on the command line after the
main.o object do not define that symbol.
Its possible the library was linked first or via the wrong variable. Or
that the C++ symbol mangling is different between what is wanted and
what the library defines.
> Here are the flags passed to ./configure:
> EXTRA_OECONF_append = " LDFLAGS="-L=/usr/lib/" \
> LIBS="-lusdpaa_dma -lusdpaa_dma_mem -lusdpaa_of -lusdpaa_fman
> -lusdpaa_qbman -lusdpaa_syscfg" \
I see 12 separate command line arguments there. Not the 3 that should exist.
Hint: shell expansion is applied to " symbols on the ./configure command
More information about the squid-users