mirror of
https://github.com/opnsense/src.git
synced 2026-02-14 16:23:25 -05:00
This includes removing all vestiges of the old not-really supported ability to build cross tools targeting non-FreeBSD systems, such as m68k Lynx and NetBSD. Move as much duplicated code from platform Makefiles into the shared Makefiles. Add a simple mechanism for specifying ELF 'ldscripts'. Also share as many .h files as possible (now a single bfd.h vs. one per platform).
28 lines
1,004 B
Makefile
28 lines
1,004 B
Makefile
# $FreeBSD$
|
|
|
|
NATIVE_EMULATION= elf_x86_64_fbsd
|
|
|
|
SRCS+= e${NATIVE_EMULATION}.c
|
|
CLEANFILES+= e${NATIVE_EMULATION}.c
|
|
e${NATIVE_EMULATION}.c: emulparams/${NATIVE_EMULATION}.sh emultempl/elf32.em \
|
|
scripttempl/elf.sc genscripts.sh stringify.sed
|
|
sh ${.CURDIR}/genscripts.sh ${SRCDIR}/ld ${LIBSERACHPATH} \
|
|
${TOOLS_PREFIX}/usr \
|
|
${HOST} ${TARGET_TUPLE} ${TARGET_TUPLE} \
|
|
"${NATIVE_EMULATION}" "" no ${NATIVE_EMULATION} "${TARGET_TUPLE}"
|
|
|
|
X86_EMULATION= elf_i386_fbsd
|
|
_i386_path= \"${TOOLS_PREFIX}/usr/lib/i386\"
|
|
EMS+= ${X86_EMULATION}
|
|
.for ext in ${ELF_SCR_EXT}
|
|
LDSCRIPTS+= ${X86_EMULATION}.${ext}
|
|
.endfor
|
|
|
|
SRCS+= e${X86_EMULATION}.c
|
|
CLEANFILES+= e${X86_EMULATION}.c
|
|
e${X86_EMULATION}.c: emulparams/${X86_EMULATION}.sh emultempl/elf32.em \
|
|
scripttempl/elf.sc genscripts.sh stringify.sed
|
|
sh ${.CURDIR}/genscripts.sh ${SRCDIR}/ld ${_i386_path} \
|
|
${TOOLS_PREFIX}/usr \
|
|
${HOST} ${TARGET_TUPLE} ${TARGET_TUPLE} \
|
|
"${X86_EMULATION}" "" no ${X86_EMULATION} "${TARGET_TUPLE}"
|