You are not logged in.
https://aur.archlinux.org/packages/djgpp-djcrx
So I am trying to install this package here, but it appears I cannot. I followed the fix in the comments exactly, but it just won't work. There appears to be an error when installing, even with the patch.
EDIT:
Here is the error log. Note that I applied the patch according to the patch in the comments:
==> Making package: djgpp-djcrx 2.05-11 (Fri 24 Mar 2023 10:00:28 AM)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
-> Downloading djcrx205.zip...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 874k 100 874k 0 0 566k 0 0:00:01 0:00:01 --:--:-- 566k
-> Downloading djlsr205.zip...
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 1999k 100 1999k 0 0 2994k 0 --:--:-- --:--:-- --:--:-- 2992k
-> Found ttyscrn.patch
-> Found nmemalign.patch
-> Found fseeko64.patch
-> Found asm.patch
-> Found dxegen.patch
-> Found djgpp-djcrx-gcccompat.patch
-> Found gcc-12.patch
==> Validating source files with sha256sums...
djcrx205.zip ... Passed
djlsr205.zip ... Passed
ttyscrn.patch ... Passed
nmemalign.patch ... Passed
fseeko64.patch ... Passed
asm.patch ... Passed
dxegen.patch ... Passed
djgpp-djcrx-gcccompat.patch ... Passed
gcc-12.patch ... Passed
==> Extracting sources...
-> Extracting djcrx205.zip with bsdtar
-> Extracting djlsr205.zip with bsdtar
==> Starting prepare()...
patching file src/libc/ansi/locale/makefile
patching file src/libc/ansi/string/makefile
patching file src/libc/c99/math/makefile
patching file src/libc/compat/stdio/makefile
patching file src/libc/compat/string/makefile
patching file src/libc/compat/unistd/makefile
patching file src/libc/dos/process/dosexec.c
patching file src/libc/dos/process/makefile
patching file src/libc/posix/string/makefile
patching file src/libm/math/e_asin.c
patching file src/libm/math/ef_asin.c
patching file src/libm/math/ef_jn.c
patching file src/libm/math/kf_rem_pio2.c
patching file src/libm/math/k_rem_pio2.c
patching file src/libm/math/s_scalbn.c
patching file src/libm/math/sf_scalbn.c
patching file src/utils/djtar/unlzh.c
patching file src/debug/common/makefile
patching file src/debug/fsdb/ed.c
patching file src/debug/fsdb/fullscr.c
patching file src/debug/fsdb/screen.h
patching file src/debug/fsdb/unassmbl.h
patching file src/libc/ansi/stdlib/exit.c
patching file src/libc/ansi/time/makefile
patching file src/libc/crt0/makefile
patching file src/libc/dos/io/makefile
patching file src/libc/emu387/npxsetup.c
patching file src/libc/go32/dpmiexcp.c
patching file src/libc/posix/fcntl/makefile
patching file src/libm/math/k_standard.c
patching file src/libm/math/sf_cos.c
patching file src/utils/djtar/zread.h
patching file src/utils/redir.c
patching file src/libc/posix/termios/ttyscrn.c
patching file src/libc/ansi/stdlib/nmalloc.c
patching file src/libc/compat/stdio/fseeko64.c
patching file src/libc/go32/dpmiexcp.c
patching file src/dxe/dxegen.c
patching file src/dxe/dxe3gen.c
patching file src/libc/ansi/stdio/makefile
patching file src/libc/ansi/stdlib/makefile
patching file src/libc/dos/process/makefile
patching file src/libemu/src/makefile
Hunk #1 FAILED at 16.
1 out of 1 hunk FAILED -- saving rejects to file src/libemu/src/makefile.rej
patching file src/libm/math/makefile
Hunk #1 succeeded at 224 with fuzz 2.
==> ERROR: A failure occurred in prepare().
Aborting...EDIT 2:
gcc-12.patch:
Only in a: gcc-12.patch
diff -r -U3 a/src/libc/ansi/stdio/makefile b/src/libc/ansi/stdio/makefile
--- a/src/libc/ansi/stdio/makefile 2001-05-21 19:25:49.000000000 +0200
+++ b/src/libc/ansi/stdio/makefile 2023-01-14 14:31:35.361845387 +0100
@@ -66,3 +66,6 @@
SRC += vsnprntf.c
include $(TOP)/../makefile.inc
+
+doscan.o: EXTRA_CFLAGS= -Wno-use-after-free
+rename.o: EXTRA_CFLAGS= -Wno-use-after-free
diff -r -U3 a/src/libc/ansi/stdlib/makefile b/src/libc/ansi/stdlib/makefile
--- a/src/libc/ansi/stdlib/makefile 2015-05-02 06:32:11.000000000 +0200
+++ b/src/libc/ansi/stdlib/makefile 2023-01-14 14:31:35.371845403 +0100
@@ -37,6 +37,6 @@
# FIXME: This is really only needed for gcc-5 .
# Unfortunatelly GCC version is not yet checked
# here.
-nmalloc.o: EXTRA_CFLAGS := -fno-builtin-malloc
+nmalloc.o: EXTRA_CFLAGS := -fno-builtin-malloc -Wno-free-nonheap-object
include $(TOP)/../makefile.inc
diff -r -U3 a/src/libc/dos/process/makefile b/src/libc/dos/process/makefile
--- a/src/libc/dos/process/makefile 2023-01-14 14:52:48.651858329 +0100
+++ b/src/libc/dos/process/makefile 2023-01-14 14:31:35.381845420 +0100
@@ -14,4 +14,4 @@
include $(TOP)/../makefile.inc
-dosexec.o: EXTRA_CFLAGS += -Wno-stringop-overflow
+dosexec.o: EXTRA_CFLAGS += -Wno-stringop-overflow -Wno-stringop-truncation
diff -r -U3 a/src/libemu/src/makefile b/src/libemu/src/makefile
--- a/src/libemu/src/makefile 2015-05-02 06:32:33.000000000 +0200
+++ b/src/libemu/src/makefile 2023-01-14 14:31:35.401845452 +0100
@@ -16,7 +16,7 @@
# FIXME: fix emu387.cc instead to avoid need for -fno-strict-aliasing
%.o : %.cc
- $(XNOPGGPP) -c -fno-exceptions -fno-strict-aliasing $<
+ $(XNOPGGPP) -c -fno-exceptions -fno-strict-aliasing -Wno-register $<
%.o : %.c
$(XNOPGGCC) -c $<
diff -r -U3 a/src/libm/math/makefile b/src/libm/math/makefile
--- a/src/libm/math/makefile 2015-07-18 16:07:52.000000000 +0200
+++ b/src/libm/math/makefile 2023-01-14 14:31:35.411845468 +0100
@@ -224,6 +224,9 @@
chew.exe: chew.c
$(GCC) -O2 -o $@ $<
+k_rem_pio2.o: EXTRA_CFLAGS += -Wno-maybe-uninitialized
+kf_rem_pio2.o: EXTRA_CFLAGS += -Wno-maybe-uninitialized
+
clean ::
-$(MISC) rm *.def *.d chew.exe targetdep.texiPKGBUILD:
# Contributor: Andris Pavenis <andris.pavenis iki fi>
# Contributor: carstene1ns <arch carsten-teibes de>
# Contributor: felix <base64 -d <<< ZmVsaXgudm9uLnNAcG9zdGVvLmRlCg==>
# Contributor: Schala
pkgname=djgpp-djcrx
pkgver=2.05
pkgrel=11
pkgdesc="Headers and utilities for the djgpp cross-compiler"
arch=('i686' 'x86_64')
url="http://www.delorie.com/djgpp/"
depends=('glibc' 'gcc-libs')
conflicts=('djgpp-djcrx-bootstrap')
license=('GPL' 'LGPL' 'custom:djgpp')
source=("http://www.delorie.com/pub/djgpp/current/v2/djcrx${pkgver//./}.zip"
"http://www.delorie.com/pub/djgpp/current/v2/djlsr${pkgver//./}.zip"
ttyscrn.patch
nmemalign.patch
fseeko64.patch
asm.patch
dxegen.patch
djgpp-djcrx-gcccompat.patch
gcc-12.patch)
makedepends=('djgpp-gcc' 'djgpp-binutils')
sha256sums=('22274ed8d5ee57cf7ccf161f5e1684fd1c0192068724a7d34e1bde168041ca60'
'80690b6e44ff8bc6c6081fca1f4faeba1591c4490b76ef0ec8b35847baa5deea'
'83bc02407566c0613c2eeb86d78f2968c11256dfc8d3c2805a5488540e059124'
'ffdbab52eb13dde716fbcce54154f7c95644afd6333f4931b2cceeb95935c675'
'536684b0152f7ad77b99bcc5ea535ca8339832399c4582b944ccd882e4b261a1'
'693810c3242f4e23cdc55d3101281721da9407851e5d29459ad59405e534b916'
'0debe0161e27aeb004e89a43915d6d77bcd07a5db2c67e2798568535fe9143f1'
'8c16b24e34dc46fee86531349a84d7353552db2eff008cb9d5ffd35ec3a7249a'
'7498f403b3b193ffab45c691ce6f5450d7af3113c8f1b30f3f0ef9475908b656')
options=('!buildflags' '!strip')
_target='i686-pc-msdosdjgpp'
prepare() {
sed -i "s/i586-pc-msdosdjgpp/$_target/" src/makefile.def src/dxe/makefile.dxe
sed -i 's/ln/ln -f/' src/dxe/makefile.dxe
# fix build with gcc >= 8
patch -Np1 < djgpp-djcrx-gcccompat.patch
# gcc provides its own float.h which masks this one
ln -fs float.h include/djfloat.h
sed -i 's/<float\.h>/<djfloat.h>/' src/libc/{go32/dpmiexcp,emu387/npxsetup}.c src/utils/redir.c
# fix libc bugs
patch -Np0 < ttyscrn.patch
patch -Np0 < nmemalign.patch
patch -Np0 < fseeko64.patch
patch -Np0 < asm.patch
# allow using dxe3gen without DJDIR and without dxe3res in PATH
patch -Np0 < dxegen.patch
# be verbose
#sed -i '/@$(MISC) echo - / d; s/^\t@/\t/' src/makefile.inc src/libc/makefile src/utils/makefile
# fix build with gcc >= 12
patch -Np1 < gcc-12.patch
}
build() {
cd src
make clean
make -j1
cd dxe
make -f makefile.dxe
}
package() {
install -d "$pkgdir"/usr/bin
install -d "$pkgdir"/usr/$_target/bin
install -d "$pkgdir"/usr/$_target/sys-include
cp -r include/* "$pkgdir"/usr/$_target/sys-include
cp -r lib "$pkgdir"/usr/$_target
cd hostbin
for _file in djasm mkdoc stubedit stubify; do
install -m0755 $_file.exe "$pkgdir"/usr/$_target/bin/$_file
ln -s ../$_target/bin/$_file "$pkgdir"/usr/bin/$_target-$_file
done
cd ../src/dxe
for _file in dxe3gen dxe3res; do
install -m0755 $_file "$pkgdir"/usr/$_target/bin/$_file
ln -s ../$_target/bin/$_file "$pkgdir"/usr/bin/$_target-$_file
done
ln -s dxe3gen "$pkgdir"/usr/$_target/bin/dxegen
cd "$srcdir"
install -Dm644 copying.dj "$pkgdir"/usr/share/licenses/$pkgname/copying.dj
cd info
for _file in *.info; do
install -Dm0644 $_file "$pkgdir"/usr/share/info/djgpp-$_file
done
}Last edited by mechSkeletal5857 (2023-03-24 15:28:53)
Offline
What does "just won't work" mean? Post the actual error message you see when attempting to build/install and somebody might be able to help you
Offline
Moving to AUR issues.
Offline
I added the error logs
Offline
Please also post the contents of the patch file you created and the PKGBUILD with the changes you made to apply the patch.
Offline
I added the patch and PKGBUILD
Offline
In the patch from https://aur.archlinux.org/packages/djgp … ent-897646 tabs have been converted to spaces so it does not apply cleanly. Either pass the -l option to patch to ignore whitespace differences or use the patch below which hopefully has preserved the tabs
diff --git a/src/libc/ansi/stdio/makefile b/src/libc/ansi/stdio/makefile
index fe2b92e..12aa4a8 100644
--- a/src/libc/ansi/stdio/makefile
+++ b/src/libc/ansi/stdio/makefile
@@ -66,3 +66,6 @@ SRC += snprintf.c
SRC += vsnprntf.c
include $(TOP)/../makefile.inc
+
+doscan.o: EXTRA_CFLAGS= -Wno-use-after-free
+rename.o: EXTRA_CFLAGS= -Wno-use-after-free
diff --git a/src/libc/ansi/stdlib/makefile b/src/libc/ansi/stdlib/makefile
index a6279f1..cc1a9ac 100644
--- a/src/libc/ansi/stdlib/makefile
+++ b/src/libc/ansi/stdlib/makefile
@@ -37,6 +37,6 @@ SRC += system.c
# FIXME: This is really only needed for gcc-5 .
# Unfortunatelly GCC version is not yet checked
# here.
-nmalloc.o: EXTRA_CFLAGS := -fno-builtin-malloc
+nmalloc.o: EXTRA_CFLAGS := -fno-builtin-malloc -Wno-free-nonheap-object
include $(TOP)/../makefile.inc
diff --git a/src/libc/dos/process/makefile b/src/libc/dos/process/makefile
index 512d1f3..a88c48d 100644
--- a/src/libc/dos/process/makefile
+++ b/src/libc/dos/process/makefile
@@ -14,4 +14,4 @@ SRC += spawnvpe.c
include $(TOP)/../makefile.inc
-dosexec.o: EXTRA_CFLAGS += -Wno-stringop-overflow
+dosexec.o: EXTRA_CFLAGS += -Wno-stringop-overflow -Wno-stringop-truncation
diff --git a/src/libemu/src/makefile b/src/libemu/src/makefile
index ee9bf5f..3717c3b 100644
--- a/src/libemu/src/makefile
+++ b/src/libemu/src/makefile
@@ -16,7 +16,7 @@ include $(TOP)/../makefile.inc
# FIXME: fix emu387.cc instead to avoid need for -fno-strict-aliasing
%.o : %.cc
- $(XNOPGGPP) -c -fno-exceptions -fno-strict-aliasing $<
+ $(XNOPGGPP) -c -fno-exceptions -fno-strict-aliasing -Wno-register $<
%.o : %.c
$(XNOPGGCC) -c $<
diff --git a/src/libm/math/makefile b/src/libm/math/makefile
index 2acc5a2..6718f06 100644
--- a/src/libm/math/makefile
+++ b/src/libm/math/makefile
@@ -224,6 +224,9 @@ targetdep.texi: $(chobj) math.texi
chew.exe: chew.c
$(GCC) -O2 -o $@ $<
+k_rem_pio2.o: EXTRA_CFLAGS += -Wno-maybe-uninitialized
+kf_rem_pio2.o: EXTRA_CFLAGS += -Wno-maybe-uninitialized
+
clean ::
-$(MISC) rm *.def *.d chew.exe targetdep.texi
Offline
In the patch from https://aur.archlinux.org/packages/djgp … ent-897646 tabs have been converted to spaces so it does not apply cleanly. Either pass the -l option to patch to ignore whitespace differences or use the patch below which hopefully has preserved the tabs
diff --git a/src/libc/ansi/stdio/makefile b/src/libc/ansi/stdio/makefile index fe2b92e..12aa4a8 100644 --- a/src/libc/ansi/stdio/makefile +++ b/src/libc/ansi/stdio/makefile @@ -66,3 +66,6 @@ SRC += snprintf.c SRC += vsnprntf.c include $(TOP)/../makefile.inc + +doscan.o: EXTRA_CFLAGS= -Wno-use-after-free +rename.o: EXTRA_CFLAGS= -Wno-use-after-free diff --git a/src/libc/ansi/stdlib/makefile b/src/libc/ansi/stdlib/makefile index a6279f1..cc1a9ac 100644 --- a/src/libc/ansi/stdlib/makefile +++ b/src/libc/ansi/stdlib/makefile @@ -37,6 +37,6 @@ SRC += system.c # FIXME: This is really only needed for gcc-5 . # Unfortunatelly GCC version is not yet checked # here. -nmalloc.o: EXTRA_CFLAGS := -fno-builtin-malloc +nmalloc.o: EXTRA_CFLAGS := -fno-builtin-malloc -Wno-free-nonheap-object include $(TOP)/../makefile.inc diff --git a/src/libc/dos/process/makefile b/src/libc/dos/process/makefile index 512d1f3..a88c48d 100644 --- a/src/libc/dos/process/makefile +++ b/src/libc/dos/process/makefile @@ -14,4 +14,4 @@ SRC += spawnvpe.c include $(TOP)/../makefile.inc -dosexec.o: EXTRA_CFLAGS += -Wno-stringop-overflow +dosexec.o: EXTRA_CFLAGS += -Wno-stringop-overflow -Wno-stringop-truncation diff --git a/src/libemu/src/makefile b/src/libemu/src/makefile index ee9bf5f..3717c3b 100644 --- a/src/libemu/src/makefile +++ b/src/libemu/src/makefile @@ -16,7 +16,7 @@ include $(TOP)/../makefile.inc # FIXME: fix emu387.cc instead to avoid need for -fno-strict-aliasing %.o : %.cc - $(XNOPGGPP) -c -fno-exceptions -fno-strict-aliasing $< + $(XNOPGGPP) -c -fno-exceptions -fno-strict-aliasing -Wno-register $< %.o : %.c $(XNOPGGCC) -c $< diff --git a/src/libm/math/makefile b/src/libm/math/makefile index 2acc5a2..6718f06 100644 --- a/src/libm/math/makefile +++ b/src/libm/math/makefile @@ -224,6 +224,9 @@ targetdep.texi: $(chobj) math.texi chew.exe: chew.c $(GCC) -O2 -o $@ $< +k_rem_pio2.o: EXTRA_CFLAGS += -Wno-maybe-uninitialized +kf_rem_pio2.o: EXTRA_CFLAGS += -Wno-maybe-uninitialized + clean :: -$(MISC) rm *.def *.d chew.exe targetdep.texi
Thank you! I was just about to do a ritual and sell my soul for the answer.
Offline