# Note that the macros are not used for the install target any more with the
# change to the install(1) program.  Edit the install commands.

FILES = mach-o/ldsyms.h mach-o/reloc.h mach-o/rld.h
LOCFILES = mach-o/rld_state.h mach-o/sarld.h mach-o/i860/reloc.h \
	   mach-o/m88k/reloc.h mach-o/m98k/reloc.h mach-o/hppa/reloc.h \
	   mach-o/sparc/reloc.h
COMPAT = 2.0Compat
COMPATFILES = ldsyms.h reloc.h rld.h

# Note that OTHER_SRCS do NOT get installed
OTHER_SRCS = notes gnu/a.out.h gnu/symseg.h gnu/exec.h \
	     stuff/allocate.h stuff/arch.h stuff/errors.h stuff/execute.h \
	     stuff/bool.h stuff/bytesex.h stuff/round.h stuff/ofile.h \
	     stuff/hash_string.h stuff/breakout.h stuff/best_arch.h \
	     stuff/hppa.h stuff/reloc.h stuff/vm_flush_cache.h

# Note that MISSING_SRCS are those may not be on all build machines
MISSING_SRCS = mach/i860/thread_status.h mach/machine.h \
	       architecture/i386/fpu.h architecture/i386/frame.h \
	       mach/m98k/thread_status.h \
	       architecture/nrw/reg_help.h \
	       architecture/nrw/macro_help.h \
	       architecture/m98k/reg_help.h \
	       architecture/m98k/basic_regs.h \
	       architecture/m98k/m98601_regs.h \
	       architecture/m98k/fp_regs.h \
	       mach/m88k/thread_status.h \
	       architecture/m88k/fp_regs.h \
	       architecture/m88k/reg_help.h \
	       standalone/libsa.h \
	       mach-o/loader.h \
	       mach-o/nlist.h \
	       mach/hppa/thread_status.h

INCDIR = /NextDeveloper/Headers
LOCINCDIR = /LocalDeveloper/Headers
COMPATDIR = /NextDeveloper/2.0CompatibleHeaders

SRC_FILES = Makefile $(FILES) $(LOCFILES) $(COMPAT) $(OTHER_SRCS) $(MISSING_SRCS)

installsrc installGNUsrc:
	mkdirs $(SRCROOT)
	chmod 755 $(SRCROOT)
	tar cf - $(SRC_FILES) | (cd $(SRCROOT); tar xf -)

install: dirs
	cd mach-o; \
	    install -m 444 ${IFLAGS} ldsyms.h reloc.h rld.h \
	    ${DSTROOT}${INCDIR}/mach-o
	cd mach-o; \
	    install -m 444 ${IFLAGS} rld_state.h \
	    ${DSTROOT}${LOCINCDIR}/mach-o
	cd mach-o; \
	    install -m 444 ${IFLAGS} sarld.h \
	    ${DSTROOT}${LOCINCDIR}/mach-o
	cd mach-o/i860; \
	    install -m 444 ${IFLAGS} reloc.h \
	    ${DSTROOT}${LOCINCDIR}/mach-o/i860
	cd mach-o/m88k; \
	    install -m 444 ${IFLAGS} reloc.h \
	    ${DSTROOT}${LOCINCDIR}/mach-o/m88k
	cd mach-o/m98k; \
	    install -m 444 ${IFLAGS} reloc.h \
	    ${DSTROOT}${LOCINCDIR}/mach-o/m98k
	cd mach-o/hppa; \
	    install -m 444 ${IFLAGS} reloc.h \
	    ${DSTROOT}${LOCINCDIR}/mach-o/hppa
	cd mach-o/sparc; \
	    install -m 444 ${IFLAGS} reloc.h \
	    ${DSTROOT}${LOCINCDIR}/mach-o/sparc
	cd $(COMPAT); \
	    install -m 444 ${IFLAGS} ${COMPATFILES} ${DSTROOT}${COMPATDIR}

dirs:
	mkdirs ${DSTROOT}${INCDIR}/mach-o
	mkdirs ${DSTROOT}${LOCINCDIR}/mach-o
	mkdirs ${DSTROOT}${LOCINCDIR}/mach-o/i860
	mkdirs ${DSTROOT}${LOCINCDIR}/mach-o/m88k
	mkdirs ${DSTROOT}${LOCINCDIR}/mach-o/m98k
	mkdirs ${DSTROOT}${LOCINCDIR}/mach-o/hppa
	mkdirs ${DSTROOT}${LOCINCDIR}/mach-o/sparc
	mkdirs ${DSTROOT}${COMPATDIR}

depend:

clean:

all:
