diff options
author | tnn <tnn@pkgsrc.org> | 2022-04-13 23:09:09 +0000 |
---|---|---|
committer | tnn <tnn@pkgsrc.org> | 2022-04-13 23:09:09 +0000 |
commit | 8ec174f95eda43b12d0bb7798ce05107e9e9ac51 (patch) | |
tree | 797281b9050b7a14b338a8bc4189580773c754e9 /cross | |
parent | f6355198165fecd843d9c861d1e952000af100f4 (diff) | |
download | pkgsrc-8ec174f95eda43b12d0bb7798ce05107e9e9ac51.tar.gz |
xtensa-esp32-elf-binutils: convert to Makefile.common
so we can target esp32s2 and esp32s3 in companion packages
Diffstat (limited to 'cross')
-rw-r--r-- | cross/xtensa-esp32-elf-binutils/Makefile | 41 | ||||
-rw-r--r-- | cross/xtensa-esp32-elf-binutils/Makefile.common | 48 |
2 files changed, 51 insertions, 38 deletions
diff --git a/cross/xtensa-esp32-elf-binutils/Makefile b/cross/xtensa-esp32-elf-binutils/Makefile index 6295f6b2c7a..cb07855ac7b 100644 --- a/cross/xtensa-esp32-elf-binutils/Makefile +++ b/cross/xtensa-esp32-elf-binutils/Makefile @@ -1,42 +1,7 @@ -# $NetBSD: Makefile,v 1.4 2022/04/13 21:02:33 tnn Exp $ +# $NetBSD: Makefile,v 1.5 2022/04/13 23:09:09 tnn Exp $ -DISTNAME= binutils-2.35.2 -PKGNAME= ${DISTNAME:C/.*binutils(-gdb)?/xtensa-esp32-elf-binutils/} -CATEGORIES= cross -MASTER_SITES= ${MASTER_SITE_GNU:=binutils/} -EXTRACT_SUFX= .tar.xz -# Espressif overlays -DISTFILES= ${DEFAULT_DISTFILES} -DISTFILES+= crosstool-NG-esp-2021r2-patch3.tar.gz -SITES.crosstool-NG-esp-2021r2-patch3.tar.gz= -https://github.com/espressif/crosstool-NG/releases/download/esp-2021r2-patch3/crosstool-NG-esp-2021r2-patch3.tar.gz +ESP32_TYPE= esp32 -MAINTAINER= pkgsrc-users@NetBSD.org -HOMEPAGE= https://github.com/espressif/binutils-gdb -COMMENT= Cross binutils for Espressif ESP32 bare metal environment -LICENSE= gnu-gpl-v2 AND gnu-gpl-v3 AND gnu-lgpl-v2 AND gnu-lgpl-v3 - -INFO_FILES= yes -GNU_CONFIGURE= yes -GNU_CONFIGURE_STRICT= no # several sub-configures know --enable-nls -USE_LIBTOOL= yes -USE_TOOLS+= gmake makeinfo - -OBJDIR= ../build -CONFIGURE_DIRS= ${OBJDIR} -CONFIGURE_SCRIPT= ${WRKSRC}/configure -GNU_CONFIGURE_PREFIX= ${PREFIX}/xtensa-esp32-elf - -CONFIGURE_ARGS+= --disable-werror -CONFIGURE_ARGS+= --target=xtensa-esp32-elf -CONFIGURE_ARGS+= --enable-multilib -CONFIGURE_ARGS+= --disable-nls -CONFIGURE_ARGS+= --disable-gdb - -post-extract: - ${CP} -r ${WRKDIR}/overlays/xtensa_esp32/binutils/. \ - ${WRKSRC}/. - -pre-configure: - ${RUN} cd ${WRKSRC} && ${MKDIR} ${OBJDIR} +.include "Makefile.common" .include "../../mk/bsd.pkg.mk" diff --git a/cross/xtensa-esp32-elf-binutils/Makefile.common b/cross/xtensa-esp32-elf-binutils/Makefile.common new file mode 100644 index 00000000000..10ee2b5cb95 --- /dev/null +++ b/cross/xtensa-esp32-elf-binutils/Makefile.common @@ -0,0 +1,48 @@ +# $NetBSD: Makefile.common,v 1.1 2022/04/13 23:09:09 tnn Exp $ + +# used by cross/xtensa-esp32-elf-binutils/Makefile +# used by cross/xtensa-esp32s2-elf-binutils/Makefile +# used by cross/xtensa-esp32s3-elf-binutils/Makefile + +DISTNAME= binutils-2.35.2 +PKGNAME= ${DISTNAME:C/.*binutils(-gdb)?/xtensa-${ESP32_TYPE}-elf-binutils/} +CATEGORIES= cross +MASTER_SITES= ${MASTER_SITE_GNU:=binutils/} +EXTRACT_SUFX= .tar.xz +# Espressif overlays +DISTFILES= ${DEFAULT_DISTFILES} +DISTFILES+= crosstool-NG-esp-2021r2-patch3.tar.gz +SITES.crosstool-NG-esp-2021r2-patch3.tar.gz= -https://github.com/espressif/crosstool-NG/releases/download/esp-2021r2-patch3/crosstool-NG-esp-2021r2-patch3.tar.gz + +MAINTAINER= pkgsrc-users@NetBSD.org +HOMEPAGE= https://github.com/espressif/binutils-gdb +COMMENT= Cross binutils for Espressif ${ESP32_TYPE:tu} bare metal environment +LICENSE= gnu-gpl-v2 AND gnu-gpl-v3 AND gnu-lgpl-v2 AND gnu-lgpl-v3 + +INFO_FILES= yes +GNU_CONFIGURE= yes +GNU_CONFIGURE_STRICT= no # several sub-configures know --enable-nls +USE_LIBTOOL= yes +USE_TOOLS+= gmake makeinfo + +#PATCHDIR= ${.CURDIR}/../../cross/xtensa-esp32-elf-binutils/patches +DISTINFO_FILE= ${.CURDIR}/../../cross/xtensa-esp32-elf-binutils/distinfo +DESCR_SRC= ${.CURDIR}/../../cross/xtensa-esp32-elf-binutils/DESCR + +OBJDIR= ../build +CONFIGURE_DIRS= ${OBJDIR} +CONFIGURE_SCRIPT= ${WRKSRC}/configure +GNU_CONFIGURE_PREFIX= ${PREFIX}/xtensa-${ESP32_TYPE}-elf + +CONFIGURE_ARGS+= --disable-werror +CONFIGURE_ARGS+= --target=xtensa-${ESP32_TYPE}-elf +CONFIGURE_ARGS+= --enable-multilib +CONFIGURE_ARGS+= --disable-nls +CONFIGURE_ARGS+= --disable-gdb + +post-extract: + ${CP} -r ${WRKDIR}/overlays/xtensa_${ESP32_TYPE}/binutils/. \ + ${WRKSRC}/. + +pre-configure: + ${RUN} cd ${WRKSRC} && ${MKDIR} ${OBJDIR} |