public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
* Help with specs
@ 2004-08-17 11:30 DY, JERRY U (SBCSI)
  2004-08-23 13:40 ` Andrea Pretto
  0 siblings, 1 reply; 2+ messages in thread
From: DY, JERRY U (SBCSI) @ 2004-08-17 11:30 UTC (permalink / raw)
  To: gcc-help

Here's my config:

g++ -v
Reading specs from
/usr/local/appl/gcc-3.4.1/lib/gcc/hppa2.0w-hp-hpux11.11/3.4.1/specs
Configured with: ../gcc-3.4.1/configure --prefix=/usr/local/appl/gcc
--with-as=/usr/local/appl/binutils/bin/as --enable-threa
ds=posix
Thread model: posix
gcc version 3.4.1

I wanted to change the specs so that -D_INCLUDE__STDC_A1_SOURCE is
defined everytime the precompiler is invoked, so I modify the cpp entry
in the specs file as follows:

*cpp:
-D_INCLUDE__STDC_A1_SOURCE %{mt|pthread:-D_REENTRANT -D_THREAD_SAFE
-D_POSIX_C_SOURCE=199506L}

But it doesn't appear to be working. Is there something wrong with my
syntax or am I missing something? Thanks!

-Jerry

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Help with specs
  2004-08-17 11:30 Help with specs DY, JERRY U (SBCSI)
@ 2004-08-23 13:40 ` Andrea Pretto
  0 siblings, 0 replies; 2+ messages in thread
From: Andrea Pretto @ 2004-08-23 13:40 UTC (permalink / raw)
  To: DY, JERRY U (SBCSI); +Cc: gcc-help

In my spec , I have changed my cpp line in this way:
*cpp:
%{posix:-D_POSIX_SOURCE} %{pthread:-D_REENTRANT}
-D_INCLUDE__STDC_A1_SOURCE

That is, I have appended -D_INCLUDE__STDC_A1_SOURCE, and this code

#include <stdio.h>

int main ( void ){

#ifdef _INCLUDE__STDC_A1_SOURCE
  printf("Yes\n");
#else
  printf("No\n");
#endif
  return 0;
}

print "Yes" string.
It seem correct.
	
On Mon, 2004-08-16 at 21:24, DY, JERRY U (SBCSI) wrote:
> Here's my config:
> 
> g++ -v
> Reading specs from
> /usr/local/appl/gcc-3.4.1/lib/gcc/hppa2.0w-hp-hpux11.11/3.4.1/specs
> Configured with: ../gcc-3.4.1/configure --prefix=/usr/local/appl/gcc
> --with-as=/usr/local/appl/binutils/bin/as --enable-threa
> ds=posix
> Thread model: posix
> gcc version 3.4.1
> 
> I wanted to change the specs so that -D_INCLUDE__STDC_A1_SOURCE is
> defined everytime the precompiler is invoked, so I modify the cpp entry
> in the specs file as follows:
> 
> *cpp:
> -D_INCLUDE__STDC_A1_SOURCE %{mt|pthread:-D_REENTRANT -D_THREAD_SAFE
> -D_POSIX_C_SOURCE=199506L}
> 
> But it doesn't appear to be working. Is there something wrong with my
> syntax or am I missing something? Thanks!
> 
> -Jerry

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-08-23  9:44 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-08-17 11:30 Help with specs DY, JERRY U (SBCSI)
2004-08-23 13:40 ` Andrea Pretto

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).