Date: Wed, 2 Jan 2019 08:10:08 +0000 (UTC) From: Jan Beich <jbeich@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r489061 - in head/multimedia/libvpx: . files Message-ID: <201901020810.x028A8SV021242@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jbeich Date: Wed Jan 2 08:10:07 2019 New Revision: 489061 URL: https://svnweb.freebsd.org/changeset/ports/489061 Log: multimedia/libvpx: restore NEON on armv6 after r466922 - Only armv6 needs -meabi=5 - Build NEON files on armv6 - Respect CPUTYPE on armv7 and aarch64 Modified: head/multimedia/libvpx/Makefile (contents, props changed) head/multimedia/libvpx/files/patch-build_make_Makefile (contents, props changed) head/multimedia/libvpx/files/patch-build_make_configure.sh (contents, props changed) Modified: head/multimedia/libvpx/Makefile ============================================================================== --- head/multimedia/libvpx/Makefile Wed Jan 2 08:01:27 2019 (r489060) +++ head/multimedia/libvpx/Makefile Wed Jan 2 08:10:07 2019 (r489061) @@ -4,7 +4,7 @@ PORTNAME= libvpx DISTVERSIONPREFIX= v DISTVERSION= 1.7.0 -PORTREVISION= 3 +PORTREVISION= 4 CATEGORIES= multimedia MAINTAINER= jbeich@FreeBSD.org @@ -24,7 +24,6 @@ HAS_CONFIGURE= yes USE_PERL5= build USE_LDCONFIG= yes SHEBANG_FILES= build/make/ads2gas.pl -CONFIGURE_ENV= ASFLAGS="${ASFLAGS}" CONFIGURE_ARGS= --prefix=${PREFIX} \ --disable-install-docs \ --disable-install-srcs \ @@ -32,8 +31,6 @@ CONFIGURE_ARGS= --prefix=${PREFIX} \ --enable-vp8 \ --enable-vp9 MAKE_ARGS+= verbose=yes -ASFLAGS+= ${ASFLAGS_${MACHINE}} -ASFLAGS_arm= -meabi=5 ALL_TARGET= # empty OPTIONS_DEFINE= DEBUG MULTIRES POSTPROC RTCPU SHARED SIZE_LIMIT TEST THREADS Modified: head/multimedia/libvpx/files/patch-build_make_Makefile ============================================================================== --- head/multimedia/libvpx/files/patch-build_make_Makefile Wed Jan 2 08:01:27 2019 (r489060) +++ head/multimedia/libvpx/files/patch-build_make_Makefile Wed Jan 2 08:10:07 2019 (r489061) @@ -1,5 +1,36 @@ +- Make sure NEON is available when building with intrinsics + --- build/make/Makefile.orig +++ build/make/Makefile +@@ -142,6 +142,28 @@ $(BUILD_PFX)%_avx2.c.o: CFLAGS += -mavx2 + $(BUILD_PFX)%_avx512.c.d: CFLAGS += -mavx512f -mavx512cd -mavx512bw -mavx512dq -mavx512vl + $(BUILD_PFX)%_avx512.c.o: CFLAGS += -mavx512f -mavx512cd -mavx512bw -mavx512dq -mavx512vl + ++# ARM ++ifeq ($(TGT_ISA),armv6) ++ifeq (,$(filter -march=%,$(CFLAGS))) ++$(BUILD_PFX)%_neon.c.d: CFLAGS += -march=armv7-a ++$(BUILD_PFX)%_neon.c.o: CFLAGS += -march=armv7-a ++$(BUILD_PFX)%_neon.asm.S.d: ASFLAGS += -march=armv7-a ++$(BUILD_PFX)%_neon.asm.S.o: ASFLAGS += -march=armv7-a ++$(BUILD_PFX)%_neon_asm.asm.S.d: ASFLAGS += -march=armv7-a ++$(BUILD_PFX)%_neon_asm.asm.S.o: ASFLAGS += -march=armv7-a ++endif ++$(BUILD_PFX)%_neon.asm.S.d: ASFLAGS += -meabi=5 ++$(BUILD_PFX)%_neon.asm.S.o: ASFLAGS += -meabi=5 ++$(BUILD_PFX)%_neon_asm.asm.S.d: ASFLAGS += -meabi=5 ++$(BUILD_PFX)%_neon_asm.asm.S.o: ASFLAGS += -meabi=5 ++endif ++ifneq (,$(filter arm%,$(TGT_ISA))) ++$(BUILD_PFX)%_neon.asm.S.d: ASFLAGS += -mfpu=neon ++$(BUILD_PFX)%_neon.asm.S.o: ASFLAGS += -mfpu=neon ++$(BUILD_PFX)%_neon_asm.asm.S.d: ASFLAGS += -mfpu=neon ++$(BUILD_PFX)%_neon_asm.asm.S.o: ASFLAGS += -mfpu=neon ++endif ++ + # POWER + $(BUILD_PFX)%_vsx.c.d: CFLAGS += -maltivec -mvsx + $(BUILD_PFX)%_vsx.c.o: CFLAGS += -maltivec -mvsx @@ -230,8 +230,8 @@ define install_map_template $(DIST_DIR)/$(1): $(2) Modified: head/multimedia/libvpx/files/patch-build_make_configure.sh ============================================================================== --- head/multimedia/libvpx/files/patch-build_make_configure.sh Wed Jan 2 08:01:27 2019 (r489060) +++ head/multimedia/libvpx/files/patch-build_make_configure.sh Wed Jan 2 08:10:07 2019 (r489061) @@ -1,5 +1,6 @@ -- Add armv6 targets where NEON depends on CFLAGS +- Add armv6 targets and try NEON there - Recognize DragonFly as x86_64-linux-gcc target by default +- Don't override -march= on armv6, armv7 and aarch64 --- build/make/configure.sh.orig 2018-01-24 22:25:44 UTC +++ build/make/configure.sh @@ -27,3 +28,42 @@ tgt_os=linux ;; *solaris2.10) +@@ -914,7 +922,7 @@ process_common_toolchain() { + arm64|armv8) + soft_enable neon + ;; +- armv7|armv7s) ++ armv6|armv7|armv7s) + soft_enable neon + # Only enable neon_asm when neon is also enabled. + enabled neon && soft_enable neon_asm +@@ -935,29 +943,6 @@ + arch_int=${arch_int%%te} + check_add_asflags --defsym ARCHITECTURE=${arch_int} + tune_cflags="-mtune=" +- if [ ${tgt_isa} = "armv7" ] || [ ${tgt_isa} = "armv7s" ]; then +- if [ -z "${float_abi}" ]; then +- check_cpp <<EOF && float_abi=hard || float_abi=softfp +-#ifndef __ARM_PCS_VFP +-#error "not hardfp" +-#endif +-EOF +- fi +- check_add_cflags -march=armv7-a -mfloat-abi=${float_abi} +- check_add_asflags -march=armv7-a -mfloat-abi=${float_abi} +- +- if enabled neon || enabled neon_asm; then +- check_add_cflags -mfpu=neon #-ftree-vectorize +- check_add_asflags -mfpu=neon +- fi +- elif [ ${tgt_isa} = "arm64" ] || [ ${tgt_isa} = "armv8" ]; then +- check_add_cflags -march=armv8-a +- check_add_asflags -march=armv8-a +- else +- check_add_cflags -march=${tgt_isa} +- check_add_asflags -march=${tgt_isa} +- fi +- + enabled debug && add_asflags -g + asm_conversion_cmd="${source_path}/build/make/ads2gas.pl" + if enabled thumb; then
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201901020810.x028A8SV021242>