mirror of
https://github.com/gentoo-mirror/guru.git
synced 2026-07-19 03:53:22 -04:00
dev-lang/fbc: New package
Closes: https://bugs.gentoo.org/96711 Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com>
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
From 94764a6bf44ab9146e23fb0559ef99f35ceeec79 Mon Sep 17 00:00:00 2001
|
||||
From: William Breathitt Gray <vilhelm.gray@gmail.com>
|
||||
Date: Sat, 6 Apr 2019 11:20:10 +0900
|
||||
Subject: [PATCH] makefile: Fix bootstrap recipe race condition
|
||||
|
||||
Since fbrt0.o and libfb.a are statically linked to the bootstrap fbc,
|
||||
rtlib should be listed as a dependency of BOOTSTRAP_FBC. This patch
|
||||
fixes the race condition described in issue #131.
|
||||
---
|
||||
makefile | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/makefile b/makefile
|
||||
index aeca4c07e..0422dfff7 100644
|
||||
--- a/makefile
|
||||
+++ b/makefile
|
||||
@@ -1063,7 +1063,7 @@ bootstrap-dist:
|
||||
#
|
||||
BOOTSTRAP_FBC := bootstrap/fbc$(EXEEXT)
|
||||
.PHONY: bootstrap
|
||||
-bootstrap: rtlib gfxlib2 $(BOOTSTRAP_FBC)
|
||||
+bootstrap: gfxlib2 $(BOOTSTRAP_FBC)
|
||||
mkdir -p bin
|
||||
cp $(BOOTSTRAP_FBC) $(FBC_EXE)
|
||||
|
||||
@@ -1089,7 +1089,7 @@ endif
|
||||
ifneq ($(filter darwin freebsd linux netbsd openbsd solaris,$(TARGET_OS)),)
|
||||
BOOTSTRAP_LIBS := -lncurses -lm -pthread
|
||||
endif
|
||||
-$(BOOTSTRAP_FBC): $(BOOTSTRAP_OBJ)
|
||||
+$(BOOTSTRAP_FBC): rtlib $(BOOTSTRAP_OBJ)
|
||||
$(QUIET_LINK)$(CC) -o $@ $(libdir)/fbrt0.o bootstrap/$(FBTARGET)/*.o $(libdir)/libfb.a $(BOOTSTRAP_LIBS)
|
||||
|
||||
.PHONY: clean-bootstrap
|
||||
--
|
||||
2.21.0
|
||||
|
||||
@@ -0,0 +1,56 @@
|
||||
From dc6e5a3b68810d0e97625b57055bd98678e13a53 Mon Sep 17 00:00:00 2001
|
||||
From: William Breathitt Gray <vilhelm.gray@gmail.com>
|
||||
Date: Tue, 9 Apr 2019 18:51:38 +0900
|
||||
Subject: [PATCH] makefile: Implement bootstrap-minimal target
|
||||
|
||||
The bootstrap-minimal target builds a bootstrap fbc with only the
|
||||
minimal features necessary to build another fbc.
|
||||
---
|
||||
makefile | 16 ++++++++++++----
|
||||
1 file changed, 12 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/makefile b/makefile
|
||||
index 0422dfff7..245e95669 100644
|
||||
--- a/makefile
|
||||
+++ b/makefile
|
||||
@@ -64,8 +64,9 @@
|
||||
# warning-tests
|
||||
# clean-tests
|
||||
#
|
||||
-# bootstrap-dist Create source package with precompiled fbc sources
|
||||
-# bootstrap Build fbc from the precompiled sources (only if precompiled sources exist)
|
||||
+# bootstrap-dist Create source package with precompiled fbc sources
|
||||
+# bootstrap Build fbc from the precompiled sources (only if precompiled sources exist)
|
||||
+# bootstrap-minimal Build fbc from the precompiled sources (only if precompiled sources exist) with only the minimal features needed to compile another fbc
|
||||
#
|
||||
# makefile configuration:
|
||||
# FB[C|L]FLAGS to set -g -exx etc. for the compiler build and/or link
|
||||
@@ -368,6 +369,11 @@ ALLFBCFLAGS += -e -m fbc -w pedantic
|
||||
ALLFBLFLAGS += -e -m fbc -w pedantic
|
||||
ALLCFLAGS += -Wall -Wextra -Wno-unused-parameter -Werror-implicit-function-declaration
|
||||
|
||||
+ifneq ($(filter bootstrap-minimal, $(MAKECMDGOALS)),)
|
||||
+ # Disable features not needed to compile a minimal bootstrap fbc
|
||||
+ ALLCFLAGS += -DDISABLE_GPM -DDISABLE_FFI -DDISABLE_X11
|
||||
+endif
|
||||
+
|
||||
ifeq ($(TARGET_OS),xbox)
|
||||
ifeq ($(OPENXDK),)
|
||||
$(error Please set OPENXDK=<OpenXDK directory>)
|
||||
@@ -1061,9 +1067,11 @@ bootstrap-dist:
|
||||
# Build the fbc[.exe] binary from the precompiled sources in the bootstrap/
|
||||
# directory.
|
||||
#
|
||||
+.PHONY: bootstrap bootstrap-minimal
|
||||
+bootstrap: gfxlib2 bootstrap-minimal
|
||||
+
|
||||
BOOTSTRAP_FBC := bootstrap/fbc$(EXEEXT)
|
||||
-.PHONY: bootstrap
|
||||
-bootstrap: gfxlib2 $(BOOTSTRAP_FBC)
|
||||
+bootstrap-minimal: $(BOOTSTRAP_FBC)
|
||||
mkdir -p bin
|
||||
cp $(BOOTSTRAP_FBC) $(FBC_EXE)
|
||||
|
||||
--
|
||||
2.21.0
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,35 @@
|
||||
From d1e485d6f1beb39e3228f86c2448b2fac77d1e62 Mon Sep 17 00:00:00 2001
|
||||
From: William Breathitt Gray <vilhelm.gray@gmail.com>
|
||||
Date: Sun, 21 Apr 2019 19:10:48 +0900
|
||||
Subject: [PATCH] Pass down all options from all -Wa, -Wc, and -Wl flags
|
||||
|
||||
All options from all -Wa, -Wc, and -Wl flags are passed down to their
|
||||
respective programs. This fixes issue #137.
|
||||
---
|
||||
src/compiler/fbc.bas | 6 +++---
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/src/compiler/fbc.bas b/src/compiler/fbc.bas
|
||||
index 0f04217a1..f6fa3d9db 100644
|
||||
--- a/src/compiler/fbc.bas
|
||||
+++ b/src/compiler/fbc.bas
|
||||
@@ -1869,13 +1869,13 @@ private sub handleOpt(byval optid as integer, byref arg as string)
|
||||
end if
|
||||
|
||||
case OPT_WA
|
||||
- fbc.extopt.gas = " " + hReplace( arg, ",", " " ) + " "
|
||||
+ fbc.extopt.gas += " " + hReplace( arg, ",", " " ) + " "
|
||||
|
||||
case OPT_WC
|
||||
- fbc.extopt.gcc = " " + hReplace( arg, ",", " " ) + " "
|
||||
+ fbc.extopt.gcc += " " + hReplace( arg, ",", " " ) + " "
|
||||
|
||||
case OPT_WL
|
||||
- fbc.extopt.ld = " " + hReplace( arg, ",", " " ) + " "
|
||||
+ fbc.extopt.ld += " " + hReplace( arg, ",", " " ) + " "
|
||||
|
||||
case OPT_X
|
||||
fbc.outname = arg
|
||||
--
|
||||
2.21.0
|
||||
|
||||
Reference in New Issue
Block a user