3 # OS/390 hints by David J. Fiander <davidf@mks.com>
5 # OS/390 OpenEdition Release 3 Mon Sep 22 1997 thanks to:
7 # John Pfuntner <pfuntner@vnet.ibm.com>
8 # Len Johnson <lenjay@ibm.net>
9 # Bud Huff <BAHUFF@us.oracle.com>
10 # Peter Prymmer <pvhp@forte.com>
11 # Andy Dougherty <doughera@lafcol.lafayette.edu>
12 # Tim Bunce <Tim.Bunce@ig.co.uk>
14 # as well as the authors of the aix.sh file
17 # To get ANSI C, we need to use c89, and ld doesn't exist
18 # You can override this with Configure -Dcc=gcc -Dld=ld.
26 # -DMAXSIG=38 maximum signal number
27 # -DOEMVS is used in place of #ifdef __MVS__ in certain places.
28 # -D_OE_SOCKETS alters system headers.
29 # -D_XOPEN_SOURCE_EXTENDEDA alters system headers.
30 # c89 hides most of the useful header stuff, _ALL_SOURCE turns it on again.
31 # YYDYNAMIC ensures that the OS/390 yacc generated parser is reentrant.
32 # -DEBCDIC should come from Configure and need not be mentioned here.
33 # Prepend your favorites with Configure -Dccflags=your_favorites
35 '') ccflags='-DMAXSIG=38 -DOEMVS -D_OE_SOCKETS -D_XOPEN_SOURCE_EXTENDED -D_ALL_SOURCE -DYYDYNAMIC' ;;
36 *) ccflags="$ccflags -DMAXSIG=38 -DOEMVS -D_OE_SOCKETS -D_XOPEN_SOURCE_EXTENDED -D_ALL_SOURCE -DYYDYNAMIC" ;;
39 # Turning on optimization breaks perl.
40 # You can override this with Configure -Doptimize='-O' or somesuch.
42 '') optimize='none' ;;
45 # ccdlflags have yet to be determined.
47 #'') ccdlflags='-c' ;;
50 # To link via definition side decks we need the dll option
51 # You can override this with Configure -Ucccdlflags or somesuch.
53 '') cccdlflags='-W 0,dll,"langlvl(extended)"' ;;
56 # ldflags have yet to be determined.
61 # lddlflags have yet to be determined.
74 case "$usemymalloc" in
75 '') usemymalloc='n' ;;
78 # On OS/390, libc.a doesn't really hold anything at all,
79 # so running nm on it is pretty useless.
80 # You can override this with Configure -Dusenm.
85 # Dynamic loading doesn't work on OS/390 quite yet.
86 # You can override this with
87 # Configure -Dusedl -Ddlext=.so -Ddlsrc=dl_dllload.xs.
97 case "$ldlibpthname" in
98 '') ldlibpthname=LIBPATH ;;
101 # Header files to include.
102 # You can override these with Configure -Ui_time -Ui_systime.
104 '') i_time='define' ;;
107 '') i_systime='define' ;;
111 # uname -m output is too specific and not appropriate here
112 # osname should come from Configure
113 # You can override this with Configure -Darchname='s390' but please don't.
115 '') archname="$osname" ;;
118 # Architecture related object files.
119 # ebcdic.c contains special \cX mapping code for EBCDIC char sets.
120 # Prepend your preference with Configure -Darchobs=your_preference.o.
122 '') archobjs="ebcdic.o" ;;
123 *) archobjs="$archobjs ebcdic.o" ;;
126 # We have our own cppstdin script. This is not a variable since
127 # Configure sees the presence of the script file.
128 # We put system header -D definitions in so that Configure
129 # can find the shmat() prototype in <sys/shm.h> and various
130 # other things. Unfortunately, cppflags occurs too late to be of
131 # value external to the script. This may need to be revisited
132 # under a compiler other than c89.
133 echo 'cat >.$$.c; '"$cc"' -D_OE_SOCKETS -D_XOPEN_SOURCE_EXTENDED -D_ALL_SOURCE -E -Wc,NOLOC ${1+"$@"} .$$.c; rm .$$.c' > cppstdin
136 # Note that Makefile.SH employs a bare yacc command to generate
137 # perly.[hc] and a2p.[hc], hence you may wish to:
139 # alias yacc='myyacc'
141 # Then if you would like to use myyacc and skip past the
142 # following warnings try invoking Configure like so:
144 # sh Configure -Dbyacc=yacc
146 # This trick ought to work even if your yacc is byacc.
148 if test "X$byacc" = "Xbyacc" ; then
149 if test -e /etc/yyparse.c ; then
150 : we should be OK - perhaps do a test -r?
154 Warning. You do not have a copy of yyparse.c, the default
155 yacc parser template file, in place in /etc.
157 if test -e /samples/yyparse.c ; then
160 There does appear to be a template file in /samples though.
163 cp /samples/yyparse.c /etc
165 before attempting to Configure the build of $package.
171 There does not appear to be one in /samples either.
172 If you feel you can make use of an alternate yacc-like
173 parser generator then please read the comments in the
174 hints/os390.sh file carefully.