Annotation of embedaddon/readline/support/shobj-conf, revision 1.1.1.1.2.1

1.1       misho       1: #! /bin/sh
                      2: #
                      3: # shobj-conf -- output a series of variable assignments to be substituted
                      4: #              into a Makefile by configure which specify system-dependent
                      5: #              information for creating shared objects that may be loaded
                      6: #              into bash with `enable -f'
                      7: #
                      8: # usage: shobj-conf [-C compiler] -c host_cpu -o host_os -v host_vendor
                      9: #
                     10: # Chet Ramey
                     11: # chet@po.cwru.edu
                     12: 
                     13: #   Copyright (C) 1996-2014 Free Software Foundation, Inc.
                     14: #
                     15: #   This file is part of GNU Bash, the Bourne Again SHell.
                     16: #
                     17: #   This program is free software: you can redistribute it and/or modify
                     18: #   it under the terms of the GNU General Public License as published by
                     19: #   the Free Software Foundation, either version 3 of the License, or
                     20: #   (at your option) any later version.
                     21: #
                     22: #   This program is distributed in the hope that it will be useful,
                     23: #   but WITHOUT ANY WARRANTY; without even the implied warranty of
                     24: #   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
                     25: #   GNU General Public License for more details.
                     26: #
                     27: #   You should have received a copy of the GNU General Public License
                     28: #   along with this program.  If not, see <http://www.gnu.org/licenses/>.
                     29: #
                     30: 
                     31: #
                     32: # defaults
                     33: #
                     34: SHOBJ_STATUS=supported
                     35: SHLIB_STATUS=supported
                     36: 
                     37: SHOBJ_CC=cc
                     38: SHOBJ_CFLAGS=
                     39: SHOBJ_LD=
                     40: SHOBJ_LDFLAGS=
                     41: SHOBJ_XLDFLAGS=
                     42: SHOBJ_LIBS=
                     43: 
                     44: SHLIB_XLDFLAGS=
                     45: SHLIB_LIBS=
                     46: 
                     47: SHLIB_DOT='.'
                     48: SHLIB_LIBPREF='lib'
                     49: SHLIB_LIBSUFF='so'
                     50: 
                     51: SHLIB_LIBVERSION='$(SHLIB_LIBSUFF)'
                     52: SHLIB_DLLVERSION='$(SHLIB_MAJOR)'
                     53: 
                     54: PROGNAME=`basename $0`
                     55: USAGE="$PROGNAME [-C compiler] -c host_cpu -o host_os -v host_vendor"
                     56: 
                     57: while [ $# -gt 0 ]; do
                     58:        case "$1" in
                     59:        -C)     shift; SHOBJ_CC="$1"; shift ;;
                     60:        -c)     shift; host_cpu="$1"; shift ;;
                     61:        -o)     shift; host_os="$1"; shift ;;
                     62:        -v)     shift; host_vendor="$1"; shift ;;
                     63:        *)      echo "$USAGE" >&2 ; exit 2;;
                     64:        esac
                     65: done
                     66: 
                     67: case "${host_os}-${SHOBJ_CC}-${host_vendor}" in
                     68: nsk-cc-tandem)
                     69:        SHOBJ_CFLAGS=-Wglobalized
                     70:        case `uname -m` in
                     71:        NSR*)
                     72:                SHOBJ_CFLAGS="${SHOBJ_CFLAGS} -Wcall_shared" # default on TNS/E, needed on TNS/R
                     73:                SHOBJ_LD=/usr/bin/ld # for TNS/R
                     74:                ;;
                     75:        NSE*|NEO*)
                     76:                SHOBJ_LD=/usr/bin/eld
                     77:                ;;
                     78:        esac
                     79:        SHOBJ_LDFLAGS='-shared -bglobalized -unres_symbols ignore'
                     80:        ;;
                     81: 
                     82: sunos4*-*gcc*)
                     83:        SHOBJ_CFLAGS=-fpic
                     84:        SHOBJ_LD=/usr/bin/ld
                     85:        SHOBJ_LDFLAGS='-assert pure-text'
                     86: 
                     87:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)$(SHLIB_MINOR)'
                     88:        ;;
                     89: 
                     90: sunos4*)
                     91:        SHOBJ_CFLAGS=-pic
                     92:        SHOBJ_LD=/usr/bin/ld
                     93:        SHOBJ_LDFLAGS='-assert pure-text'
                     94: 
                     95:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)$(SHLIB_MINOR)'
                     96:        ;;
                     97: 
                     98: sunos5*-*gcc*|solaris2*-*gcc*)
                     99:        SHOBJ_LD='${CC}'
                    100:        ld_used=`gcc -print-prog-name=ld`
                    101:        if ${ld_used} -V 2>&1 | grep GNU >/dev/null 2>&1; then
                    102:                # This line works for the GNU ld
                    103:                SHOBJ_LDFLAGS='-shared -Wl,-h,$@'
                    104:                # http://sourceware.org/ml/binutils/2001-08/msg00361.html
                    105:                SHOBJ_CFLAGS=-fPIC
                    106:        else
                    107:                # This line works for the Solaris linker in /usr/ccs/bin/ld
                    108:                SHOBJ_LDFLAGS='-shared -Wl,-i -Wl,-h,$@'
                    109:                SHOBJ_CFLAGS=-fpic
                    110:        fi
                    111: 
                    112: #      SHLIB_XLDFLAGS='-R $(libdir)'
                    113:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    114:        ;;
                    115: 
                    116: sunos5*|solaris2*)
                    117:        SHOBJ_CFLAGS='-K pic'
                    118:        SHOBJ_LD=/usr/ccs/bin/ld
                    119:        SHOBJ_LDFLAGS='-G -dy -z text -i -h $@'
                    120: 
                    121: #      SHLIB_XLDFLAGS='-R $(libdir)'
                    122:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    123:        ;;
                    124: 
                    125: # All versions of Linux (including Gentoo/FreeBSD) or the semi-mythical GNU Hurd.
                    126: linux*-*|gnu*-*|k*bsd*-gnu-*|freebsd*-gentoo)
                    127:        SHOBJ_CFLAGS=-fPIC
                    128:        SHOBJ_LD='${CC}'
                    129:        SHOBJ_LDFLAGS='-shared -Wl,-soname,$@'
                    130: 
                    131:        SHLIB_XLDFLAGS='-Wl,-rpath,$(libdir) -Wl,-soname,`basename $@ $(SHLIB_MINOR)`'
                    132:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)$(SHLIB_MINOR)'
                    133:        ;;
                    134: 
