Skip to content

Commit db9dac2

Browse files
committed
gst-plugins-rs: update to 1.26.0
1 parent 1acfa3b commit db9dac2

File tree

3 files changed

+97
-17
lines changed

3 files changed

+97
-17
lines changed

mingw-w64-gst-plugins-rs/.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
/aws-lc-rs
2+
/aws-lc

mingw-w64-gst-plugins-rs/PKGBUILD

+49-17
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,13 @@
33
_realname=gst-plugins-rs
44
pkgbase=mingw-w64-${_realname}
55
pkgname=${MINGW_PACKAGE_PREFIX}-${_realname}
6-
pkgver=1.24.12
7-
_tag=gstreamer-$pkgver
8-
pkgrel=2
6+
pkgver=1.26.0
7+
_tag=gstreamer-${pkgver}
8+
pkgrel=1
99
pkgdesc='GStreamer plugins written in Rust (mingw-w64)'
1010
arch=(any)
1111
mingw_arch=('mingw64' 'ucrt64' 'clang64')
12-
url="https://gitlab.freedesktop.org/gstreamer/$_realname"
12+
url='https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs'
1313
license=('spdx:LGPL-3.0-or-later AND Apache-2.0 AND MIT AND MPL-2.0')
1414
depends=(${MINGW_PACKAGE_PREFIX}-gtk4
1515
${MINGW_PACKAGE_PREFIX}-libsodium
@@ -19,14 +19,44 @@ depends=(${MINGW_PACKAGE_PREFIX}-gtk4
1919
${MINGW_PACKAGE_PREFIX}-libwebp)
2020
makedepends=(${MINGW_PACKAGE_PREFIX}-rust
2121
${MINGW_PACKAGE_PREFIX}-cargo-c
22-
${MINGW_PACKAGE_PREFIX}-pkgconf)
23-
source=("$url/-/archive/$_tag/$_realname-gstreamer-$_tag.tar.bz2")
24-
sha256sums=('29ee51abe820db58338942c2c6d5fa0e94180117eb29c8f26797c3f1b6757b7d')
22+
${MINGW_PACKAGE_PREFIX}-cmake
23+
${MINGW_PACKAGE_PREFIX}-pkgconf
24+
${MINGW_PACKAGE_PREFIX}-nasm
25+
${MINGW_PACKAGE_PREFIX}-rust-bindgen
26+
${MINGW_PACKAGE_PREFIX}-cargo-edit
27+
git)
28+
source=("${url}/-/archive/${_tag}/${_realname}-gstreamer-${_tag}.tar.bz2"
29+
"git+https://github.com/aws/aws-lc-rs.git#tag=aws-lc-sys/v0.27.0"
30+
"git+https://github.com/aws/aws-lc.git"
31+
"aws-lc-clang-build.patch")
32+
sha256sums=('d1d2cd9111ff166f41f09a83e13bc397ef5c075bcca72dac9f8b506e1c93ff6c'
33+
'371b865c75caa66947b3b8e4e001e4255577c8320ba8875ae5212d3dc7dcc3a1'
34+
'SKIP'
35+
'2e3d7ef6fdb3ef8a2ec11207e8120ea34553888116ea8a032cb425a8a6261c39')
2536

2637
prepare() {
27-
mv "$_realname-$_tag-"* "$_realname-$_tag"
28-
cd $_realname-$_tag
29-
cargo fetch
38+
mv "${_realname}-${_tag}-"* "${_realname}-${_tag}"
39+
40+
(cd aws-lc-rs
41+
git config submodule."aws-lc-sys/aws-lc".url "${srcdir}/aws-lc"
42+
git config submodule."aws-lc-fips-sys/aws-lc".url "${srcdir}/aws-lc"
43+
git -c protocol.file.allow=always submodule update --init --recursive)
44+
45+
if [ ${CC} = clang ]; then
46+
patch -d aws-lc -p1 -i "${srcdir}/aws-lc-clang-build.patch"
47+
fi
48+
49+
cd "${_realname}-${_tag}"
50+
51+
cargo update -p [email protected] --precise 1.12.6
52+
cat >> Cargo.toml <<END
53+
54+
[patch.crates-io]
55+
aws-lc-sys = { path = "../aws-lc-rs/aws-lc-sys" }
56+
END
57+
58+
cargo update -p aws-lc-sys
59+
cargo fetch --locked
3060
}
3161

