Skip to content

Commit 63d9bf1

Browse files
committed
test
1 parent b12ca4f commit 63d9bf1

File tree

3 files changed

+23
-10
lines changed

3 files changed

+23
-10
lines changed

build-ffmpeg.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ shift 1
1111
cd $SRC_DIR
1212

1313
if [ $BUILD_TYPE == "static" ]; then
14-
CFLAGS="$CFLAGS /MT"
14+
CFLAGS="$CFLAGS -MT"
1515
TYPE_ARGS="--enable-static --pkg-config-flags=--static"
1616
else
17-
CFLAGS="$CFLAGS /MD"
17+
CFLAGS="$CFLAGS -MD"
1818
TYPE_ARGS="--enable-shared"
1919
fi
2020
if [[ $BUILD_ARCH =~ arm ]]; then
@@ -27,7 +27,7 @@ fi
2727
CFLAGS="$CFLAGS -I${SRC_DIR}/compat/stdbit"
2828
EX_BUILD_ARGS="$TYPE_ARGS $CROSS_ARGS $LICENSE_ARGS"
2929

30-
./configure --toolchain=msvc --arch=$BUILD_ARCH $EX_BUILD_ARGS $@
30+
CFLAGS="$CFLAGS" ./configure --toolchain=msvc --arch=$BUILD_ARCH $EX_BUILD_ARGS $@
3131
iconv -f gbk config.h >config.h.tmp && mv config.h.tmp config.h
3232
make -j$(nproc)
3333
make install prefix=$INSTALL_PREFIX

build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ if [ -n "$ENABLE_LIBVPX" ]; then
122122
fi
123123
apply-patch libvpx libvpx.patch
124124
export
125-
AS=yasm AR=lib ARFLAGS= CC=cl CXX=cl LD=link STRIP=false target= ./build-make-dep.sh libvpx --target=$libvpx_target --as=yasm --disable-optimizations --disable-dependency-tracking --disable-runtime-cpu-detect --disable-thumb --disable-neon --enable-external-build --disable-unit-tests --disable-decode-perf-tests --disable-encode-perf-tests --disable-examples $LIBVPX_ARGS
125+
AS=yasm AR=lib ARFLAGS= CC=cl CXX=cl LD=link STRIP=false target= ./build-make-dep.sh libvpx --target=$libvpx_target --as=yasm --disable-optimizations --disable-dependency-tracking --disable-runtime-cpu-detect --disable-thumb --disable-neon --enable-external-build --disable-unit-tests --disable-decode-perf-tests --disable-encode-perf-tests --disable-tools --disable-examples $LIBVPX_ARGS
126126
FF_ARGS=--enable-libvpx
127127
fi
128128

patches/libvpx.patch

Lines changed: 19 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ index d1d89aa69..155c43c54 100644
185185
ASFLAGS = ${ASFLAGS}
186186
extralibs = ${extralibs}
187187
diff --git a/build/make/gen_msvs_sln.sh b/build/make/gen_msvs_sln.sh
188-
index 0b312850f..9fbb7a6f9 100755
188+
index 0b312850f..d566ae4be 100755
189189
--- a/build/make/gen_msvs_sln.sh
190190
+++ b/build/make/gen_msvs_sln.sh
191191
@@ -70,7 +70,9 @@ parse_project() {
@@ -204,7 +204,7 @@ index 0b312850f..9fbb7a6f9 100755
204204
$nows_sln_config: $outfile
205205
${TAB}\$(MSBUILD_TOOL) $outfile -m -t:Build \\
206206
-${TAB}${TAB}-p:Configuration="$config" -p:Platform="$platform"
207-
+${TAB}${TAB}-p:Configuration="$config" -p:Platform="$platform" -p:WindowsTargetPlatformVersion="$SDK_VER"
207+
+${TAB}${TAB}-p:Configuration="$config" -p:Platform="$platform" -p:VCToolsVersion="$VSCMD_ARG_VCVARS_VER" -p:WindowsTargetPlatformVersion="$UCRTVersion"
208208
else
209209
$nows_sln_config: $outfile .nodevenv.once
210210
${TAB}@echo " * Skipping build of $sln_config (\$(MSBUILD_TOOL) not in path)."
@@ -218,9 +218,22 @@ index 0b312850f..9fbb7a6f9 100755
218218
;;
219219
*) file_list[${#file_list[@]}]="$opt"
220220
diff --git a/build/make/gen_msvs_vcxproj.sh b/build/make/gen_msvs_vcxproj.sh
221-
index 1e1db05bb..5b7e090ed 100755
221+
index 1e1db05bb..6f6ea0eda 100755
222222
--- a/build/make/gen_msvs_vcxproj.sh
223223
+++ b/build/make/gen_msvs_vcxproj.sh
224+
@@ -270,9 +270,9 @@ case "$target" in
225+
arm64*)
226+
platforms[0]="ARM64"
227+
# As of Visual Studio 2022 17.5.5, clang-cl does not support ARM64EC.
228+
- if [ "$vs_ver" -ge 17 -a "$platform_toolset" != "ClangCl" ]; then
229+
- platforms[1]="ARM64EC"
230+
- fi
231+
+ # if [ "$vs_ver" -ge 17 -a "$platform_toolset" != "ClangCl" ]; then
232+
+ # platforms[1]="ARM64EC"
233+
+ # fi
234+
asm_Debug_cmdline="armasm64 -nologo -oldit "%(FullPath)""
235+
asm_Release_cmdline="armasm64 -nologo -oldit "%(FullPath)""
236+
;;
224237
@@ -311,7 +311,8 @@ generate_vcxproj() {
225238
tag_content RootNamespace ${name}
226239
tag_content Keyword ManagedCProj
@@ -246,12 +259,12 @@ index 1e1db05bb..5b7e090ed 100755
246259
fi
247260
tag_content TargetName "${name}${lib_sfx}${config_suffix}"
248261
fi
249-
+ tag_content ExecutablePath "\$(VC_ExecutablePath_x64_ARM);\$(CommonExecutablePath)"
262+
+ tag_content ExecutablePath "\$(VC_ExecutablePath_${VSCMD_ARG_HOST_ARCH}_${VSCMD_ARG_TGT_ARCH});\$(CommonExecutablePath)"
250263
close_tag PropertyGroup
251264
done
252265
done
253266
diff --git a/libs.mk b/libs.mk
254-
index d5076b7e8..f7f615bfd 100644
267+
index d5076b7e8..70affdace 100644
255268
--- a/libs.mk
256269
+++ b/libs.mk
257270
@@ -152,8 +152,8 @@ INSTALL_MAPS += include/vpx/% $(SRC_PATH_BARE)/vpx_ports/%
@@ -299,7 +312,7 @@ index d5076b7e8..f7f615bfd 100644
299312
+ $(qexec)echo 'Version: $(VERSION_MAJOR).$(VERSION_MINOR).$(VERSION_PATCH)' >> $@
300313
+ $(qexec)echo 'Requires:' >> $@
301314
+ $(qexec)echo 'Conflicts:' >> $@
302-
+ $(qexec)echo 'Libs: -L$${libdir} -lvpx$(if $(CONFIG_STATIC_MSVCRT),mt,md)' >> $@
315+
+ $(qexec)echo 'Libs: -L$${libdir} -lvpx$(if $(CONFIG_STATIC_MSVCRT),mt,md -lmsvcrt)' >> $@
303316
+ifeq ($(HAVE_PTHREAD_H),yes)
304317
+ $(qexec)echo 'Libs.private: -lpthread' >> $@
305318
+else

0 commit comments

Comments
 (0)