473,386 Members | 1,602 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

C_INCLUDE_PATH and gcc -I option

Hi,

I would like to know the difference between using the
C_INCLUDE_PATH and using the -I option with compilers. How are they
different?

The problem which I am facing is that I am having a
source base which uses python. I am currently enabling compile time
option _POSIX_C_SOURCE in my Makefile. The compilaiton fails if i
include -I option to /usr/include/python2.4

/usr/include/python2.4/pyconfig-32.h:838:1: error: "_POSIX_C_SOURCE"
redefined

but if i do

export C_INCLUDE_PATH=/usr/include/python2.4

I do not face any compilation issues.

I would like to know if there is anything i am missing on this.
Regards,
Madhur
Jun 27 '08 #1
3 10622
On 9 Jun 2008 at 13:46, Madhur wrote:
The problem which I am facing is that I am having a
source base which uses python. I am currently enabling compile time
option _POSIX_C_SOURCE in my Makefile. The compilaiton fails if i
include -I option to /usr/include/python2.4

/usr/include/python2.4/pyconfig-32.h:838:1: error: "_POSIX_C_SOURCE"
redefined

but if i do

export C_INCLUDE_PATH=/usr/include/python2.4

I do not face any compilation issues.
[guess]
Does your build procedure include running some python script that reads
the C_INCLUDE_PATH envrionment variable, but doesn't see -I... in
CFLAGS?
[/guess]

Jun 27 '08 #2
There aren't any python scripts which reads C_INCLUDE_PATH.

On Jun 9, 7:04 am, Antoninus Twink <nos...@nospam.invalidwrote:
On 9 Jun 2008 at 13:46, Madhur wrote:
The problem which I am facing is that I am having a
source base which uses python. I am currently enabling compile time
option _POSIX_C_SOURCE in my Makefile. The compilaiton fails if i
include -I option to /usr/include/python2.4
/usr/include/python2.4/pyconfig-32.h:838:1: error: "_POSIX_C_SOURCE"
redefined
but if i do
export C_INCLUDE_PATH=/usr/include/python2.4
I do not face any compilation issues.

[guess]
Does your build procedure include running some python script that reads
the C_INCLUDE_PATH envrionment variable, but doesn't see -I... in
CFLAGS?
[/guess]
Jun 27 '08 #3
Madhur <ma********@gmail.comwrites:
I would like to know the difference between using the
C_INCLUDE_PATH and using the -I option with compilers. How are they
different?
Best not to ask this sort of question. It asks for an essay on the
differences when there may be only one detail that matters.
The problem which I am facing is that I am having a
source base which uses python. I am currently enabling compile time
option _POSIX_C_SOURCE in my Makefile. The compilaiton fails if i
include -I option to /usr/include/python2.4

/usr/include/python2.4/pyconfig-32.h:838:1: error: "_POSIX_C_SOURCE"
redefined

but if i do

export C_INCLUDE_PATH=/usr/include/python2.4

I do not face any compilation issues.
That is clear enough but it is better asked in gnu.gcc.help. I have
sent this there and set followups-to.

You can make it non-python specific if you like. I have just got the
same behaviour from:

--- m.c ---
#define MACRO 0
#include <x.h>

MACRO
-----------
--- x.h ---
#define MACRO 1
-----------

$ gcc -E -I. m.c

gives the expected error, but setting C_INCLUDE_PATH=. makes the error
vanish (even if the -I. parameter is kept).

--
Ben.
Jun 27 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Targa | last post by:
I have a select box with about 5 options. I need to have one of the options, when selected, display a second select box. The second select box is populated by a database and needs to be preloaded...
3
by: gekoblu | last post by:
Hi!, I want to fix via javascript the combo width to a fix value. I'd like to implement a kind of ALT / TITLE function to show the entire option when the text is longer than the combo width......
3
by: Rithish Saralaya | last post by:
Is there a way to scroll a selected OPTION into view? I have a combination of text box and SELECT list. A user can key in text in the text box, and depending on the entry made, the respective...
3
by: Iain Hallam | last post by:
Hi. I've been using display:none on the style property of some <option> elements in my forms, which works fine with Mozilla - as expected it removes the option from my dropdown (although it...
3
by: Stewart | last post by:
Dear comp.lang.javascript, I have more than once wanted to manipulate the contents of select boxes dynamically, whilst the boxes contain <optgroup> tags. Manipulation of a select box containing...
8
by: McKirahan | last post by:
Firefox does not reflect selected option via innerHTML How do I get Firefox to reflect selected option values? <html> <head> <title>FFinner.htm</title> <script type="text/javascript">...
2
by: rpeterson84 | last post by:
Hi, Thanks in advance to for the help!!!!! When the page loads, "Application Inventory" is selected by default --- I want to use a mouse.click to select "Systems Compliance", BUT HOW? I'm...
1
by: Madhur | last post by:
I would like to know the difference between using the C_INCLUDE_PATH and using the -I option with compilers. How are they different? The problem which I am facing is that I am having a source...
3
by: Venturini | last post by:
I am trying to put together a web page where the customer makes choices of products and is then given a total. I am extremely new to Javascript and have managed to get as far as I have from web...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.