dotgnu-general
[Top][All Lists]
Advanced

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

[DotGNU] hpux issues


From: James Mc Parlane
Subject: [DotGNU] hpux issues
Date: Mon, 27 May 2002 13:56:21 +1000

I spent a good portion of the weekend learning automake and autoconf. I did
this for two reasons. 1) I wanted a nice configure script for my own
project, and 2) I'm trying to /*breath_in_here/* build pnet under hpux using
the hpux C compiler so I can debug it using wdb (I have to use hpux's wdb
because gdb does not work under hpux and gcc does not instrument using
anything that wdb will take notice of) so I can track down a crash and get a
backtrace.

For my own project I have decided to maintain my own Makefile.in and use
autoconf, because it seems that the latest versions of these tools will not
play together well. autoconf will complain when it sees macros for automake,
and automake looks in configure.ac for its macros and screams when it sees
some of the autoconf macros.  

On top of all this, automake seems to generate a gcc specific Makefile.in.

<DrMiaow> even if its not using gcc, automake generates a gcc specific
Makefile.in
<DrMiaow> %.o: %.c
<DrMiaow>         @echo '$(COMPILE) -c $<'; \
<DrMiaow>         $(COMPILE) -Wp,-MD,.deps/$(*F).pp -c $<
<DrMiaow>         @-cp .deps/$(*F).pp .deps/$(*F).P; \
<DrMiaow>         tr ' ' '\012' < .deps/$(*F).pp \
<DrMiaow>           | sed -e 's/^\\$$//' -e '/^$$/ d' -e '/:$$/ d' -e 's/$$/
:/' \
<DrMiaow>             >> .deps/$(*F).P; \
<DrMiaow>         rm .deps/$(*F).pp
<DrMiaow> the correct rule for hpux should be
<DrMiaow> %.o: %.c
<DrMiaow>         @echo '$(COMPILE) -c $<'; \
<DrMiaow>         $(COMPILE) +Md -c $<
<DrMiaow>         mv $(*F).d .deps/$(*F).pp
<DrMiaow>         @-cp .deps/$(*F).pp .deps/$(*F).P; \
<DrMiaow>         tr ' ' '\012' < .deps/$(*F).pp \
<DrMiaow>           | sed -e 's/^\\$$//' -e '/^$$/ d' -e '/:$$/ d' -e 's/$$/
:/' \
<DrMiaow>             >> .deps/$(*F).P; \
<DrMiaow>         rm .deps/$(*F).pp

In short, automake appears to me the "Work Of The Devil"TM

I have managed to get past this. This code looks like it is only used to
generate dynamic dependencies, so even though the make process squeals like
a pig,I managed to get treecc to compile only by modifying
treecc/configure.in so that instead of

AC_PROG_CC
AC_PROG_CXX

it reads

AC_PROG_CC(aCC gcc cc)
AC_PROG_CXX(aCC gcc cc)

Happy with this I moved onto building pnet, made the same change started
making and came a cropper with /pnet/support/gen_errno.sh 

When compiling with gcc I get the following line in the Makefile

/bin/sh gen_errno.sh ../include/il_errno.h gcc -DHAVE_CONFIG_H -I. -I.
-I../include    -I../libgc/include -g -O2 -Wall > errno_map.c

which works..

When compiling with aCC I get the following line in the Makefile

/bin/sh gen_errno.sh ../include/il_errno.h aCC -Ae -DHAVE_CONFIG_H -I. -I.
-I../include    -I../libgc/include -g >errno_map.c
aCC: warning 901: unknown option: `-': use +help for online documentation. 

Which does not. At this point I went to bed.

So I'm just wondering. Is the pnet build going to be limited just to gcc?

Does anyone know what I need to do in gen_errno.sh to 'fix' it...?

l8r!








reply via email to

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