Compare commits

...

7 Commits

Author SHA1 Message Date
Maciej Bałuta
9e6821c209 jam: update version
Version string was not updated for 10 years, but there were some changes made.
This commit updates the date to avoid confusion.

Test plan:
~/buildtools/jam> jam -v
Jam 2.5-haiku-20211020. OS=HAIKU. Copyright 1993-2002 Christopher Seiwald.

Change-Id: Ieea0ed2a533396f664948f58798acee0f6c811e9
Reviewed-on: https://review.haiku-os.org/c/buildtools/+/4618
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2021-10-20 17:56:33 +00:00
Maciej Bałuta
72c791bc1f jam: update default paths in Jambase
Running "./jam0 install" installed jam in /boot/common/bin/ which
is no longer used. Other directories also looked outdated so they
are updated too.

Test plan:
1. make
2. ./jam0 install
   Install /boot/system/non-packaged/bin/jam
3. which jam
   /boot/system/non-packaged/bin/jam

Change-Id: I69c719eab0bd211f545c17337e3bc73bb1ab78fe
Reviewed-on: https://review.haiku-os.org/c/buildtools/+/4617
Reviewed-by: waddlesplash <waddlesplash@gmail.com>
2021-10-20 17:56:33 +00:00
Franck LeCodeur
4b7b6c63e8 jam: Remove ignored archiver flag modifier
The call of make in buildtools/jam produces the following output:

LINKLIBS= ./jam0
...patience...
...found 271 target(s)...
...updating 33 target(s)...
MkDir1 bin.linuxx86
Cc bin.linuxx86/builtins.o
< reduced output >
Cc bin.linuxx86/variable.o
Archive bin.linuxx86/libjam.a
ar: `u' modifier ignored since `D' is the default (see `U')
ar: creating bin.linuxx86/libjam.a
...

'make' bootstraps 'jam0' which calls 'ar' to create the static library 'libjam.a'.
The call looks like this:

ar ru bin.linuxx86/libjam.a bin.linuxx86/builtins.o <reduced output> bin.linuxx86/variable.o

The modifier 'u' gets ignored.

The underlying cause is that the build was done in deterministic mode ('D'), a.o. NOT using timestamps, which is completely fine.
But because of this the archiver tool (ar) can never update files in the archive based on timestamps.
"ru" means replace files (flag 'r') only if they are updated (flag suffix 'u') based on timestamps.
This patch removes the flag suffix 'u'.

Change-Id: I57fa2d50c2081ee66d1b71648714e773ecb7cd59
Reviewed-on: https://review.haiku-os.org/c/buildtools/+/4419
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
2021-09-13 06:10:36 +00:00
Fredrik Holmqvist
0ff4d6adaf gcc: Use initarray for ARM64 and RISC-v.
Change-Id: I6695707357f8dba467b09f700e7efe702102a42e
Reviewed-on: https://review.haiku-os.org/c/buildtools/+/4408
Reviewed-by: Jérôme Duval <jerome.duval@gmail.com>
2021-09-08 08:54:03 +00:00
Augustin Cavalier
139f4e7c6c jam: Pass -e to JAMSHELL.
Equivalent to hrev55387 in Haiku.
2021-09-06 16:11:04 -04:00
Alexander von Gluck IV
bc70af2399 binutils/ld: Fix arm target emulation typo
Change-Id: Ia8e6631b3aae04c302104826d1e98a33590ed440
2021-09-03 20:18:36 -05:00
Franck LeCodeur
c3d8487752 jam: Fix build warnings. Add missing include for POSIX compliant systems.
Warnings were:

Cc bin.linuxx86/fileunix.o
fileunix.c: In function ‘file_archscan’:
fileunix.c:217:6: warning: implicit declaration of function ‘read’; did you mean ‘fread’? [-Wimplicit-function-declaration]
  217 |  if( read( fd, buf, SARMAG ) != SARMAG ||
      |      ^~~~
      |      fread
fileunix.c:220:6: warning: implicit declaration of function ‘close’; did you mean ‘pclose’? [-Wimplicit-function-declaration]
  220 |      close( fd );
      |      ^~~~~
      |      pclose
fileunix.c:272:3: warning: implicit declaration of function ‘lseek’; did you mean ‘fseek’? [-Wimplicit-function-declaration]
  272 |   lseek(fd, offset + SARHDR, 0);
      |   ^~~~~
      |   fseek

Change-Id: Iedcdec01deb929d6c91ebc9d7eb72497fe078dd4
Reviewed-on: https://review.haiku-os.org/c/buildtools/+/4399
Reviewed-by: Adrien Destugues <pulkomandy@gmail.com>
2021-09-02 19:34:43 +00:00
6 changed files with 28 additions and 21 deletions

View File

@@ -203,7 +203,7 @@ arm*-*-conix*) targ_emul=armelf
arm*-*-fuchsia*) targ_emul=armelf_fuchsia
targ_extra_emuls="armelfb_fuchsia armelf armelfb"
;;
arm*-*-haiku*) arg_emul=armelf_haiku
arm*-*-haiku*) targ_emul=armelf_haiku
targ_extra_emuls=armelf
;;
avr-*-*) targ_emul=avr2

View File

@@ -994,6 +994,7 @@ aarch64*-*-freebsd*)
tmake_file="${tmake_file} aarch64/t-aarch64 aarch64/t-aarch64-freebsd"
;;
aarch64*-*-haiku*)
gcc_cv_initfini_array=yes
tm_file="${tm_file} dbxelf.h elfos.h haiku.h haiku-stdint.h"
tm_file="${tm_file} aarch64/aarch64-elf.h aarch64/aarch64-haiku.h"
tmake_file="${tmake_file} t-haiku aarch64/t-aarch64 aarch64/t-aarch64-haiku"
@@ -2104,6 +2105,7 @@ microblaze*-*-elf)
tmake_file="${tmake_file} microblaze/t-microblaze"
;;
riscv*-*-haiku*)
gcc_cv_initfini_array=yes
tm_file="elfos.h haiku.h ${tm_file} riscv/haiku.h haiku-stdint.h"
tmake_file="${tmake_file} t-haiku riscv/t-riscv riscv/t-haiku"
gnu_ld=yes

View File

@@ -135,7 +135,7 @@
# for perforce use -- jambase version
JAMBASEDATE = 2020.09.16 ;
JAMBASEDATE = 2021.10.20 ;
# Initialize variables
#
@@ -248,7 +248,7 @@ if $(NT) {
YACCFILES ?= y.tab ;
YACCFLAGS ?= -d ;
} else if $(OS) = HAIKU {
BINDIR ?= /boot/common/bin ;
BINDIR ?= /boot/system/non-packaged/bin ;
CC ?= gcc ;
C++ ?= $(CC) ;
CHMOD ?= chmod ;
@@ -256,11 +256,11 @@ if $(NT) {
CHOWN ?= chown ;
FORTRAN ?= "" ;
LEX ?= flex ;
LIBDIR ?= /boot/common/lib ;
LIBDIR ?= /boot/system/non-packaged/lib ;
LINK ?= gcc ;
MANDIR ?= /boot/common/man ;
MANDIR ?= /boot/system/non-packaged/documentation/man ;
RANLIB ?= ranlib ;
STDHDRS ?= /boot/develop/headers/posix ;
STDHDRS ?= /boot/system/develop/headers/posix ;
YACC ?= bison -y ;
YACCGEN ?= .c ;
YACCFILES ?= y.tab ;
@@ -272,7 +272,7 @@ if $(NT) {
CC ?= gcc ;
CCFLAGS += -D__cygwin__ ;
LEX ?= flex ;
JAMSHELL ?= sh -c ;
JAMSHELL ?= sh -e -c ;
RANLIB ?= "" ;
SUFEXE ?= .exe ;
YACC ?= bison -y ;
@@ -316,7 +316,7 @@ if $(NT) {
#
AR ?= ar ;
ARFLAGS ?= ru ;
ARFLAGS ?= r ;
AS ?= as ;
ASFLAGS ?= ;
AWK ?= awk ;

View File

@@ -58,7 +58,7 @@
# define STRUCT_DIRENT struct dirent
# endif
# ifdef __CYGWIN__
# if defined(__CYGWIN__) || defined(unix)
# include <unistd.h>
# endif

View File

@@ -1,7 +1,7 @@
/* Generated by mkjambase from Jambase */
const char *jambase[] = {
/* Jambase */
"JAMBASEDATE = 2018.11.21 ;\n",
"JAMBASEDATE = 2021.10.20 ;\n",
"if $(NT) {\n",
"MV ?= move /y ;\n",
"CP ?= copy ;\n",
@@ -12,7 +12,8 @@ const char *jambase[] = {
"SUFOBJ ?= .obj ;\n",
"SUFEXE ?= .exe ;\n",
"if $(MSVC) {\n",
"AR ?= lib /nologo ;\n",
"AR ?= lib ;\n",
"ARFLAGS ?= /nologo ;\n",
"CC ?= cl /nologo ;\n",
"CCFLAGS ?= /D \\\"WIN\\\" ;\n",
"C++ ?= $(CC) ;\n",
@@ -31,6 +32,7 @@ const char *jambase[] = {
"MSVCNT ?= $(MSVCDIR) ;\n",
"local I ; if $(OSPLAT) = IA64 { I = ia64\\\\ ; } else { I = \"\" ; }\n",
"AR ?= lib ;\n",
"ARFLAGS ?= ;\n",
"AS ?= masm386 ;\n",
"CC ?= cl /nologo ;\n",
"CCFLAGS ?= \"\" ;\n",
@@ -56,7 +58,8 @@ const char *jambase[] = {
"RANLIB ?= \"ranlib\" ;\n",
"SUFEXE ?= .exe ;\n",
"} else if $(OS) = BEOS && $(OSPLAT) = PPC {\n",
"AR ?= mwld -xml -o ;\n",
"AR ?= mwld ;\n",
"ARFLAGS ?= -xml -o ;\n",
"BINDIR ?= /boot/home/config/bin ;\n",
"CC ?= mwcc ;\n",
"CCFLAGS ?= -nosyspath ;\n",
@@ -96,7 +99,7 @@ const char *jambase[] = {
"YACCFILES ?= y.tab ;\n",
"YACCFLAGS ?= -d ;\n",
"} else if $(OS) = HAIKU {\n",
"BINDIR ?= /boot/common/bin ;\n",
"BINDIR ?= /boot/system/non-packaged/bin ;\n",
"CC ?= gcc ;\n",
"C++ ?= $(CC) ;\n",
"CHMOD ?= chmod ;\n",
@@ -104,11 +107,11 @@ const char *jambase[] = {
"CHOWN ?= chown ;\n",
"FORTRAN ?= \"\" ;\n",
"LEX ?= flex ;\n",
"LIBDIR ?= /boot/common/lib ;\n",
"LIBDIR ?= /boot/system/non-packaged/lib ;\n",
"LINK ?= gcc ;\n",
"MANDIR ?= /boot/common/man ;\n",
"MANDIR ?= /boot/system/non-packaged/documentation/man ;\n",
"RANLIB ?= ranlib ;\n",
"STDHDRS ?= /boot/develop/headers/posix ;\n",
"STDHDRS ?= /boot/system/develop/headers/posix ;\n",
"YACC ?= bison -y ;\n",
"YACCGEN ?= .c ;\n",
"YACCFILES ?= y.tab ;\n",
@@ -120,7 +123,7 @@ const char *jambase[] = {
"CC ?= gcc ;\n",
"CCFLAGS += -D__cygwin__ ;\n",
"LEX ?= flex ;\n",
"JAMSHELL ?= sh -c ;\n",
"JAMSHELL ?= sh -e -c ;\n",
"RANLIB ?= \"\" ;\n",
"SUFEXE ?= .exe ;\n",
"YACC ?= bison -y ;\n",
@@ -129,6 +132,7 @@ const char *jambase[] = {
"MANDIR ?= /usr/local/share/man ;\n",
"case QNX :\n",
"AR ?= wlib ;\n",
"ARFLAGS ?= ;\n",
"CC ?= cc ;\n",
"CCFLAGS ?= -Q ; # quiet\n",
"C++ ?= $(CC) ;\n",
@@ -152,7 +156,8 @@ const char *jambase[] = {
"YACCFILES ?= y.tab ;\n",
"YACCFLAGS ?= -d ;\n",
"}\n",
"AR ?= ar ru ;\n",
"AR ?= ar ;\n",
"ARFLAGS ?= r ;\n",
"AS ?= as ;\n",
"ASFLAGS ?= ;\n",
"AWK ?= awk ;\n",
@@ -749,7 +754,7 @@ const char *jambase[] = {
"}\n",
"actions updated together piecemeal Archive\n",
"{\n",
"$(AR) $(<) $(>)\n",
"$(AR) $(ARFLAGS) $(<) $(>)\n",
"}\n",
"actions As\n",
"{\n",

View File

@@ -1,5 +1,5 @@
/* Keep JAMVERSYM in sync with VERSION. */
/* It can be accessed as $(JAMVERSION) in the Jamfile. */
#define VERSION "2.5-haiku-20111222"
#define JAMVERSYM "JAMVERSION=2.5-haiku-20111222"
#define VERSION "2.5-haiku-20211020"
#define JAMVERSYM "JAMVERSION=2.5-haiku-20211020"