Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/extra/fpc/PKGBUILD
diff options
context:
space:
mode:
authorErich Eckner <git@eckner.net>2023-05-22 20:18:50 +0200
committerErich Eckner <git@eckner.net>2023-05-22 20:18:50 +0200
commite74cde76c104df82b120a7b13964cb786da8f565 (patch)
tree39967e24037929c04aaf79922aa260b437a60a5e /extra/fpc/PKGBUILD
parent73e1d3b448cc583ab38cae4d61a26f313fad946b (diff)
community -> extra
Diffstat (limited to 'extra/fpc/PKGBUILD')
-rw-r--r--extra/fpc/PKGBUILD28
1 files changed, 28 insertions, 0 deletions
diff --git a/extra/fpc/PKGBUILD b/extra/fpc/PKGBUILD
new file mode 100644
index 00000000..71bd6540
--- /dev/null
+++ b/extra/fpc/PKGBUILD
@@ -0,0 +1,28 @@
+# symlink for 32-bit Pascal compiler
+
+# temporary:
+# the package has been built wrongly in the past, so we have to force
+# a ppc386 symlink in build (PP variable) because the Makefile is trying to
+# guess the target platform by executing fpc
+
+eval "$(
+ declare -f package | \
+ sed '
+ 2 a _pkgver=$(find /usr/lib/fpc -name ppc386 | cut -d/ -f5 | sort -V | tail -n1)
+ /"\$CARCH" = "x86_64"/ {
+ p
+ s@ppcx64@ppc386@g
+ s@x86_64@i686@
+ p
+ s@i686@i486@
+ p
+ s@i486@pentium4@
+ }
+ s@NOGDB=1@NOGDB=1 PP=/usr/lib/fpc/$_pkgver/ppc386 @
+ '
+ declare -f build | \
+ sed '
+ 2 a _pkgver=$(find /usr/lib/fpc -name ppc386 | cut -d/ -f5 | sort -V | tail -n1)
+ s@NOGDB=1@NOGDB=1 PP=/usr/lib/fpc/$_pkgver/ppc386 @
+ '
+)"