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: NoneSeverity: 3 - Normal
Item Group: NoneStatus: None
Privacy: PublicAssigned 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 File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

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

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

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follows 1 latest change.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon 11 Jan 2016 06:21:02 PM UTCjeffbaiCarbon-Copy-=>Added -unavailable-

    Back to the top


    Powered by Savane 3.1-cleanup1