-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
bin/package, src/cmd/INIT/package.sh: - CCFLAGS overwrites the autodetected optimisation flags (e.g. -Os) if set. Unfortunately, that also happened when we added something to CCFLAGS for a release build or to add an extra flag needed by Solaris. The fix is to use a new flags variable (KSH_RELFLAGS) instead. This needs to be done in a different place as it needs to be added to the mamake command as an assignment argument. - Remove the Solaris CCFLAGS hack; see features/common below. src/*/*/Mamfile: - Add ${KSH_RELFLAGS} to all the compiler commands. src/lib/libast/features/common: - Enable POSIX standard on Solaris (i.e.: if __sun is defined) by defining _XPG6 directly in the feature test that generates ast_std.h, which is indirectly included by everything. This removes the need to pass -D_XPG6 via CCFLAGS. (Doing so automatically with gcc was not otherwise possible.) src/cmd/INIT/cc.sol11.*: - No longer pass -D_XPG6, as per above.
- Loading branch information
Showing
14 changed files
with
925 additions
and
922 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,6 +7,7 @@ setv AS as | |
setv ASFLAGS | ||
setv CC cc | ||
setv mam_cc_FLAGS | ||
setv KSH_RELFLAGS | ||
setv CCFLAGS ${-debug-symbols?1?${mam_cc_DEBUG} -D_BLD_DEBUG?${mam_cc_OPTIMIZE}?} | ||
setv CCLDFLAGS ${-strip-symbols?1?${mam_cc_LD_STRIP}??} | ||
setv COTEMP $$ | ||
|
@@ -532,19 +533,19 @@ done ast.h dontcare virtual | |
done mamake.c | ||
meta mamake.o %.c>%.o mamake.c mamake | ||
prev mamake.c | ||
exec - ${CC} ${mam_cc_FLAGS} ${CCFLAGS} -DUSAGE_LICENSE=\""[-author?Glenn Fowler <[email protected]>][-copyright?Copyright (c) 1994-2012 AT&T Intellectual Property][-license?http://www.eclipse.org/org/documents/epl-v10.html]"\" -c mamake.c | ||
exec - ${CC} ${mam_cc_FLAGS} ${KSH_RELFLAGS} ${CCFLAGS} -DUSAGE_LICENSE=\""[-author?Glenn Fowler <[email protected]>][-copyright?Copyright (c) 1994-2012 AT&T Intellectual Property][-license?http://www.eclipse.org/org/documents/epl-v10.html]"\" -c mamake.c | ||
done mamake.o generated | ||
exec - ${CC} ${CCLDFLAGS} ${mam_cc_FLAGS} ${CCFLAGS} ${LDFLAGS} -o mamake mamake.o | ||
exec - ${CC} ${CCLDFLAGS} ${mam_cc_FLAGS} ${KSH_RELFLAGS} ${CCFLAGS} ${LDFLAGS} -o mamake mamake.o | ||
done mamake generated | ||
make proto | ||
make proto.o | ||
make proto.c | ||
done proto.c | ||
meta proto.o %.c>%.o proto.c proto | ||
prev proto.c | ||
exec - ${CC} ${mam_cc_FLAGS} ${CCFLAGS} -c proto.c | ||
exec - ${CC} ${mam_cc_FLAGS} ${KSH_RELFLAGS} ${CCFLAGS} -c proto.c | ||
done proto.o generated | ||
exec - ${CC} ${CCLDFLAGS} ${mam_cc_FLAGS} ${CCFLAGS} ${LDFLAGS} -o proto proto.o | ||
exec - ${CC} ${CCLDFLAGS} ${mam_cc_FLAGS} ${KSH_RELFLAGS} ${CCFLAGS} ${LDFLAGS} -o proto proto.o | ||
done proto generated | ||
make ratz | ||
make ratz.o | ||
|
@@ -567,9 +568,9 @@ prev ast.h implicit | |
done ratz.c | ||
meta ratz.o %.c>%.o ratz.c ratz | ||
prev ratz.c | ||
exec - ${CC} ${mam_cc_FLAGS} ${CCFLAGS} -c ratz.c | ||
exec - ${CC} ${mam_cc_FLAGS} ${KSH_RELFLAGS} ${CCFLAGS} -c ratz.c | ||
done ratz.o generated | ||
exec - ${CC} ${CCLDFLAGS} ${mam_cc_FLAGS} ${CCFLAGS} ${LDFLAGS} -o ratz ratz.o | ||
exec - ${CC} ${CCLDFLAGS} ${mam_cc_FLAGS} ${KSH_RELFLAGS} ${CCFLAGS} ${LDFLAGS} -o ratz ratz.o | ||
done ratz generated | ||
make release | ||
make release.o | ||
|
@@ -578,9 +579,9 @@ prev ast.h implicit | |
done release.c | ||
meta release.o %.c>%.o release.c release | ||
prev release.c | ||
exec - ${CC} ${mam_cc_FLAGS} ${CCFLAGS} -DUSAGE_LICENSE=\""[-author?Glenn Fowler <[email protected]>][-copyright?Copyright (c) 1994-2012 AT&T Intellectual Property][-license?http://www.eclipse.org/org/documents/epl-v10.html]"\" -c release.c | ||
exec - ${CC} ${mam_cc_FLAGS} ${KSH_RELFLAGS} ${CCFLAGS} -DUSAGE_LICENSE=\""[-author?Glenn Fowler <[email protected]>][-copyright?Copyright (c) 1994-2012 AT&T Intellectual Property][-license?http://www.eclipse.org/org/documents/epl-v10.html]"\" -c release.c | ||
done release.o generated | ||
exec - ${CC} ${CCLDFLAGS} ${mam_cc_FLAGS} ${CCFLAGS} ${LDFLAGS} -o release release.o | ||
exec - ${CC} ${CCLDFLAGS} ${mam_cc_FLAGS} ${KSH_RELFLAGS} ${CCFLAGS} ${LDFLAGS} -o release release.o | ||
done release generated | ||
make mprobe | ||
make mprobe.sh | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,6 +12,7 @@ setv AS as | |
setv ASFLAGS | ||
setv CC cc | ||
setv mam_cc_FLAGS | ||
setv KSH_RELFLAGS | ||
setv CCFLAGS ${-debug-symbols?1?${mam_cc_DEBUG} -D_BLD_DEBUG?${mam_cc_OPTIMIZE}?} | ||
setv CCLDFLAGS ${-strip-symbols?1?${mam_cc_LD_STRIP}??} | ||
setv COTEMP $$ | ||
|
@@ -55,7 +56,7 @@ make FEATURE/pty implicit | |
meta FEATURE/pty features/%>FEATURE/% features/pty pty | ||
make features/pty | ||
done features/pty | ||
exec - iffe -v -c '${CC} ${mam_cc_FLAGS} ${CCFLAGS} ${LDFLAGS} ' ref ${mam_cc_L+-L${INSTALLROOT}/lib} -I${PACKAGE_ast_INCLUDE} -I${INSTALLROOT}/include ${mam_libast} ${mam_libcmd} : run features/pty | ||
exec - iffe -v -c '${CC} ${mam_cc_FLAGS} ${KSH_RELFLAGS} ${CCFLAGS} ${LDFLAGS} ' ref ${mam_cc_L+-L${INSTALLROOT}/lib} -I${PACKAGE_ast_INCLUDE} -I${INSTALLROOT}/include ${mam_libast} ${mam_libcmd} : run features/pty | ||
done FEATURE/pty generated | ||
make ${PACKAGE_ast_INCLUDE}/ast_time.h implicit | ||
done ${PACKAGE_ast_INCLUDE}/ast_time.h | ||
|
@@ -72,11 +73,11 @@ meta pty.o %.c>%.o pty.c pty | |
prev pty.c | ||
setv CMD_STANDALONE -DCMD_STANDALONE="b_pty" | ||
setv LICENSE -DLICENSE="since=2001,author=gsf+dgk" | ||
exec - ${CC} ${mam_cc_FLAGS} ${CCFLAGS} -I. -I${PACKAGE_ast_INCLUDE} -DERROR_CATALOG=\""builtin"\" -D_PACKAGE_ast -DCMD_STANDALONE=b_pty -DUSAGE_LICENSE=\""[-author?Glenn Fowler <[email protected]>][-author?David Korn <[email protected]>][-copyright?Copyright (c) 2001-2012 AT&T Intellectual Property][-license?http://www.eclipse.org/org/documents/epl-v10.html][--catalog?builtin]"\" -c pty.c | ||
exec - ${CC} ${mam_cc_FLAGS} ${KSH_RELFLAGS} ${CCFLAGS} -I. -I${PACKAGE_ast_INCLUDE} -DERROR_CATALOG=\""builtin"\" -D_PACKAGE_ast -DCMD_STANDALONE=b_pty -DUSAGE_LICENSE=\""[-author?Glenn Fowler <[email protected]>][-author?David Korn <[email protected]>][-copyright?Copyright (c) 2001-2012 AT&T Intellectual Property][-license?http://www.eclipse.org/org/documents/epl-v10.html][--catalog?builtin]"\" -c pty.c | ||
done pty.o generated | ||
bind -lutil dontcare | ||
setv CMD_STANDALONE -DCMD_STANDALONE="b_pty" | ||
exec - ${CC} ${CCLDFLAGS} ${mam_cc_FLAGS} ${CCFLAGS} ${LDFLAGS} ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} -o pty pty.o ${mam_libutil} ${mam_libast} ${mam_libcmd} | ||
exec - ${CC} ${CCLDFLAGS} ${mam_cc_FLAGS} ${KSH_RELFLAGS} ${CCFLAGS} ${LDFLAGS} ${mam_cc_L+-L.} ${mam_cc_L+-L${INSTALLROOT}/lib} -o pty pty.o ${mam_libutil} ${mam_libast} ${mam_libcmd} | ||
done pty generated | ||
make ${INSTALLROOT}/bin | ||
exec - if silent test ! -d ${INSTALLROOT}/bin | ||
|
Oops, something went wrong.