summaryrefslogtreecommitdiffstats
path: root/share/mk/bsd.prog.mk
Commit message (Collapse)AuthorAgeFilesLines
* Emit the correct standard library dependency line for C++ programs. Indes2013-09-091-1/+1
| | | | | | | | the CLANG_IS_CC case, the default is now libc++. Only use libstdc++ if !CLANG_IS_CC or it was explicitly requested in CXXFLAGS. Submitted by: theraven Approved by: re (gjb)
* Create a private library directory (LIBPRIVATEDIR) for libraries whichdes2013-09-081-0/+4
| | | | | | | | | | | | | | we don't want to expose but which can't or shouldn't be static. To mark a library as private, define PRIVATELIB in its Makefile. It will be installed in LIBPRIVATEDIR, which is normally /usr/lib/private (or /usr/lib32/private for 32-bit libraries on 64-bit platforms). To indicate that a program or library depends on a private library, define USEPRIVATELIB in its Makefile. The correct version of LIBPRIVATEDIR will be added to its run-time library search path. Approved by: re (blanket)
* Add a new knob WITH_DEBUG_FILES to control the building of standaloneemaste2013-06-071-7/+57
| | | | | | | | | | | | | | | | debug files for userland programs and libraries. The "-g" debug flag is automatically applied when WITH_DEBUG_FILES is set. The debug files are now named ${prog}.debug and ${shlib}.debug for consistency with other systems and documentation. In addition they are installed under /usr/lib/debug, to simplify the process of installing them if needed after a crash. Users of bsd.{prog,lib}.mk outside of the base system place the standalone debug files in a .debug subdirectory. GDB automatically searches both of these directories for standalone debug files. Thanks to everyone who contributed changes, review, and testing during development.
* Always define and use PROGNAMEemaste2013-03-261-5/+1
| | | | | | This avoids having separate cases in the install rule for PROGNAME set and not set. This is a minor cleanup in advance of further support for standalone debug files.
* Make sure to set OBJS consistently in the cases where SRCS is and isn'tmarkj2013-03-261-1/+1
| | | | | | | | already defined. Setting it with "+=" makes it possible for other make scripts (e.g. bsd.dtrace.mk) to include additional object files in the linker arguments. Approved by: emaste (co-mentor)
* Remove support for installing 1aout section manpages.brooks2013-01-161-2/+1
|
* Explicitly specify that the beforelinking target depends on themarkj2012-12-311-0/+2
| | | | | | | | | | | | generated object files, ensuring that the beforelinking recipe won't be executed until compilation has finished. Also define SHLIB_NAME_FULL to denote ${SHLIB_NAME}.debug if DEBUG_FILES is set and ${SHLIB_NAME} otherwise, which helps avoid obfuscating the compilation and linking rules. Reviewed by: emaste Approved by: emaste (co-mentor)
* Minor refactoring prior to .symbols file changesemaste2012-12-141-8/+6
| | | | | | | | - Combine .if x and .if !x using .else - Separate out beforelinking dependency - Add comments to clarify .if nesting Sponsored by: ADARA Networks
* When using -stdlib=libc++, add the correct dependency to .depend indim2012-08-251-0/+4
| | | | | | | bsd.prog.mk. Submitted by: Yamaya Takashi <yamayan@kbh.biglobe.ne.jp> MFC after: 2 weeks
* - CTF knob is now implemented using common scheme: MK_CTF=yes/no isfjoe2011-11-301-3/+3
| | | | | | | defined based on WITH/WITHOUT_CTF settings, default is WITHOUT_CTF, NO_CTF overrides WITH_CTF (used by Makefile.inc1) - CTFCONVERT_CMD/NORMAL_CTFCONVERT are now defined to empty string if make(1) can handle empty commands
* - fix WITH_CTF when specified in /etc/src.conf [1]fjoe2011-11-291-8/+3
| | | | | | | | | | | | | - CTFCONVERT_CMD=... is a hack (should be defined to empty string instead): make(1) should be taught to ignore empty commands silently in compat mode (as it does in !compat mode, GNU make also silently ignores empty commands) and to skip printing empty commands in !compat mode - config(8) should generate ${NORMAL_CTFCONVERT} invocation without '@': this will allow to simplify kern.pre.mk even more and lessen the number of shell invocations during kernel build when CTF is turned off - WITH_CTF can now be converted to usual MK_CTF=yes/no infrastructure Pointy hat to: fjoe [1]
* Conditionalize ctfconvert/ctfmerge runs on make level (.if/.endif) insteadfjoe2011-11-291-6/+6
| | | | | | of executing a shell on every object or executable/library file. This shaves off more than 30,000 shell invocations during buildworld.
* Remove libobjc and other Objective-C related components, as these aredim2011-04-171-10/+0
| | | | | | extremely outdated, and not used by anything in the base system. Silence from: current@
* Fix typo in previous commit.rpaulo2010-09-101-1/+1
|
* Check the existence of a 'beforelinking' target and make the resultingrpaulo2010-09-101-1/+9
| | | | | | | program or library depend on that before doing the final linking. This will be needed by DTrace. Sponsored by: The FreeBSD Foundation
* Add missing escape characthers.rpaulo2010-07-301-1/+1
| | | | Pointed out by: b.f.
* Fix previous commit: I forgot to include parenthesis.rpaulo2010-07-301-4/+4
| | | | Submitted by: anonymous
* When building WITH_CTF=1, print the ctf executable that's going to berpaulo2010-07-291-2/+6
| | | | | | | run. This makes the 'ctfconvert' and 'ctfmerge' programs show up during a build when compiling a kernel, a library or a program. Sponsored by: The FreeBSD Foundation
* WITH_CTF can now be specified in src.conf (not recommended, therenetchild2010-04-021-6/+7
| | | | | | | | | | | | | | | | | | | | | | are some problems with static executables), make.conf (would also affect ports which do not use GNU make and do not override the compile targets) or in the kernel config (via "makeoptions WITH_CTF=yes"). Additional (related) changes: - propagate WITH_CTF to module builds - do not add -g to the linker flags, it's a noop there anyway (at least according to the man page of ld) - do not add -g to CFLAGS unconditionally we need to have a look if it is really needed (IMO not) or if there is a way to add it only when WITH_CTF is used Note: ctfconvert / ctfmerge lines will not appear in the build output, to protect the innocent (those which do not build with WITH_CTF would see the shell-test and may think WITH_CTF is used). Reviewed by: imp, jhb, scottl (earlier version) Discussed on: arch@
* Also add DEBUG_FLAGS to CXXFLAGS if defined.marcel2010-02-181-0/+1
|
* Add support for the Compact C Type (CTF) conversions throughout FreeBSD'sjb2008-05-221-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | system makefiles. Note that the CTF conversion defaults to off. We may choose to change this default later if DTrace proves popular and people are prepared to wear the compilation performance impact of compiling with debug symbols all the time. Setting NO_CTF in the make args or user environment turns off CTF conversion. Even if we choose to default CTF generation to on later, we still need NO_CTF so that the buildworld process can bootstrap the tools without needlessly generating CTF data for temporary tools. Setting WITH_CTF in the make args or user environment (and _NOT_ in /etc/make.conf) is the only way to enable CTF data conversion. Nore that this can't be implemented the same way that the WITH_ and WITHOUT_ stuff is implemented throughout the buildworld because the CTF conversion needs to work when building a simple object without a Makefile, using the default rules in sys.mk. Typing 'make test.o' with no makefile and just a source file test.c should work. Also, typing 'make WITH_CTF=1 test.o without a makefile and just a source file test.c should work and produce an object with a CTF elf section. Typing 'make WITH_CTF=1 CFLAGS=-g test.o' without a makefile and just a source file test.c should produce an object with both a CTF elf section and the debug elf sections. In the FreeBSD build where more .mk files are used than just sys.mk which is included my make by default, the use of DEBUG_FLAGS is the correct way to enable a debug build. The important thing to note here is that it is the DEBUG_FLAGS setting that prevents libraries and programs from being stripped on installation. So, for the addition of CTF data conversion, setting DEBUG_FLAGS to contain -g, without NO_CTF, will cause the ctfconvert and ctfmerge build programs to be executed also with the -g arg so that debug symbols are retained rather than being removed after the CTF data elf section has been added. Add DTrace libraries to the list of libnames.
* Fixed "make checkdpadd" (missing library dependencies).ru2007-10-011-1/+5
| | | | Approved by: re (kensmith)
* When building WITHOUT_ASSERT_DEBUG, we need to disable -Werror as its easyobrien2006-09-131-0/+1
| | | | to see "warning: unused variable `foo'".
* Add a knob for compiling the tree -DNDEBUG. This turns off all theimp2006-09-111-0/+4
| | | | | | | | asserts and makes binaries smaller. The binaries also become repeatable again. As it was, without this md5's of binaries built with different paths differed. # Where do I document this?
* Reimplementation of world/kernel build options. For details, see:ru2006-03-171-4/+4
| | | | | | | | http://lists.freebsd.org/pipermail/freebsd-current/2006-March/061725.html The src.conf(5) manpage is to follow in a few days. Brought to you by: imp, jhb, kris, phk, ru (all bugs are mine)
* Handle NO_INCS solely inside bsd.incs.mk.ru2006-02-031-2/+0
|
* Add the NO_INCS knob to bsd.prog.mk and bsd.lib.mk to not includeru2005-11-191-0/+2
| | | | | | | | | | bsd.incs.mk, and use it when installing 32-bit compat libraries on amd64. This causes it to *not* overwrite native headers with i386 versions, which was the case with <fenv.h> and <vgl.h>. PR: amd64/83806 Prodded by: bde MFC after: 1 week
* Make sure the only thing that follows .endif or .else is a comment.harti2005-04-111-2/+2
|
* Linkage with -lobjc requires -lpthread nowadays.jmallett2005-01-261-1/+1
|
* NOSHARED -> NO_SHAREDru2004-12-211-1/+1
|
* NOFSCHG -> NO_FSCHGru2004-12-211-1/+1
|
* Start the dreaded NOFOO -> NO_FOO conversion.ru2004-12-211-4/+4
| | | | OK'ed by: core
* If PORTNAME is set in a system Makefile then hook into the portspaul2004-12-201-0/+4
| | | | | mechanisms to allow a package to be created. This paves the way for packaging the main tree.
* Install precious programs with -S.ru2004-11-121-1/+4
|
* Introduce the PRECIOUSPROG knob in bsd.prog.mk, similarru2004-11-031-0/+4
| | | | | | | | to PRECIOUSLIB from bsd.lib.mk. The side effect of this is making installing the world under jail(8) possible by using another knob, NOFSCHG. Reviewed by: oliver
* Removed COPTS support from kmod.mk and kern.pre.mk.ru2004-08-131-0/+1
| | | | COPTS support in bsd.prog.mk is preserved but discouraged.
* Two changes to aid in cleaning up sys/boot/ makefiles:ru2004-02-091-3/+9
| | | | | | | - Don't put libc.a as a dependency if program is linked with -nostdlib. - Added INTERNALPROG (by analogy to INTERNALLIB) for programs which are built only for its side effect and shold not be installed.
* make(1) can now handle spaces surrounding parenthesis correctly.ru2004-02-051-1/+1
|
* Fixed bogus ${FOO:Mbar} tests where the actual intent is to checkru2004-01-271-1/+1
| | | | | if the result set is empty. While here, replaced non-bogus empty string comparisons with equivalent empty() checks.
* Whitespace diff reduction between bsd.prog.mk and bsd.lib.mk outputs.ru2003-08-311-2/+17
|
* Add ${CRUNCH_CFLAGS} support for adding compile options to crunchgordon2003-06-291-0/+1
| | | | | | | components. This is generally considered a non-optimal solution but it gets the job done for the /rescue case. Submitted by: Tim Kientzle <kientzle@acm.org>
* Remove some games/ cruft that is no longer of relevance.markm2003-05-031-4/+0
|
* Added the new variable CTAGS which, if set to "ctags", revertsru2002-10-171-14/+0
| | | | | | | | to creating the tags file using ctags(1). Defaults to "gtags". Made GTAGSFLAGS and HTAGSFLAGS overrideable, added CTAGSFLAGS. Folded bsd.prog.mk version of `tags' into bsd.dep.mk. PR: bin/42852
* Extend the lint handling a bit.markm2002-09-201-3/+3
| | | | | | | | | o Make it possible to prevent parts of the tree from being linted (say) during a 'make world' by setting NOLINT in a leaf Makefile. o Make "make lint" work (better) for executable programs. o Clean up (nuke!) a syntax damaged pipeline.
* Initiate deorbit burn for the i386-only a.out related support. Moves arepeter2002-09-171-7/+0
| | | | | | | | | | | | | | | under way to move the remnants of the a.out toolchain to ports. As the comment in src/Makefile said, this stuff is deprecated and one should not expect this to remain beyond 4.0-REL. It has already lasted WAY beyond that. Notable exceptions: gcc - I have not touched the a.out generation stuff there. ldd/ldconfig - still have some code to interface with a.out rtld. old as/ld/etc - I have not removed these yet, pending their move to ports. some includes - necessary for ldd/ldconfig for now. Tested on: i386 (extensively), alpha
* Drop support for COPY, -c has been the default mode of install(1)ru2002-07-291-3/+3
| | | | | | for a long time now. Approved by: bde
* Try really hard to fix parallel installs. Add a bunch of .ORDERru2002-07-031-0/+3
| | | | | | | | | | | | | | | | | | | | | directives to ensure that all realinstall sub-tasks are executed after beforeinstall, similarly ensure that all afterinstall sub- tasks are executed after realinstall. Demonstration: all: task1 task2 .ORDER: task1 task2 task2: task2_subtask .ORDER: task1 task2_subtask task1 task2 task2_subtask: @sleep `jot -r 1 0 1.0` @echo ${.TARGET} Without the second .ORDER directive, task2_subtask can be run in parallel with task1. Spotted by: Andrea Campi <andrea@webcom.it>
* Reimplemented bsd.nls.mk using bsd.files.mk and bsd.links.mk.ru2002-07-021-0/+3
| | | | | | | | | | | | Provided the (previously missing) dependency on source files for intermediate .msg files. Provided the default for NLSSRCDIR (defaults to .CURDIR). Slightly changed the API: NLS should now list plain locale names, without the .msg suffix. When included from bsd.prog.mk, NLSNAME defaults to PROG.
* Handle installation of hard and symbolic links via a seperate .mk file.ru2002-07-021-24/+1
|
* Reimplement FILES support using bsd.files.mk with theru2002-06-031-28/+2
| | | | | | | | same set of features as in recently added bsd.incs.mk (FILESGROUPS, accessibility from both bsd.prog.mk and bsd.lib.mk, de-pessimized typical installation path, etc.) New standard targets: buildfiles, installfiles, and files (buildfiles + installfiles).
OpenPOWER on IntegriCloud