Tweaks for OpenBSD:
authorniklas <niklas@openbsd.org>
Mon, 8 Jan 1996 15:54:12 +0000 (15:54 +0000)
committerniklas <niklas@openbsd.org>
Mon, 8 Jan 1996 15:54:12 +0000 (15:54 +0000)
1) recognize OpenBSD at various places
2) m68k-cbm-* is *NOT* ELF always
3) clean-info must be called before distclean in the GAS
realclean target
4) don't install unformatted ma-pages
5) add a Makefile.bsd-wrapper
6) just build gas through Makefile.bsd-wrapper yet
There are still other things to do...

gnu/usr.bin/binutils/Makefile.bsd-wrapper [new file with mode: 0644]
gnu/usr.bin/binutils/Makefile.in
gnu/usr.bin/binutils/bfd/config.bfd
gnu/usr.bin/binutils/config.guess
gnu/usr.bin/binutils/config.sub
gnu/usr.bin/binutils/configure.in
gnu/usr.bin/binutils/gas/Makefile.in

diff --git a/gnu/usr.bin/binutils/Makefile.bsd-wrapper b/gnu/usr.bin/binutils/Makefile.bsd-wrapper
new file mode 100644 (file)
index 0000000..fa8e1ea
--- /dev/null
@@ -0,0 +1,38 @@
+#      $Id: Makefile.bsd-wrapper,v 1.1 1996/01/08 15:54:12 niklas Exp $
+
+MAN=   binutils/ar.1 binutils/nlmconv.1 binutils/nm.1 binutils/objcopy.1 \
+       binutils/objdump.1 binutils/ranlib.1 binutils/size.1 \
+       binutils/strings.1 binutils/strip.1 gas/doc/as.1 ld/ld.1 \
+       gprof/gprof.1
+
+# So far only gas is useful for us.  This will change, be sure.
+all:   config.status
+       ${MAKE} LDFLAGS=${LDSTATIC} all-gas
+
+.FORCE:        .IGNORE
+
+config: .FORCE
+       sh ${.CURDIR}/configure --prefix=/usr
+
+config.status:
+       sh ${.CURDIR}/configure --prefix=/usr
+
+install: maninstall
+       ${MAKE} prefix=${DESTDIR}/usr infodir=${DESTDIR}/usr/share/info \
+               bindir=${DESTDIR}/usr/bin INSTALL_MAN= install-gas install-ld
+
+clean cleandir:
+       -@if [ -e Makefile ]; then ${MAKE} realclean; fi
+
+depend:
+       # Nothing here so far...
+
+lint:
+       # Nothing here so far...
+
+tags:
+       # Nothing here so far...
+
+.include <bsd.obj.mk>
+.include <bsd.subdir.mk>
+.include <bsd.man.mk>
index b803620..139fa47 100644 (file)
@@ -112,7 +112,6 @@ RUNTEST = `if [ -f $${srcroot}/dejagnu/runtest ] ; \
        then echo $${srcroot}/dejagnu/runtest ; \
        else echo runtest ; fi`
 
-
 # compilers to use to create programs which must be run in the build
 # environment.
 CC_FOR_BUILD = $(CC)
@@ -279,6 +278,7 @@ BASE_FLAGS_TO_PASS = \
        "RUNTEST=$(RUNTEST)" \
        "RUNTESTFLAGS=$(RUNTESTFLAGS)" \
        "YACC=$(BISON)" \
+       "INSTALL_MAN=$(INSTALL_MAN)" \
        "exec_prefix=$(exec_prefix)" \
        "prefix=$(prefix)" \
        "tooldir=$(tooldir)" 
index 2b385d1..a03f978 100644 (file)
@@ -231,7 +231,7 @@ case "${targ}" in
     targ_selvecs=cisco_core_vec
     targ_underscore=yes
     ;;
-  m68*-*-elf* | m68*-*-sysv4* | m68*-cbm-*)
+  m68*-*-elf* | m68*-*-sysv4*)
     targ_defvec=bfd_elf32_m68k_vec
     targ_selvecs=m68kcoff_vec
     ;;
index 2ff0eba..08c151a 100644 (file)
@@ -65,6 +65,9 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
     amiga:NetBSD:*:*)
       echo m68k-cbm-netbsd${UNAME_RELEASE}
       exit 0 ;;
+    amiga:OpenBSD:*:*)
+      echo m68k-cbm-openbsd${UNAME_RELEASE}
+      exit 0 ;;
     arm:RISC*:1.[012]*:*|arm:riscix:1.[012]*:*)
        echo arm-acorn-riscix${UNAME_RELEASE}
        exit 0;;
@@ -102,12 +105,21 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
     atari*:NetBSD:*:*)
        echo m68k-atari-netbsd${UNAME_RELEASE}
        exit 0 ;;
+    atari*:OpenBSD:*:*)
+       echo m68k-atari-openbsd${UNAME_RELEASE}
+       exit 0 ;;
     sun3*:NetBSD:*:*)
        echo m68k-sun-netbsd${UNAME_RELEASE}
        exit 0 ;;
