Skip to content

Commit d73b202

Browse files
committed
2.26; add cross toolchain on x86_64
1 parent 063232f commit d73b202

File tree

3 files changed

+361
-6
lines changed

3 files changed

+361
-6
lines changed

.SRCINFO

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
pkgbase = redpanda-cpp
22
pkgdesc = A fast, lightweight, open source, and cross platform C/C++/GNU Assembly IDE
3-
pkgver = 2.25
3+
pkgver = 2.26
44
pkgrel = 1
55
url = https://github.com/royqh1979/RedPanda-CPP
66
arch = i686
@@ -18,7 +18,15 @@ pkgbase = redpanda-cpp
1818
depends = gcc
1919
depends = gdb
2020
optdepends = clang: C/C++ compiler (alternative)
21-
source = RedPanda-CPP-2.25.tar.gz::https://github.com/royqh1979/RedPanda-CPP/archive/refs/tags/2.25.tar.gz
22-
sha256sums = 8e655b1522695618de7d973df6e732c853b4f8eabdc3efbea15a8820d97acc32
21+
source = RedPanda-CPP-2.26.tar.gz::https://github.com/royqh1979/RedPanda-CPP/archive/refs/tags/2.26.tar.gz
22+
source = compiler_hint.lua
23+
sha256sums = 8f8a5d131c4155c0af23bf2a1faa9ad1899d092b598010d43ebb2d8f0604942c
24+
sha256sums = 65647471f5360648800aaa6027a8d8be3e2121ce0c470b99b8cace6f1654f20d
25+
optdepends_x86_64 = mingw-w64-gcc: Windows C/C++ compiler
26+
optdepends_x86_64 = wine: run Windows executable
27+
optdepends_x86_64 = aarch64-linux-gnu-gcc: AArch64 C/C++ compiler
28+
optdepends_x86_64 = qemu-user-static: run AArch64 executable
29+
optdepends_x86_64 = qemu-user-static-binfmt: run AArch64 executable
30+
makedepends_x86_64 = mingw-w64-gcc
2331

2432
pkgname = redpanda-cpp

PKGBUILD

Lines changed: 37 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,44 @@
11
_pkgname=RedPanda-CPP
22
pkgname=${_pkgname,,}
3-
pkgver=2.25
3+
pkgver=2.26
44
pkgrel=1
55
pkgdesc='A fast, lightweight, open source, and cross platform C/C++/GNU Assembly IDE'
66
arch=('i686' 'pentium4' 'x86_64' 'arm' 'armv6h' 'armv7h' 'aarch64' 'riscv64')
77
url="https://github.com/royqh1979/$_pkgname"
88
license=('GPL3')
99
depends=(qt5-base qt5-svg gcc gdb)
1010
makedepends=(qt5-tools)
11+
makedepends_x86_64=(mingw-w64-gcc)
1112
optdepends=(
1213
'clang: C/C++ compiler (alternative)'
1314
)
14-
source=("$_pkgname-$pkgver.tar.gz::https://github.com/royqh1979/$_pkgname/archive/refs/tags/$pkgver.tar.gz")
15-
sha256sums=('8e655b1522695618de7d973df6e732c853b4f8eabdc3efbea15a8820d97acc32')
15+
optdepends_x86_64=(
16+
'mingw-w64-gcc: Windows C/C++ compiler'
17+
'wine: run Windows executable'
18+
'aarch64-linux-gnu-gcc: AArch64 C/C++ compiler'
19+
'qemu-user-static: run AArch64 executable'
20+
'qemu-user-static-binfmt: run AArch64 executable'
21+
)
22+
source=(
23+
"$_pkgname-$pkgver.tar.gz::https://github.com/royqh1979/$_pkgname/archive/refs/tags/$pkgver.tar.gz"
24+
'compiler_hint.lua'
25+
)
26+
sha256sums=('8f8a5d131c4155c0af23bf2a1faa9ad1899d092b598010d43ebb2d8f0604942c'
27+
'65647471f5360648800aaa6027a8d8be3e2121ce0c470b99b8cace6f1654f20d')
28+
29+
prepare() {
30+
sed -i '/CONFIG += ENABLE_LUA_ADDON/ { s/^#\s*// }' "$srcdir/$_pkgname-$pkgver/RedPandaIDE/RedPandaIDE.pro"
31+
}
1632

1733
build() {
34+
local _utf8dir="$srcdir/$_pkgname-$pkgver/platform/windows/utf8"
35+
if [[ "$CARCH" == 'x86_64' ]]; then
36+
x86_64-w64-mingw32-gcc -Os -fno-exceptions -nodefaultlibs -nostdlib -c -o utf8init.x86_64.o "$_utf8dir/utf8init.cpp"
37+
x86_64-w64-mingw32-windres -O coff -o utf8manifest.x86_64.o "$_utf8dir/utf8manifest.rc"
38+
i686-w64-mingw32-gcc -Os -fno-exceptions -nodefaultlibs -nostdlib -c -o utf8init.i686.o "$_utf8dir/utf8init.cpp"
39+
i686-w64-mingw32-windres -O coff -o utf8manifest.i686.o "$_utf8dir/utf8manifest.rc"
40+
fi
41+
1842
mkdir redpanda-build
1943
cd redpanda-build
2044
qmake \
@@ -26,6 +50,16 @@ build() {
2650
}
2751

2852
package() {
53+
local _libexecdir="$pkgdir/usr/lib/RedPandaCPP"
54+
install -Dm644 "compiler_hint.lua" "$_libexecdir/compiler_hint.lua"
55+
56+
if [[ "$CARCH" == 'x86_64' ]]; then
57+
install -Dm644 "utf8init.x86_64.o" "$_libexecdir/x86_64-w64-mingw32/utf8init.o"
58+
install -Dm644 "utf8manifest.x86_64.o" "$_libexecdir/x86_64-w64-mingw32/utf8manifest.o"
59+
install -Dm644 "utf8init.i686.o" "$_libexecdir/i686-w64-mingw32/utf8init.o"
60+
install -Dm644 "utf8manifest.i686.o" "$_libexecdir/i686-w64-mingw32/utf8manifest.o"
61+
fi
62+
2963
cd redpanda-build
3064
make INSTALL_ROOT="$pkgdir" install
3165
}

0 commit comments

Comments
 (0)