1.1.1.1.2.1! misho     135: freebsd2.*)
1.1       misho     136:        SHOBJ_CFLAGS=-fpic
                    137:        SHOBJ_LD=ld
                    138:        SHOBJ_LDFLAGS='-x -Bshareable'
                    139: 
                    140:        SHLIB_XLDFLAGS='-R$(libdir)'
                    141:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)$(SHLIB_MINOR)'
                    142:        ;;
                    143: 
                    144: # FreeBSD-3.x ELF
1.1.1.1.2.1! misho     145: freebsd3.*|freebsdaout*)
1.1       misho     146:        SHOBJ_CFLAGS=-fPIC
                    147:        SHOBJ_LD='${CC}'
                    148: 
                    149:                SHOBJ_LDFLAGS='-shared -Wl,-soname,$@'
                    150: 
                    151:                SHLIB_XLDFLAGS='-Wl,-rpath,$(libdir)'
                    152:                SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    153:        ;;
                    154: 
                    155: # FreeBSD-4.x and later have only ELF
                    156: freebsd[4-9]*|freebsd1[0-9]*|freebsdelf*|dragonfly*)
                    157:        SHOBJ_CFLAGS=-fPIC
                    158:        SHOBJ_LD='${CC}'
                    159: 
                    160:        SHOBJ_LDFLAGS='-shared -Wl,-soname,$@'
                    161:        SHLIB_XLDFLAGS='-Wl,-rpath,$(libdir)'
                    162: 
                    163:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    164:        ;;
                    165: 
                    166: # Darwin/MacOS X
                    167: darwin*)
                    168:        # Common definitions for all darwin/mac os x versions
                    169:        SHOBJ_CFLAGS='-fno-common'
                    170: 
                    171:        SHOBJ_LD='${CC}'
                    172: 
                    173:        SHLIB_LIBVERSION='$(SHLIB_MAJOR)$(SHLIB_MINOR).$(SHLIB_LIBSUFF)'
                    174:        SHLIB_LIBSUFF='dylib'
                    175: 
                    176:        # unused at this time
                    177:        SHLIB_SONAME='$(libdir)/`echo $@ | sed "s:\\..*::"`.$(SHLIB_MAJOR).$(SHLIB_LIBSUFF)'
                    178: 
                    179:        case "${host_os}" in
                    180:        # Darwin versions 1, 5, 6, 7 correspond to Mac OS X 10.0, 10.1, 10.2,
                    181:        # and 10.3, respectively.
                    182:        darwin[1-7].*)
                    183:                SHOBJ_STATUS=unsupported
                    184:                SHOBJ_LDFLAGS='-dynamic'
                    185:                SHLIB_XLDFLAGS='-arch_only `/usr/bin/arch` -install_name $(libdir)/`echo $@ | sed "s:\\..*::"`.$(SHLIB_MAJOR).$(SHLIB_LIBSUFF) -current_version $(SHLIB_MAJOR)$(SHLIB_MINOR) -compatibility_version $(SHLIB_MAJOR) -v'
                    186:                ;;
                    187:        # Darwin 8 == Mac OS X 10.4; Mac OS X 10.N == Darwin N+4
                    188:        *)
                    189:                case "${host_os}" in
                    190:                darwin[89]*|darwin1[012]*)
                    191:                        SHOBJ_ARCHFLAGS='-arch_only `/usr/bin/arch`'
                    192:                        ;;
                    193:                 *)     # Mac OS X 10.9 (Mavericks) and later
                    194:                        SHOBJ_ARCHFLAGS=
                    195:                        # for 32 and 64bit universal library
                    196:                        #SHOBJ_ARCHFLAGS='-arch i386 -arch x86_64'
                    197:                        #SHOBJ_CFLAGS=${SHOBJ_CFLAGS}' -arch i386 -arch x86_64'
                    198:                        ;;
                    199:                 esac
                    200:                 SHOBJ_LDFLAGS="-dynamiclib -dynamic -undefined dynamic_lookup ${SHOBJ_ARCHFLAGS}"
                    201:                 SHLIB_XLDFLAGS="-dynamiclib ${SHOBJ_ARCHFLAGS}"' -install_name $(libdir)/`echo $@ | sed "s:\\..*::"`.$(SHLIB_MAJOR).$(SHLIB_LIBSUFF) -current_version $(SHLIB_MAJOR)$(SHLIB_MINOR) -compatibility_version $(SHLIB_MAJOR) -v'
                    202:                ;;
                    203:        esac
                    204: 
                    205:        SHLIB_LIBS='-lncurses'  # see if -lcurses works on MacOS X 10.1 
                    206:        ;;
                    207: 
                    208: openbsd*|netbsd*|mirbsd*)
                    209:        SHOBJ_CFLAGS=-fPIC
                    210:        SHOBJ_LD='${CC}'
                    211:        SHOBJ_LDFLAGS='-shared'
                    212: 
                    213:        SHLIB_XLDFLAGS='-R$(libdir)'
                    214:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)$(SHLIB_MINOR)'
                    215:        ;;
                    216: 
                    217: bsdi2*)
                    218:        SHOBJ_CC=shlicc2
                    219:        SHOBJ_CFLAGS=
                    220:        SHOBJ_LD=ld
                    221:        SHOBJ_LDFLAGS=-r
                    222:        SHOBJ_LIBS=-lc_s.2.1.0
                    223: 
                    224:        # BSD/OS 2.x and 3.x `shared libraries' are too much of a pain in
                    225:        # the ass -- they require changing {/usr/lib,etc}/shlib.map on
                    226:        # each system, and the library creation process is byzantine
                    227:        SHLIB_STATUS=unsupported
                    228:        ;;
                    229: 
                    230: bsdi3*)
                    231:        SHOBJ_CC=shlicc2
                    232:        SHOBJ_CFLAGS=
                    233:        SHOBJ_LD=ld
                    234:        SHOBJ_LDFLAGS=-r
                    235:        SHOBJ_LIBS=-lc_s.3.0.0
                    236: 
                    237:        # BSD/OS 2.x and 3.x `shared libraries' are too much of a pain in
                    238:        # the ass -- they require changing {/usr/lib,etc}/shlib.map on
                    239:        # each system, and the library creation process is byzantine
                    240:        SHLIB_STATUS=unsupported
                    241:        ;;
                    242: 
                    243: bsdi4*)
                    244:        # BSD/OS 4.x now supports ELF and SunOS-style dynamically-linked
                    245:        # shared libraries.  gcc 2.x is the standard compiler, and the
                    246:        # `normal' gcc options should work as they do in Linux.
                    247: 
                    248:        SHOBJ_CFLAGS=-fPIC
                    249:        SHOBJ_LD='${CC}'
                    250:        SHOBJ_LDFLAGS='-shared -Wl,-soname,$@'
                    251: 
                    252:        SHLIB_XLDFLAGS='-Wl,-soname,`basename $@ $(SHLIB_MINOR)`'
                    253:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)$(SHLIB_MINOR)'
                    254:        ;;
                    255: 
                    256: osf*-*gcc*)
                    257:        # Fix to use gcc linker driver from bfischer@TechFak.Uni-Bielefeld.DE
                    258:        SHOBJ_LD='${CC}'
                    259:        SHOBJ_LDFLAGS='-shared -Wl,-soname,$@'
                    260: 
                    261:        SHLIB_XLDFLAGS='-rpath $(libdir)'
                    262:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    263:        ;;
                    264: 
                    265: osf*)
                    266:        SHOBJ_LD=ld
                    267:        SHOBJ_LDFLAGS='-shared -soname $@ -expect_unresolved "*"'
                    268: 
                    269:        SHLIB_XLDFLAGS='-rpath $(libdir)'
                    270:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    271:        ;;
                    272: 
                    273: aix4.[2-9]*-*gcc*|aix[5-9].*-*gcc*)            # lightly tested by jik@cisco.com
                    274:        SHOBJ_CFLAGS=-fpic
                    275:        SHOBJ_LD='ld'
                    276:        SHOBJ_LDFLAGS='-bdynamic -bnoentry -bexpall'
                    277:        SHOBJ_XLDFLAGS='-G'
                    278: 
                    279:        SHLIB_XLDFLAGS='-bM:SRE'
                    280:        SHLIB_LIBS='-lcurses -lc'
                    281:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    282:        ;;
                    283: 
                    284: aix4.[2-9]*|aix[5-9].*)
                    285:        SHOBJ_CFLAGS=-K
                    286:        SHOBJ_LD='ld'
                    287:        SHOBJ_LDFLAGS='-bdynamic -bnoentry -bexpall'
                    288:        SHOBJ_XLDFLAGS='-G'
                    289: 
                    290:        SHLIB_XLDFLAGS='-bM:SRE'
                    291:        SHLIB_LIBS='-lcurses -lc'
                    292:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    293:        ;;
                    294: 
                    295: #
                    296: # THE FOLLOWING ARE UNTESTED -- and some may not support the dlopen interface
                    297: #
                    298: irix[56]*-*gcc*)
                    299:        SHOBJ_CFLAGS='-fpic'
                    300:        SHOBJ_LD='${CC}'
                    301:        SHOBJ_LDFLAGS='-shared -Wl,-soname,$@'
                    302: 
                    303:        SHLIB_XLDFLAGS='-Wl,-rpath,$(libdir)'
                    304:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    305:        ;;
                    306: 
                    307: irix[56]*)
                    308:        SHOBJ_CFLAGS='-K PIC'
                    309:        SHOBJ_LD=ld
                    310: #      SHOBJ_LDFLAGS='-call_shared -hidden_symbol -no_unresolved -soname $@'
                    311: #      Change from David Kaelbling <drk@sgi.com>.  If you have problems,
                    312: #      remove the `-no_unresolved'
                    313:        SHOBJ_LDFLAGS='-shared -no_unresolved -soname $@'
                    314: 
                    315:        SHLIB_XLDFLAGS='-rpath $(libdir)'
                    316:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    317:        ;;
                    318: 
                    319: hpux9*-*gcc*)
                    320:        # must use gcc; the bundled cc cannot compile PIC code
                    321:        SHOBJ_CFLAGS='-fpic'
                    322:        SHOBJ_LD='${CC}'
                    323:        SHOBJ_LDFLAGS='-shared -Wl,-b -Wl,+s'
                    324: 
                    325:        SHLIB_XLDFLAGS='-Wl,+b,$(libdir)'
                    326:        SHLIB_LIBSUFF='sl'
                    327:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    328:        ;;
                    329: 
                    330: hpux9*)
                    331:        SHOBJ_STATUS=unsupported
                    332:        SHLIB_STATUS=unsupported
                    333: 
                    334:        # If you are using the HP ANSI C compiler, you can uncomment and use
                    335:        # this code (I have not tested it)
                    336: #      SHOBJ_STATUS=supported
                    337: #      SHLIB_STATUS=supported
                    338: #
                    339: #      SHOBJ_CFLAGS='+z'
                    340: #      SHOBJ_LD='ld'
                    341: #      SHOBJ_LDFLAGS='-b +s'
                    342: #
                    343: #      SHLIB_XLDFLAGS='+b $(libdir)'
                    344: #      SHLIB_LIBSUFF='sl'
                    345: #      SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'      
                    346: 
                    347:        ;;
                    348: 
                    349: hpux10*-*gcc*)
                    350:        # must use gcc; the bundled cc cannot compile PIC code
                    351:        SHOBJ_CFLAGS='-fpic'
                    352:        SHOBJ_LD='${CC}'
                    353:        # if you have problems linking here, moving the `-Wl,+h,$@' from
                    354:        # SHLIB_XLDFLAGS to SHOBJ_LDFLAGS has been reported to work
                    355:        SHOBJ_LDFLAGS='-shared -fpic -Wl,-b -Wl,+s'
                    356: 
                    357:        SHLIB_XLDFLAGS='-Wl,+h,$@ -Wl,+b,$(libdir)'
                    358:        SHLIB_LIBSUFF='sl'
                    359:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    360:        ;;
                    361: 
                    362: hpux10*)
                    363:        SHOBJ_STATUS=unsupported
                    364:        SHLIB_STATUS=unsupported
                    365: 
                    366:        # If you are using the HP ANSI C compiler, you can uncomment and use
                    367:        # this code (I have not tested it)
                    368: #      SHOBJ_STATUS=supported
                    369: #      SHLIB_STATUS=supported
                    370: #
                    371: #      SHOBJ_CFLAGS='+z'
                    372: #      SHOBJ_LD='ld'
                    373: #      SHOBJ_LDFLAGS='-b +s +h $@'
                    374: #
                    375: #      SHLIB_XLDFLAGS='+b $(libdir)'
                    376: #      SHLIB_LIBSUFF='sl'
                    377: #      SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'      
                    378: 
                    379:        ;;
                    380: 
                    381: hpux11*-*gcc*)
                    382:        # must use gcc; the bundled cc cannot compile PIC code
                    383:        SHOBJ_CFLAGS='-fpic'
                    384:        SHOBJ_LD='${CC}'
                    385: #      SHOBJ_LDFLAGS='-shared -Wl,-b -Wl,-B,symbolic -Wl,+s -Wl,+std -Wl,+h,$@'
                    386:        SHOBJ_LDFLAGS='-shared -fpic -Wl,-b -Wl,+s -Wl,+h,$@'
                    387: 
                    388:        SHLIB_XLDFLAGS='-Wl,+b,$(libdir)'
                    389:        SHLIB_LIBSUFF='sl'
                    390:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    391:        ;;
                    392: 
                    393: hpux11*)
                    394:        SHOBJ_STATUS=unsupported
                    395:        SHLIB_STATUS=unsupported
                    396: 
                    397:        # If you are using the HP ANSI C compiler, you can uncomment and use
                    398:        # this code (I have not tested it)
                    399: #      SHOBJ_STATUS=supported
                    400: #      SHLIB_STATUS=supported
                    401: #
                    402: #      SHOBJ_CFLAGS='+z'
                    403: #      SHOBJ_LD='ld'
                    404: #      SHOBJ_LDFLAGS='-b +s +h $@'
                    405: #
                    406: #      SHLIB_XLDFLAGS='+b $(libdir)'
                    407: #      SHLIB_LIBSUFF='sl'
                    408: #      SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'      
                    409: 
                    410:        ;;
                    411: 
                    412: sysv4*-*gcc*)
                    413:        SHOBJ_CFLAGS=-shared
                    414:        SHOBJ_LDFLAGS='-shared -h $@'
                    415:        SHOBJ_LD='${CC}'
                    416: 
                    417:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    418:        ;;
                    419: 
                    420: sysv4*)
                    421:        SHOBJ_CFLAGS='-K PIC'
                    422:        SHOBJ_LD=ld
                    423:        SHOBJ_LDFLAGS='-dy -z text -G -h $@'
                    424: 
                    425:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    426:        ;;
                    427: 
                    428: sco3.2v5*-*gcc*)
                    429:        SHOBJ_CFLAGS='-fpic'            # DEFAULTS TO ELF
                    430:        SHOBJ_LD='${CC}'
                    431:        SHOBJ_LDFLAGS='-shared'
                    432: 
                    433:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    434:        ;;
                    435: 
                    436: sco3.2v5*)
                    437:        SHOBJ_CFLAGS='-K pic -b elf'
                    438:        SHOBJ_LD=ld
                    439:        SHOBJ_LDFLAGS='-G -b elf -dy -z text -h $@'
                    440: 
                    441:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    442:        ;;
                    443: 
                    444: sysv5uw7*-*gcc*)
                    445:        SHOBJ_CFLAGS='-fpic'
                    446:        SHOBJ_LD='${CC}'
                    447:        SHOBJ_LDFLAGS='-shared'
                    448: 
                    449:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    450:        ;;
                    451: 
                    452: sysv5uw7*)
                    453:        SHOBJ_CFLAGS='-K PIC'
                    454:        SHOBJ_LD=ld
                    455:        SHOBJ_LDFLAGS='-G -dy -z text -h $@'
                    456: 
                    457:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    458:        ;;
                    459: 
                    460: sysv5UnixWare*-*gcc*)
                    461:        SHOBJ_CFLAGS=-fpic
                    462:        SHOBJ_LD='${CC}'
                    463:        SHOBJ_LDFLAGS='-shared'
                    464: 
                    465:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    466:        ;;
                    467: 
                    468: sysv5UnixWare*)
                    469:        SHOBJ_CFLAGS='-K PIC'
                    470:        SHOBJ_LD=ld
                    471:        SHOBJ_LDFLAGS='-G -dy -z text -h $@'
                    472: 
                    473:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    474:        ;;
                    475: 
                    476: sysv5OpenUNIX*-*gcc*)
                    477:        SHOBJ_CFLAGS=-fpic
                    478:        SHOBJ_LD='${CC}'
                    479:        SHOBJ_LDFLAGS='-shared'
                    480: 
                    481:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    482:        ;;
                    483: 
                    484: sysv5OpenUNIX*)
                    485:        SHOBJ_CFLAGS='-K PIC'
                    486:        SHOBJ_LD=ld
                    487:        SHOBJ_LDFLAGS='-G -dy -z text -h $@'
                    488: 
                    489:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    490:        ;;
                    491: 
                    492: dgux*-*gcc*)
                    493:        SHOBJ_CFLAGS=-fpic
                    494:        SHOBJ_LD='${CC}'
                    495:        SHOBJ_LDFLAGS='-shared'
                    496: 
                    497:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    498:        ;;
                    499: 
                    500: dgux*)
                    501:        SHOBJ_CFLAGS='-K pic'
                    502:        SHOBJ_LD=ld
                    503:        SHOBJ_LDFLAGS='-G -dy -h $@'
                    504: 
                    505:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    506:        ;;
                    507: 
                    508: msdos*)
                    509:        SHOBJ_STATUS=unsupported
                    510:        SHLIB_STATUS=unsupported
                    511:        ;;
                    512: 
                    513: cygwin*)
                    514:        SHOBJ_LD='$(CC)'
                    515:        SHOBJ_LDFLAGS='-shared -Wl,--enable-auto-import -Wl,--enable-auto-image-base -Wl,--export-all -Wl,--out-implib=$(@).a'
                    516:        SHLIB_LIBPREF='cyg'
                    517:        SHLIB_LIBSUFF='dll'
                    518:        SHLIB_LIBVERSION='$(SHLIB_DLLVERSION).$(SHLIB_LIBSUFF)'
                    519:        SHLIB_LIBS='$(TERMCAP_LIB)'
                    520: 
                    521:        SHLIB_DOT=
                    522:        # For official cygwin releases, DLLVERSION will be defined in the
                    523:        # environment of configure, and will be incremented any time the API
                    524:        # changes in a non-backwards compatible manner.  Otherwise, it is just
                    525:        # SHLIB_MAJOR.
                    526:        if [ -n "$DLLVERSION" ] ; then
                    527:                SHLIB_DLLVERSION="$DLLVERSION"
                    528:        fi
                    529:        ;;
                    530: 
                    531: mingw*)
                    532:        SHOBJ_LD='$(CC)'
                    533:        SHOBJ_LDFLAGS='-shared -Wl,--enable-auto-import -Wl,--enable-auto-image-base -Wl,--export-all -Wl,--out-implib=$(@).a'
                    534:        SHLIB_LIBSUFF='dll'
                    535:        SHLIB_LIBVERSION='$(SHLIB_DLLVERSION).$(SHLIB_LIBSUFF)'
                    536:        SHLIB_LIBS='$(TERMCAP_LIB)'
                    537: 
                    538:        SHLIB_DOT=
                    539:        # For official cygwin releases, DLLVERSION will be defined in the
                    540:        # environment of configure, and will be incremented any time the API
                    541:        # changes in a non-backwards compatible manner.  Otherwise, it is just
                    542:        # SHLIB_MAJOR.
                    543:        if [ -n "$DLLVERSION" ] ; then
                    544:                SHLIB_DLLVERSION="$DLLVERSION"
                    545:        fi
                    546:        ;;
                    547: 
                    548: #
                    549: # Rely on correct gcc configuration for everything else
                    550: #
                    551: *-*gcc*)
                    552:        SHOBJ_CFLAGS=-fpic
                    553:        SHOBJ_LD='${CC}'
                    554:        SHOBJ_LDFLAGS='-shared'
                    555: 
                    556:        SHLIB_LIBVERSION='$(SHLIB_LIBSUFF).$(SHLIB_MAJOR)'
                    557:        ;;
                    558: 
                    559: *)
                    560:        SHOBJ_STATUS=unsupported
                    561:        SHLIB_STATUS=unsupported
                    562:        ;;
                    563: 
                    564: esac
                    565: 
                    566: echo SHOBJ_CC=\'"$SHOBJ_CC"\'
                    567: echo SHOBJ_CFLAGS=\'"$SHOBJ_CFLAGS"\'
                    568: echo SHOBJ_LD=\'"$SHOBJ_LD"\'
                    569: echo SHOBJ_LDFLAGS=\'"$SHOBJ_LDFLAGS"\'
                    570: echo SHOBJ_XLDFLAGS=\'"$SHOBJ_XLDFLAGS"\'
                    571: echo SHOBJ_LIBS=\'"$SHOBJ_LIBS"\'
                    572: 
                    573: echo SHLIB_XLDFLAGS=\'"$SHLIB_XLDFLAGS"\'
                    574: echo SHLIB_LIBS=\'"$SHLIB_LIBS"\'
                    575: 
                    576: echo SHLIB_DOT=\'"$SHLIB_DOT"\'
                    577: 
                    578: echo SHLIB_LIBPREF=\'"$SHLIB_LIBPREF"\'
                    579: echo SHLIB_LIBSUFF=\'"$SHLIB_LIBSUFF"\'
                    580: 
                    581: echo SHLIB_LIBVERSION=\'"$SHLIB_LIBVERSION"\'
                    582: echo SHLIB_DLLVERSION=\'"$SHLIB_DLLVERSION"\'
                    583: 
                    584: echo SHOBJ_STATUS=\'"$SHOBJ_STATUS"\'
                    585: echo SHLIB_STATUS=\'"$SHLIB_STATUS"\'
                    586: 
                    587: exit 0

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>