autoconf
[Top][All Lists]
Advanced

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

Re: autoconf not passing all the flags needed to g++


From: Gavin Smith
Subject: Re: autoconf not passing all the flags needed to g++
Date: Wed, 24 Jun 2015 19:12:22 +0100

On 24 June 2015 at 17:48, Robert Stolarz <address@hidden> wrote:
> I'm trying to adapt the library soil2 to work with autoconf.
> http://pastebin.ca/raw/3035774 is what I have so far. My g++ invocation
> reads `g++ -I/usr/include/libdrm  -Wall -v -g -O2 -lGLEW -lGLU -lGL -lglfw
>  -lm  -o giants src/main.o` and `pkg-config --libs soil2` yields
> "-L/usr/lib/linux -lsoil2". Why aren't the soil2 flags showing up in my g++
> invocation?

You do

AM_CXXFLAGS = @gllibs_CFLAGS@ -Wall -v
AM_LDFLAGS = @gllibs_LIBS@ -lm

and

PKG_CHECK_MODULES([gllibs], [gl glew glfw3 >= 3.0])
PKG_CHECK_MODULES([soil2], [soil2])

i.e. you use the result of the gllibs check but not the result of the
soil2 check. It should rather be

AM_CXXFLAGS = @gllibs_CFLAGS@ @soil2_CFLAGS@ -Wall -v
AM_LDFLAGS = @gllibs_LIBS@ @soil2_CFLAGS@ -lm



reply via email to

[Prev in Thread] Current Thread [Next in Thread]