[squid-users] Editing Makefile.am to include static libraries

Priya Agarwal priya_agarwal at students.iitmandi.ac.in
Fri Mar 13 11:28:09 UTC 2015


I tried what you advised. Getting the same error for both methods
(./configure LDFLAGS=-L<../tmp/../lib CXXFLAGS=-I<.../tmp../include or
editing Makefile.am appropriately). autoreconf is failing.
And also I am getting many such warnings:

| src/Common.am:16: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS'
(or '*_CPPFLAGS')
| compat/Makefile.am:5:   'src/Common.am' included from here
| src/Common.am:16: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS'
(or '*_CPPFLAGS')
| helpers/basic_auth/DB/Makefile.am:1:   'src/Common.am' included from here
| src/Common.am:16: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS'
(or '*_CPPFLAGS')
| helpers/basic_auth/LDAP/Makefile.am:1:   'src/Common.am' included from
here
| src/Common.am:16: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS'
(or '*_CPPFLAGS')
| helpers/basic_auth/MSNT-multi-domain/Makefile.am:1:   'src/Common.am'
included from here
| src/Common.am:16: warning: 'INCLUDES' is the old name for 'AM_CPPFLAGS'
(or '*_CPPFLAGS')

Final error:
| autoreconf: automake failed with exit status: 1
| ERROR: autoreconf execution failed.

So is something wrong with the path?

I have attached the logfile as well which shows the detailed output.




On Fri, Mar 13, 2015 at 3:24 PM, Amos Jeffries <squid3 at treenet.co.nz> wrote:

> On 13/03/2015 10:19 p.m., Priya Agarwal wrote:
> > Hi,
> >
> > I wanted to link certain static libraries and use them in squid source
> > code. I added the following lines in Makefile.am of the 'src' directory.
>
> Please be aware if you do that your new code and anything built from the
> Squid Makefile MUST be GPLv2 compliant.
>
>
> >
> > squid_LDFLAGS =
> >
> -L/media/NewVolume/yocto/build_t4240qds_release/tmp/work/ppce6500-fsl_networking-linux/usdpaa/git-r5/lib_powerpc/
> >
> > squid_LDLIBS = -lusdpaa_dma -lusdpaa_dpa_offload -lusdpaa_of
> -lusdpaa_ppac
> > -lusdpaa_qbman -lusdpaa_rmu -lusdpaa_srio -lusdpaa_dma_mem -lusdpaa_fman
> > -lusdpaa_pme \
> >                -lusdpaa_process -lusdpaa_rman -lusdpaa_sec
> -lusdpaa_syscfg
> >
> > squid_CPPFLAGS =
> >
> -I/media/NewVolume/yocto/build_t4240qds_release/tmp/work/ppce6500-fsl_networking-linux/usdpaa/git-r5/include/
> >
> > But I think this wrong as libraries aren't getting linked. I am getting
> > "undefined reference to" errors.
> > So what variables should I add/change.
>
> Those options are auto-generated by the autotools build chain.
>
> The -L flag should be passed by the ./configure LDFLAGS= parameter or
> coded into Makefile.am variable as a relative path. Its unlikely the
> exact absolute path will remain the same even within your build
> machines. I see you are using some path under ".../tmp" for example.
>
>
> Libraries are added to squid_LDADD variable. That takes the form:
>
>  squid_LDADD += -lusdpaa_dma
> or
>  squid_LDADD += -L$(top_srcdir)/../usdpaa/ -lusdpaa_dma
>
>
> which assumes the squid and usdpaa library code checkouts are sitting
> next to each other.
>
>
> Same deal for the -I value in the ./configure CXXFLAGS= parameter, or in
> the Makefile.am as a relative path:
>
>  AM_CPPFLAGS += -I$(top_srcdir)/../usdpaa/include/
>
>
> Amos
>
> _______________________________________________
> squid-users mailing list
> squid-users at lists.squid-cache.org
> http://lists.squid-cache.org/listinfo/squid-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squid-cache.org/pipermail/squid-users/attachments/20150313/340d7e08/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: log.do_configure.3013
Type: application/octet-stream
Size: 21494 bytes
Desc: not available
URL: <http://lists.squid-cache.org/pipermail/squid-users/attachments/20150313/340d7e08/attachment-0001.obj>


More information about the squid-users mailing list