Skip to content

Commit 7e7e850

Browse files
committed
libobjc2: Fix exception handling, linking
Backport two patches from libobjc2: - Fix uncaught exception handling (gnustep/libobjc2#278) - Export forwarders for C++ methods, so that we no longer need to link with the C++ runtime (gnustep/libobjc2#279)
1 parent bd1938f commit 7e7e850

File tree

1 file changed

+16
-3
lines changed

1 file changed

+16
-3
lines changed

mingw-w64-libobjc2/PKGBUILD

+16-3
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ _realname=libobjc2
44
pkgbase=mingw-w64-${_realname}
55
pkgname=("${MINGW_PACKAGE_PREFIX}-${_realname}")
66
pkgver=2.2
7-
pkgrel=1
7+
pkgrel=2
88
pkgdesc="Objective-C runtime library intended for use with Clang. (mingw-w64)"
99
arch=('any')
1010
mingw_arch=('mingw64' 'ucrt64' 'clang64')
@@ -21,18 +21,31 @@ source=("https://github.com/gnustep/${_realname}/archive/v${pkgver}/${_realname}
2121
# Support building on msys/clang64
2222
"https://github.com/gnustep/libobjc2/commit/1ff5e1298dd76aa370d5a12b690857f9a47b4b56.patch"
2323
# MinGW: Remove manual setting of library prefix/suffix
24-
"https://github.com/gnustep/libobjc2/commit/f983cdbf683925d942dd1d86edcfe4316bf9ed6c.patch")
24+
"https://github.com/gnustep/libobjc2/commit/f983cdbf683925d942dd1d86edcfe4316bf9ed6c.patch"
25+
# MinGW: Use _Unwind_RaiseException to throw exceptions
26+
"https://github.com/gnustep/libobjc2/commit/4af127abaa958127091d962109211df87a9b6c02.patch"
27+
# Use __cxa_throw on clang64
28+
"https://github.com/gnustep/libobjc2/commit/f0e601c910554bd507014a80a0d4afb5eb28dfa0.patch"
29+
# MSYS2: Export forwarders for __cxa_begin_catch, __cxa_end_catch, __cxa_rethrow and __gxx_personality_seh0
30+
"https://github.com/gnustep/libobjc2/commit/6ef33e5741640e4a320dad0f5378e54262e516a2.patch"
31+
)
2532
sha256sums=('c4c5cede579949249f16736c9b1f85c58c44addb013f59970dcb566d9069152a'
2633
'aaa23146b3c2ec442b5dbf20606020bddd15230041ad738ef3a06e92d13605c3'
2734
'fba7d33aa03ee7383b559c5b845063acd16b45396520250849f22559577adcc9'
28-
'd955fcee075af724a97d63f1b325e97ab6c3d018ac38f0597ef3e8c57b0820e2')
35+
'd955fcee075af724a97d63f1b325e97ab6c3d018ac38f0597ef3e8c57b0820e2'
36+
'4d35a16baa6700761fca976a02e64a526448e5d4b5129e311c96ed6dd057736e'
37+
'23e59362c08fca3d6457575d7ae3eeb6e32328abe936dc974a237f040cd4b374'
38+
'7dd7f6108be1df422aca8c9f2e59a964b9365508f86895039f41f6b19d977c9d')
2939

3040
prepare() {
3141
cd ${srcdir}/${_realname}-${pkgver}
3242

3343
patch -p1 -i ${srcdir}/639c676bb8033422539e19a2e2888bdbd06507e5.patch
3444
patch -p1 -i ${srcdir}/1ff5e1298dd76aa370d5a12b690857f9a47b4b56.patch
3545
patch -p1 -i ${srcdir}/f983cdbf683925d942dd1d86edcfe4316bf9ed6c.patch
46+
patch -p1 -i ${srcdir}/4af127abaa958127091d962109211df87a9b6c02.patch
47+
patch -p1 -i ${srcdir}/f0e601c910554bd507014a80a0d4afb5eb28dfa0.patch
48+
patch -p1 -i ${srcdir}/6ef33e5741640e4a320dad0f5378e54262e516a2.patch
3649
}
3750

3851
build() {

0 commit comments

Comments
 (0)