| @@ -1,61 +1,31 @@ | | | @@ -1,61 +1,31 @@ |
1 | # $NetBSD: Makefile.inc,v 1.34 2023/06/02 14:32:04 lukem Exp $ | | 1 | # $NetBSD: Makefile.inc,v 1.35 2023/06/02 20:49:07 lukem Exp $ |
2 | # | | 2 | # |
3 | # etc.sparc64/Makefile.inc -- sparc64-specific etc Makefile targets | | 3 | # etc.sparc64/Makefile.inc -- sparc64-specific etc Makefile targets |
4 | # | | 4 | # |
5 | # Specify whether or not to build 32-bit libs. | | | |
6 | MK32BITLIBS?=no | | | |
7 | | | 5 | |
8 | # If you change the list of distributed kernels, don't forget | | 6 | # If you change the list of distributed kernels, don't forget |
9 | # to update the release documentation in distrib/notes/common/contents | | 7 | # to update the release documentation in distrib/notes/common/contents |
10 | | | 8 | |
11 | KERNEL_SETS= GENERIC GENERIC.UP | | 9 | KERNEL_SETS= GENERIC GENERIC.UP |
12 | | | 10 | |
13 | BUILD_KERNELS+= INSTALL | | 11 | BUILD_KERNELS+= INSTALL |
14 | | | 12 | |
15 | MD_INSTALLATION_DIRS= installation/miniroot \ | | 13 | MD_INSTALLATION_DIRS= installation/miniroot \ |
16 | installation/netboot \ | | 14 | installation/netboot \ |
17 | installation/misc | | 15 | installation/misc |
18 | INSTALLATION_DIRS+= ${MD_INSTALLATION_DIRS} | | 16 | INSTALLATION_DIRS+= ${MD_INSTALLATION_DIRS} |
19 | | | 17 | |
20 | # Used by 32 bit lib/csu, lib, gnu/lib & libexec/ld.elf_so | | | |
21 | LIBDIR=/usr/lib/32 | | | |
22 | BINDIR=/usr/libexec/32 | | | |
23 | SPARC32_ENV=MACHINE=sparc MACHINE_ARCH=sparc | | | |
24 | SPARC32=COPTS=-m32 LD="ld -m elf32_sparc" AS="as -32" \ | | | |
25 | LIBDIR=${LIBDIR} BINDIR=${BINDIR} \ | | | |
26 | SHLIB_LDSTARTFILE=${DESTDIR}${LIBDIR}/crtbeginS.o \ | | | |
27 | SHLIB_LDENDFILE=${DESTDIR}${LIBDIR}/crtendS.o | | | |
28 | | | | |
29 | | | | |
30 | snap_md_post: | | 18 | snap_md_post: |
31 | | | | |
32 | .if ${MACHINE_ARCH} == "sparc64" && ${MK32BITLIBS} != "no" | | | |
33 | | | | |
34 | # build 32 bit programs | | | |
35 | .for _s64dir in lib/csu lib gnu/lib libexec/ld_elf.so | | | |
36 | .if ${MKOBJDIRS} != "no" | | | |
37 | (cd ${NETBSDSRCDIR}/${_s64dir} && \ | | | |
38 | ${SPARC32_ENV} ${MAKE} ${SPARC32} ${_M} obj) | | | |
39 | .endif | | | |
40 | .if ${MKUPDATE} == "no" | | | |
41 | (cd ${NETBSDSRCDIR}/${_s64dir} && ${MAKE} cleandir) | | | |
42 | .endif | | | |
43 | (cd ${NETBSDSRCDIR}/${_s64dir} && \ | | | |
44 | ${SPARC32_ENV} ${MAKE} ${SPARC32} ${_M} ${_J} MKSHARE=no dependall \ | | | |
45 | && ${SPARC32_ENV} ${MAKE} ${SPARC32} ${_M} MKSHARE=no install) | | | |
46 | .endfor | | | |
47 | .endif # MACHINE_ARCH==sparc64 && MACHINE==sparc && MK32BITLIBS!=no | | | |
48 | | | | |
49 | # Install miniroot images and auxiliary scripts to the release tree | | 19 | # Install miniroot images and auxiliary scripts to the release tree |
50 | .if exists($(XSRCDIR)/xc/Imakefile) | | 20 | .if exists($(XSRCDIR)/xc/Imakefile) |
51 | # build X11 | | 21 | # build X11 |
52 | .ifndef XSRC_DONE | | 22 | .ifndef XSRC_DONE |
53 | (cd $(XSRCDIR); $(MAKE) release) | | 23 | (cd $(XSRCDIR); $(MAKE) release) |
54 | .endif | | 24 | .endif |
55 | .endif | | 25 | .endif |
56 | | | 26 | |
57 | # install boot image and installation scripts in netboot directory | | 27 | # install boot image and installation scripts in netboot directory |
58 | .for file in ofwboot.net | | 28 | .for file in ofwboot.net |
59 | ${HOST_INSTALL_FILE} -m ${NONBINMODE} ${DESTDIR}/usr/mdec/${file} \ | | 29 | ${HOST_INSTALL_FILE} -m ${NONBINMODE} ${DESTDIR}/usr/mdec/${file} \ |
60 | ${RELEASEDIR}/${RELEASEMACHINEDIR}/installation/netboot | | 30 | ${RELEASEDIR}/${RELEASEMACHINEDIR}/installation/netboot |
61 | .endfor | | 31 | .endfor |