bugGPSD - Bugs: bug #46876, gpsd 3.16: CPPFLAGS read with...

 
 

bug #46876: gpsd 3.16: CPPFLAGS read with quotation marks

Submitted by:  Jeff Bai <jeffbai>
Submitted on:  Mon 11 Jan 2016 06:21:02 PM UTC  
 
Category:  None Severity:  3 - Normal
Item Group:  None Status:  None
Privacy:  Public Assigned to:  None
Open/Closed:  Open

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Mon 11 Jan 2016 06:21:02 PM UTC, original submission:

When building gpsd 3.16 with CPPFLAGS declared as...

CPPFLAGS="-O2 -D_FORTIFY_SOURCE=2 "

By the build system, however it causes gpsd to fail to build with the output as provided below.

/usr/bin/gcc -o ais_json.os -c -pipe -Wno-error -fPIC -fstack-protector-strong --param=ssp-buffer-size=4 -fomit-frame-pointer -O2 -march=x86-64 -mtune=core2 -msse -msse2 -msse3 -fira-loop-pressure -fira-hoist-pressure -Wextra -Wall -Wno-uninitialized -Wno-missing-field-initializers -Wcast-align -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith -Wreturn-type -pthread -Wmissing-declarations -O2 -fPIC "-O2 -D_FORTIFY_SOURCE=2 " -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include ais_json.c
cc1: error: argument to '-O' should be a non-negative integer, 'g', 's' or 'fast'
scons: *** [ais_json.os] Error 1
scons: building terminated because of errors.

As you can see here, CPPFLAGS is been included as a string of parameter to the compiler, however **with** quotation marks, causing a failure.

However if I would merge CPPFLAGS as part of CFLAGS like so.

export CFLAGS="${CPPFLAGS} ${CFLAGS}"
unset CPPFLAGS

The build will proceed as normal.

Jeff Bai <jeffbai>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by jeffbai (Submitted the item)
  • -email is unavailable- added by jeffbai
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

     

     

    Follows 1 latest change.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-01-11 jeffbai Carbon-Copy- => Added -email is unavailable-

    Back to the top


    Powered by Savane 3.3