Commit Graph

13 Commits

Author SHA1 Message Date
Warner Losh
917587f435 Rename libstand.a to libsa.a and libstand32.a to libsa32.a
Sponsored by: Netflix
2017-10-12 14:56:48 +00:00
Warner Losh
3006b7c8a9 Kill the userboot copy of libstand.
It's not needed (it's now identical to libsa, and seems to have been
for some time).

Sponsored by: Netflix
2017-10-12 14:56:42 +00:00
Enji Cooper
6cea2e6b1a Fix typos: stand alon{e,g} should be spelled like standalone 2017-10-10 04:53:26 +00:00
Warner Losh
b9b9a7c3a2 Rather than laying whack-a-mole with including the path to stand.h,
always include it. Remove places where we explicitly include it. This
also helps reduce the 'cut-and-paste' factor of these Makefiles.

Sponsored by: Netflix
2017-10-10 01:31:44 +00:00
Warner Losh
e1ff8b2f35 Create sys/boot/libsa and build libstand.a there
Build libstand from inside the sys/boot build. Redirect all users in
sys/boot to grab it from there. We still build it as libstand.a for
the moment. When lib/libstand is moved here, we'll change the name.

Sponsored by: Netflix
2017-10-09 22:12:53 +00:00
Warner Losh
8f409b435a Define LIBSA* and use them instead of overloaded LIBSTAND
LIBSA is the current stand alone library. LIBSA32 is the 32-bit
version of the library. LIBSAU is the userboot version of libsa. Use
the proper define instead of the more generic define.

Sponsored by: Netflix
2017-10-09 22:12:46 +00:00
Warner Losh
eca8b9c449 Define SASRC and use it
Define SASRC to point to the current libstand sources. Include
../Makefile.inc early enough in a few places so we can .include
"${SASRC}/Makefile" and have it work. Create a new pass-up
Makefile.inc in sys/boot/userboot to allow this pattern to work.

Sponsored by: Netflix
2017-10-09 22:12:32 +00:00
Wojciech Macek
76541eb0a7 Compile loader as Little-Endian on PPC64/POWER8
Add flag to the makefile to allow loader compilation as
  Little-Endian 32-bit executable.
  Usage:

  make WITH_LOADER_FORCE_LE=yes -C sys/boot all

Submitted by:          Wojciech Macek <wma@freebsd.org>
Reviewed by:           imp, nwhitehorn
Obtained from:         Semihalf
Sponsored by:          QCM Technologies
Differential revision: https://reviews.freebsd.org/D12421
2017-09-29 06:36:19 +00:00
Warner Losh
158c18ffb4 dd is currently a bootstrap tool. It really doesn't have any business
being a bootstrap tool. However, for reproducible build output,
FreeBSD added dd status=none because it was otherwise difficult to
suppress the status information, but retain any errors that might
happen. There's no real reason that dd has to be a build tool, other
than we use status=none unconditional. Remove dd from a bootstrap tool
entirely by only using status=none when available. This may also help
efforts to build the system on non-FreeBSD hosts as well.

Differential Revision: https://reviews.freebsd.org/D8605
2016-12-02 14:44:38 +00:00
Dimitry Andric
43a7fce37a Similar to r293384 and r293426, for sys/boot, also use the new -mno-movt
flag with clang >= 3.8.0 targeting arm.
2016-02-11 20:16:11 +00:00
Andrew Turner
214d450501 Stop clang from generating movt/movw sequences. These don't get relocated
so will access data from an unrelocated address. This is only needed for
self relocating code on ARMv7, however this is true for both ubldr and
loader.efi, the only two loaders we support on ARMv7.

While here also force the fpu to be none as is done in libstand.

Sponsored by:	ABT Systems Ltd
2016-02-09 00:15:41 +00:00
Ruslan Ermilov
d9ca85fca7 Fix build when WITH_SSP is set explicitly.
Submitted by:	Jeremie Le Hen
2009-02-21 15:04:31 +00:00
Ruslan Ermilov
042df2e2da Enable GCC stack protection (aka Propolice) for userland:
- It is opt-out for now so as to give it maximum testing, but it may be
  turned opt-in for stable branches depending on the consensus.  You
  can turn it off with WITHOUT_SSP.
- WITHOUT_SSP was previously used to disable the build of GNU libssp.
  It is harmless to steal the knob as SSP symbols have been provided
  by libc for a long time, GNU libssp should not have been much used.
- SSP is disabled in a few corners such as system bootstrap programs
  (sys/boot), process bootstrap code (rtld, csu) and SSP symbols themselves.
- It should be safe to use -fstack-protector-all to build world, however
  libc will be automatically downgraded to -fstack-protector because it
  breaks rtld otherwise.
- This option is unavailable on ia64.

Enable GCC stack protection (aka Propolice) for kernel:
- It is opt-out for now so as to give it maximum testing.
- Do not compile your kernel with -fstack-protector-all, it won't work.

Submitted by:	Jeremie Le Hen <jeremie@le-hen.org>
2008-06-25 21:33:28 +00:00