I am missing something important while porting to AIX 3.1?

jsalter at ibmpa.awdpa.ibm.com jsalter at ibmpa.awdpa.ibm.com
Thu Feb 7 04:42:48 AEST 1991


In article <1991Feb6.050344.1516 at ux1.cso.uiuc.edu> andreess at mrlaxs.mrl.uiuc.edu (Marc Andreessen) writes:
>In article <1991Feb6.020623.26983 at lavaca.uh.edu> jet at karazm.math.uh.edu ("J. Eric Townsend") writes:
>>Several times I've tried to port relatively innocuous (good word, eh?)
>>code from the BSD/SunOS world to AIX 3.1 and have had a big AIX-shaped
>>boot stomped all over my head.

>>These are things that should be simple: patch, BSD tar, etc.

patch doesn't come with the system, but it ports relatively easily.
tar works just fine for me, and I transfer stuff all the time between 4.3's
and 6000's.

>>[...]  Maybe there's a magic
>>program, "bsdtoaix" that modifies generic BSD code so that cc/c89/xlc
>>doesn't barf so hard.

See the 'bsdcc' stanza in the BSD porting document /usr/lpp/bos/bsdport
that comes with your system.  It talks a LOT about this stuff.  And, while
you're at it, you might want to read the /usr/lpp/bos/README file which
is chock-full [:-)] of interesting information.

>Maybe this is self-evident, but you are compiling with -D_BSD and
>then linking everything to libbsd.a in the end, aren't you?

Don't forget that this has been upgraded in later releases from GOLD to
also use the _BSD_INCLUDE token (for stuff that was missed earlier.  They
will be grouped together in later releases.)

>I've compiled literally scores of more-or-less standard BSD programs
>this way (including patch, etc).  After _BSD is defined, quite often the
>only problems remaining are declarations of malloc(), sprintf(),
>and the like, which can be safely #ifndef _AIX'd out of the source code.

>Also, I avoid xlc and c89 like the Black Plague.  But that's another
>story.

Why?  I don't understand this comment at all.  xlc and c89 (as defined in
the file /etc/xlc.cfg) just define *strict* ANSI C conformance.  If your
code is strictly conforming (nothing outside of the ANSI C standard) then
it should compile just fine.  If you believe your code is ANSI C compliant
and it doesn't compile with xlc or c89, then you need to open an
APAR/problem-report with IBM, or at least give us a chance to see the code.

I'm sorry, but I'm tired of seeing global accusations like this without proof.

>Marc Andreessen___________University of Illinois Materials Research Laboratory
>Internet: andreessen at uimrl7.mrl.uiuc.edu____________Bitnet: andreessen at uiucmrl

jim/jsalter  IBM PSLOB, Palo Alto  T465/(415)855-4427  VNET: JSALTER at AUSVMQ
Internet: jsalter at slo.awdpa.ibm.com         UUCP: ..!uunet!ibmsupt!jsalter 
  PS/2 it, or DIE!  :-)  The ramblings above have nothing to do with Big Blue.



More information about the Comp.unix.aix mailing list