diff options
author | Waldemar Brodkorb <wbx@openadk.org> | 2024-01-13 14:19:19 +0100 |
---|---|---|
committer | Waldemar Brodkorb <wbx@openadk.org> | 2024-01-18 06:17:13 +0100 |
commit | e69f684dedb4a693e38fc8b948cdff8c7601674c (patch) | |
tree | f65f0118178c9e288f945d4bc813ae8a49dbce0d /toolchain/uclibc-ng/Makefile | |
parent | 1e8ce0775190cbff163cf2d8e42bea16ba1669e7 (diff) |
support nommu with ELF binaries
Diffstat (limited to 'toolchain/uclibc-ng/Makefile')
-rw-r--r-- | toolchain/uclibc-ng/Makefile | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/toolchain/uclibc-ng/Makefile b/toolchain/uclibc-ng/Makefile index 5b0a6fdef..6b1fd31ce 100644 --- a/toolchain/uclibc-ng/Makefile +++ b/toolchain/uclibc-ng/Makefile @@ -50,8 +50,13 @@ UCLIBC_MAKEOPTS+= -j${ADK_MAKE_JOBS} endif $(WRKBUILD)/.configured: $(WRKBUILD)/.prepared +ifeq ($(ADK_TARGET_WITH_MMU),y) PATH='$(HOST_PATH)' sed -e 's^KERNEL_HEADERS.*$$KERNEL_HEADERS=\"${STAGING_TARGET_DIR}/usr/include\"' \ $(ADK_TOPDIR)/target/$(ADK_TARGET_ARCH)/uclibc-ng.config >${WRKBUILD}/.config +else + PATH='$(HOST_PATH)' sed -e 's^KERNEL_HEADERS.*$$KERNEL_HEADERS=\"${STAGING_TARGET_DIR}/usr/include\"' \ + $(ADK_TOPDIR)/target/$(ADK_TARGET_ARCH)/uclibc-ng-nommu.config >${WRKBUILD}/.config +endif $(SED) 's^.*\(CROSS_COMPILER_PREFIX\).*^\1=\"$(TARGET_CROSS)\"^' ${WRKBUILD}/.config ifeq ($(ADK_TARGET_ENDIAN),little) $(SED) 's/.*\(ARCH_LITTLE_ENDIAN\).*/\1=y/' ${WRKBUILD}/.config @@ -80,6 +85,13 @@ ifeq ($(ADK_TARGET_HARD_FLOAT_DP),y) $(SED) 's/.*\(UCLIBC_HAS_FPU\).*/\1=y/' ${WRKBUILD}/.config $(SED) 's/.*\(UCLIBC_HAS_SOFT_FLOAT\).*/# \1 is not set/' ${WRKBUILD}/.config endif +ifeq ($(ADK_TARGET_BINFMT_ELF),y) + $(SED) 's/.*\(UCLIBC_FORMAT_ELF\).*/\1=y/' ${WRKBUILD}/.config + $(SED) 's/.*\(UCLIBC_FORMAT_FDPIC_ELF\).*/# \1 is not set/' ${WRKBUILD}/.config + $(SED) 's/.*\(UCLIBC_FORMAT_FLAT\).*/# \1 is not set/' ${WRKBUILD}/.config + $(SED) 's/.*\(UCLIBC_FORMAT_FLAT_SEP_DATA\).*/# \1 is not set/' ${WRKBUILD}/.config + $(SED) 's/.*\(UCLIBC_FORMAT_SHARED_FLAT\).*/# \1 is not set/' ${WRKBUILD}/.config +endif ifeq ($(ADK_TARGET_BINFMT_FDPIC),y) $(SED) 's/.*\(UCLIBC_FORMAT_FDPIC_ELF\).*/\1=y/' ${WRKBUILD}/.config $(SED) 's/.*\(UCLIBC_FORMAT_ELF\).*/# \1 is not set/' ${WRKBUILD}/.config @@ -376,6 +388,8 @@ $(WRKBUILD)/.installed: $(WRKBUILD)/.compiled UCLIBC_EXTRA_LDFLAGS="$(TARGET_LDFLAGS)" \ VERBOSE=1 \ install_runtime install_dev + ln -f ${STAGING_TARGET_DIR}/usr/lib/crt1.o \ + ${STAGING_TARGET_DIR}/usr/lib/Scrt1.o ifeq ($(ADK_TARGET_LIBC_UTILS),y) PATH='$(HOST_PATH)' $(MAKE) -C $(WRKBUILD) \ ARCH="$(ADK_TARGET_ARCH)" \ |