diff options
| author | petede <none@none> | 2006-10-09 12:36:41 -0700 |
|---|---|---|
| committer | petede <none@none> | 2006-10-09 12:36:41 -0700 |
| commit | 5483666841c43709d99a540b2c151c9a38193799 (patch) | |
| tree | aef5856d650ef02e0b48fb64276047b8e65648d5 /usr | |
| parent | a2eea2e101e6a163a537dcc6d4e3c4da2a0ea5b2 (diff) | |
| download | illumos-joyent-5483666841c43709d99a540b2c151c9a38193799.tar.gz | |
6470487 ld relocation errors occur when building the amd64 kernel for nevada with mars build 30
Diffstat (limited to 'usr')
| -rw-r--r-- | usr/src/Makefile.master | 12 | ||||
| -rw-r--r-- | usr/src/tools/cw/cw.c | 13 |
2 files changed, 22 insertions, 3 deletions
diff --git a/usr/src/Makefile.master b/usr/src/Makefile.master index c846e7c87c..c76e5c357e 100644 --- a/usr/src/Makefile.master +++ b/usr/src/Makefile.master @@ -100,14 +100,19 @@ INTEL_BLD= $(INTEL_BLD_1:i386=) STRIP_COMMENTS= $(INTERNAL_RELEASE_BUILD) # set __GNUC= in the environment to build 32-bit with the gcc compiler. -# The default is to use the Sun Studio 10 compiler for all processor types. +# The default is to use the Sun Studio compiler for all processor types. __GNUC= $(POUND_SIGN) # set __GNUC64= in the environment to build 64-bit with the gcc compiler. -# The default is to use the Sun Studio 10 compiler by using the __GNUC -# setting. +# Inherit the __GNUC value by default, and if that is set to $(POUND_SIGN) +# then this means use the Sun Studio compiler. __GNUC64= $(__GNUC) +# set __SSNEXT= in the enviroment to build with the 'next' release of +# the Sun Studio compiler. This will cause command line options specific +# to the 'next' version of the Sun Studio compiler to be used. +__SSNEXT= $(POUND_SIGN) + # CLOSED is the root of the tree that contains source which isn't released # as open source CLOSED= $(SRC)/../closed @@ -328,6 +333,7 @@ sparc_STAND_FLAGS= -_gcc=-ffreestanding sparcv9_STAND_FLAGS= -_gcc=-ffreestanding i386_STAND_FLAGS= -_gcc=-ffreestanding amd64_STAND_FLAGS= -Wu,-xmodel=kernel +$(__SSNEXT)amd64_STAND_FLAGS= -xmodel=kernel SAVEARGS= -Wu,-save_args amd64_STAND_FLAGS += $(SAVEARGS) diff --git a/usr/src/tools/cw/cw.c b/usr/src/tools/cw/cw.c index 933ee9cf56..dcc5572924 100644 --- a/usr/src/tools/cw/cw.c +++ b/usr/src/tools/cw/cw.c @@ -225,6 +225,7 @@ * -Wl,<arg> pass-thru * -W{m,0,2,h,i,u> error/ignore * -Wu,-xmodel=kernel -ffreestanding -mcmodel=kernel -mno-red-zone + * -xmodel=kernel -ffreestanding -mcmodel=kernel -mno-red-zone * -Wu,-save_args -msave-args * -w pass-thru * -Xa -std=iso9899:199409 or -ansi @@ -1178,6 +1179,18 @@ do_gcc(cw_ictx_t *ctx) break; error(arg); break; +#if defined(__x86) + case 'm': + if (strcmp(arg, "-xmodel=kernel") == 0) { + newae(ctx->i_ae, "-ffreestanding"); + newae(ctx->i_ae, "-mno-red-zone"); + model = "-mcmodel=kernel"; + nolibc = 1; + break; + } + error(arg); + break; +#endif /* __x86 */ case 'M': if (strcmp(arg, "-xM") == 0) { newae(ctx->i_ae, "-M"); |
