Files
haikuports/dev-lang/nasm/patches/nasm-2.15.05.patchset

70 lines
2.6 KiB
Plaintext

From 8636b3a4a54d00d4a45d61bdaffb31dfd0283142 Mon Sep 17 00:00:00 2001
From: Leorize <leorize+oss@disroot.org>
Date: Thu, 23 Jan 2020 12:13:55 -0600
Subject: Makefile.in: use iquote for include paths
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
The -I flag used causes gcc to pick headers from NASM instead of system
headers for system includes. Since NASM have headers with names
overlapping with the ones in the C standard library (ie. float.h). This
breaks compilation on certain systems (ie. Haiku).
This commit swap out the -I flags for -iquote, to only prioritise NASM
include paths for quoted includes.
Signed-off-by: Hiếu Lê <leorize+oss@disroot.org>
diff --git a/Makefile.in b/Makefile.in
index 5725ed3..988779b 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -22,12 +22,12 @@ CC = @CC@
CFLAGS = @CFLAGS@
CPPFLAGS = @CPPFLAGS@
BUILD_CFLAGS = $(CPPFLAGS) $(CFLAGS) @DEFS@
-INTERNAL_CFLAGS = -I$(srcdir) -I$(objdir) \
- -I$(srcdir)/include -I$(objdir)/include \
- -I$(srcdir)/x86 -I$(objdir)/x86 \
- -I$(srcdir)/asm -I$(objdir)/asm \
- -I$(srcdir)/disasm -I$(objdir)/disasm \
- -I$(srcdir)/output -I$(objdir)/output
+INTERNAL_CFLAGS = -iquote$(srcdir) -iquote$(objdir) \
+ -iquote$(srcdir)/include -iquote$(objdir)/include \
+ -iquote$(srcdir)/x86 -iquote$(objdir)/x86 \
+ -iquote$(srcdir)/asm -iquote$(objdir)/asm \
+ -iquote$(srcdir)/disasm -iquote$(objdir)/disasm \
+ -iquote$(srcdir)/output -iquote$(objdir)/output
ALL_CFLAGS = $(BUILD_CFLAGS) $(INTERNAL_CFLAGS)
LDFLAGS = @LDFLAGS@
ALL_LDFLAGS = $(ALL_CFLAGS) $(LDFLAGS)
--
2.24.1
From c93f1e9590d46b5c644ec3e56e9857ad63b928f7 Mon Sep 17 00:00:00 2001
From: robxnano <89391914+robxnano@users.noreply.github.com>
Date: Sun, 24 Mar 2024 22:59:15 +0000
Subject: [PATCH] Add Haiku definition for path separators
---
nasmlib/path.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/nasmlib/path.c b/nasmlib/path.c
index d228ed1e..5d6a5f2a 100644
--- a/nasmlib/path.c
+++ b/nasmlib/path.c
@@ -53,7 +53,7 @@
# define curdir "."
#elif defined(unix) || defined(__unix) || defined(__unix__) || \
defined(__UNIX__) || defined(__Unix__) || \
- defined(__MACH__) || defined(__BEOS__)
+ defined(__MACH__) || defined(__BEOS__) || defined(__HAIKU__)
/* Unix and Unix-like operating systems and others using
* the equivalent syntax (slashes as only separators, no concept of volume)
*
--
2.44.0