3262
_cargo_opts=(--workspace
@@ -36,22 +66,24 @@ _cargo_opts=(--workspace
3666
--library-type=cdylib
3767
--prefix="${MINGW_PREFIX}"
3868
--exclude gst-plugin-csound
39-
--exclude gst-plugin-dav1d # not compatiple with dav1d 1.3.0 yet
40-
--exclude gst-plugin-aws)
69+
--exclude gst-plugin-dav1d) # not compatiple with dav1d 1.3.0 yet
4170

4271
build() {
43-
cd $_realname-$_tag
72+
cd "${_realname}-${_tag}"
73+
4474
MSYS2_ARG_CONV_EXCL="--prefix=" cargo cbuild "${_cargo_opts[@]}"
4575
}
4676

4777
check() {
48-
cd $_realname-$_tag
78+
cd "${_realname}-${_tag}"
79+
4980
MSYS2_ARG_CONV_EXCL="--prefix=" cargo ctest "${_cargo_opts[@]}" --target-dir=tests-build
5081
}
5182

5283
package() {
53-
cd $_realname-$_tag
54-
MSYS2_ARG_CONV_EXCL="--prefix=" cargo cinstall "${_cargo_opts[@]}" --destdir="$pkgdir"
84+
cd "${_realname}-${_tag}"
85+
86+
MSYS2_ARG_CONV_EXCL="--prefix=" cargo cinstall "${_cargo_opts[@]}" --destdir="${pkgdir}"
5587

56-
install -Dm644 -t "$pkgdir/$MINGW_PREFIX"/share/licenses/$_realname/ LICENSE*
88+
install -Dm644 -t "${pkgdir}${MINGW_PREFIX}/share/licenses/${_realname}/" LICENSE*
5789
}
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
diff --git a/CMakeLists.txt b/CMakeLists.txt
2+
index fcb8c928e..d283a6ed4 100644
3+
--- a/CMakeLists.txt
4+
+++ b/CMakeLists.txt
5+
@@ -399,7 +399,7 @@ if(GCC OR CLANG)
6+
set(C_CXX_FLAGS "${C_CXX_FLAGS} -Wno-deprecated-declarations")
7+
else()
8+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wextra")
9+
- set(C_CXX_FLAGS "${C_CXX_FLAGS} -Wall -fvisibility=hidden -fno-common")
10+
+ set(C_CXX_FLAGS "${C_CXX_FLAGS} -Wall -fvisibility=hidden -fno-common -fms-extensions")
11+
set(CMAKE_ASM_FLAGS "${CMAKE_ASM_FLAGS} -Wno-newline-eof")
12+
endif()
13+
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wunused -Wcomment -Wchar-subscripts -Wuninitialized -Wshadow")
14+
diff --git a/crypto/internal.h b/crypto/internal.h
15+
index 4e42bb5b5..cb74fac23 100644
16+
--- a/crypto/internal.h
17+
+++ b/crypto/internal.h
18+
@@ -141,7 +141,7 @@
19+
#endif
20+
21+
#if defined(OPENSSL_THREADS) && \
22+
- (!defined(OPENSSL_WINDOWS) || defined(__MINGW32__))
23+
+ (!defined(OPENSSL_WINDOWS) || defined(__MINGW32__) && !defined(__clang__))
24+
#include <pthread.h>
25+
#define OPENSSL_PTHREADS
26+
#endif
27+
diff --git a/crypto/thread_win.c b/crypto/thread_win.c
28+
index 9a1f8045e..0606e6db0 100644
29+
--- a/crypto/thread_win.c
30+
+++ b/crypto/thread_win.c
31+
@@ -146,6 +146,7 @@ static void NTAPI thread_local_destructor(PVOID module, DWORD reason,
32+
// optimization from discarding the variable.
33+
//
34+
// Note, in the prefixed build, |p_thread_callback_boringssl| may be a macro.
35+
+#ifdef _MSC_VER
36+
#define STRINGIFY(x) #x
37+
#define EXPAND_AND_STRINGIFY(x) STRINGIFY(x)
38+
#ifdef _WIN64
39+
@@ -157,6 +158,7 @@ __pragma(comment(linker, "/INCLUDE:__tls_used"))
40+
__pragma(comment(
41+
linker, "/INCLUDE:_" EXPAND_AND_STRINGIFY(p_thread_callback_boringssl)))
42+
#endif
43+
+#endif
44+
45+
// .CRT$XLA to .CRT$XLZ is an array of PIMAGE_TLS_CALLBACK pointers that are
46+
// called automatically by the OS loader code (not the CRT) when the module is

0 commit comments

Comments
 (0)