+    sun3*:OpenBSD:*:*)
+       echo m68k-sun-openbsd${UNAME_RELEASE}
+       exit 0 ;;
     mac68k:NetBSD:*:*)
        echo m68k-apple-netbsd${UNAME_RELEASE}
        exit 0 ;;
+    mac68k:OpenBSD:*:*)
+       echo m68k-apple-openbsd${UNAME_RELEASE}
+       exit 0 ;;
     RISC*:ULTRIX:*:*)
        echo mips-dec-ultrix${UNAME_RELEASE}
        exit 0 ;;
@@ -303,6 +315,9 @@ EOF
     hp3[0-9][05]:NetBSD:*:*)
        echo m68k-hp-netbsd${UNAME_RELEASE}
        exit 0 ;;
+    hp3[0-9][05]:OpenBSD:*:*)
+       echo m68k-hp-openbsd${UNAME_RELEASE}
+       exit 0 ;;
     i[34]86:BSD/386:*:* | *:BSD/OS:*:*)
        echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
        exit 0 ;;
@@ -312,6 +327,9 @@ EOF
     *:NetBSD:*:*)
        echo ${UNAME_MACHINE}-unknown-netbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
        exit 0 ;;
+    *:OpenBSD:*:*)
+       echo ${UNAME_MACHINE}-unknown-openbsd`echo ${UNAME_RELEASE}|sed -e 's/[-_].*/\./'`
+       exit 0 ;;
     *:GNU:*:*)
        echo `echo ${UNAME_MACHINE}|sed -e 's,/.*$,,'`-unknown-gnu`echo ${UNAME_RELEASE}|sed -e 's,/.*$,,'`
        exit 0 ;;
index cdad52c..ce3dd49 100644 (file)
@@ -809,7 +809,8 @@ case $os in
              | -amigados* | -msdos* | -moss* | -newsos* | -unicos* | -aos* \
              | -nindy* | -vxworks* | -ebmon* | -hms* | -mvs* | -clix* \
              | -riscos* | -linux* | -uniplus* | -iris* | -rtu* | -xenix* \
-             | -hiux* | -386bsd* | -netbsd* | -freebsd* | -riscix*  | -lites* \
+             | -hiux* | -386bsd* | -netbsd* | -freebsd* | -openbsd* \
+             | -riscix*  | -lites* \
              | -lynxos* | -bosx* | -nextstep* | -cxux* | -aout* | -elf* \
              | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta | -udi | -eabi*)
                ;;
index 567a5a1..e1d191d 100644 (file)
@@ -444,6 +444,9 @@ case "${target}" in
   m68k-*-netbsd*)
     noconfigdirs="$noconfigdirs gdb"
     ;;
+  m68k-*-openbsd*)
+    noconfigdirs="$noconfigdirs gdb"
+    ;;
   m68k-apollo-*)
     noconfigdirs="$noconfigdirs ld binutils gprof"
     ;;
index 805d5cc..c5bf38c 100644 (file)
@@ -206,6 +206,10 @@ GASPOBJS = \
        sb.o \
        hash.o
 
+# Target to use for installing unformatted man-pages.  Some systems may not
+# want them installed.
+INSTALL_MAN = install-man
+
 all: .gdbinit as.new gasp.new
        @srcroot=`cd $(srcroot); pwd`; export srcroot; \
        (cd doc ; $(MAKE) $(FLAGS_TO_PASS) all)
@@ -426,7 +430,7 @@ distclean: clean-here
                targ-cpu.c obj-format.h obj-format.c atof-targ.c TAGS \
                config-stamp config.h conf config.log config.cache .gdbinit \
                testsuite/Makefile testsuite/config.status
-maintainer-clean realclean: clean distclean clean-info
+maintainer-clean realclean: clean clean-info distclean
        @echo "This command is intended for maintainers to use;"
        @echo "it deletes files that may require special tools to rebuild."
        -rm -rf $(DISTSTUFF)
@@ -434,10 +438,9 @@ maintainer-clean realclean: clean distclean clean-info
 # Entry points `install', `includes' and `uninstall'.
 
 # Copy the files into directories where they will be run.
-install:
+install: $(INSTALL_MAN)
        srcroot=`cd $(srcroot); pwd`; export srcroot; \
        $(INSTALL_XFORM) as.new $(bindir)/as; \
-       $(INSTALL_XFORM1) $(srcdir)/doc/as.1 $(man1dir)/as.1; \
        n=`echo as | sed '$(program_transform_name)'`; \
        if [ -d $(tooldir) ]; then \
          if [ -d $(tooldir)/bin ] ; then true ; else mkdir $(tooldir)/bin ; fi; \
@@ -456,6 +459,10 @@ uninstall:
        -n=`t='$(program_transform_name)'; echo gasp | sed $$t`; \
        rm -f $(bindir)/$$n; \
 
+install-man:
+       srcroot=`cd $(srcroot); pwd`; export srcroot; \
+       $(INSTALL_XFORM1) $(srcdir)/doc/as.1 $(man1dir)/as.1
+
 # These exist for maintenance purposes.
 
 tags TAGS: force