Felix Fietkau
b737686b2c
build: use -iremap feature to replace __FILE__ absolute path names in packages with ones relative to $(BUILD_DIR)
...
improves reproducible builds
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 48489
2016-01-25 15:49:31 +00:00
Felix Fietkau
b1986d8fd6
build: use directory name instead of PKG_NAME for staging files and package metadata
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 48110
2016-01-04 01:33:32 +00:00
Steven Barth
fc5f02410f
buildroot: move hardening options into separate file
...
Signed-off-by: Steven Barth <steven@midlink.org>
SVN-Revision: 46070
2015-06-20 17:37:18 +00:00
Steven Barth
ca96d1ab3f
package.mk: replicate SSP and relro in both CFLAGS and LDFLAGS
...
Signed-off-by: Steven Barth <steven@midlink.org>
SVN-Revision: 46035
2015-06-18 10:48:28 +00:00
Jo-Philipp Wich
a621b8c284
include: clean package staging dir files before configure
...
This is required to allow packages to ship libraries with a different API.
Previously the linker would favor the old shared libraries in STAGING_DIR
instead of the just compiled ones in PKG_BUILD_DIR.
Avoid that problem by clearing the package staging files right after
prepare.
Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>
SVN-Revision: 45759
2015-05-26 09:17:13 +00:00
Felix Fietkau
d42be88915
build: include variant name in STAMP_INSTALLED
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 45253
2015-04-03 18:33:25 +00:00
Luka Perkov
7002f6326e
include: remove trailing whitespaces
...
Signed-off-by: Luka Perkov <luka@openwrt.org>
SVN-Revision: 45127
2015-03-29 07:29:18 +00:00
Felix Fietkau
74ca7e9af3
build: clean up sitefiles, make them per-arch
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 45090
2015-03-28 13:38:34 +00:00
John Crispin
08ae6296ca
build: define STAMP_CONFIGURED recursively
...
Defining STAMP_CONFIGURED statically caused it not to reflect changes to
PKG_CONFIG_DEPENDS made after including package.mk, like the additional options
added by feeds.mk for all packages.
Furthermore, as STAMP_CONFIGURED_WILDCARD was already defined recursively, the
patsubst in its definition would never match, and in consequence, the stamps
were never removed. This caused packages not to be rebuilt when they should have
been.
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
SVN-Revision: 44927
2015-03-21 21:47:53 +00:00
Felix Fietkau
e9e6e75c2a
build: explicitly unexport CONFIG_SITE
...
On systems with CONFIG_SITE in the environment (e.g. OpenSUSE) make will export
the CONFIG_SITE set in include/package.mk by default. This will cause host
builds to get the target site configuration, leading to all kinds of weirdness
(wrong pointer size, wrong endianess).
Fix this by explicitly unexporting CONFIG_SITE. The explicit export for the
target builds overrides the unexport, so the target builds will still correctly
get the site config.
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
SVN-Revision: 44019
2015-01-18 00:37:18 +00:00
John Crispin
491f3fc048
Support for building an hardened OpenWRT
...
Introduce configuration options to build an "hardened" OpenWRT.
Options to enable Stack-Smashing Protection, FORTIFY_SOURCE and RELRO
have been introduced.
uClibc makefile now automatically detects if SSP support is necessary.
hostapd makefile has been fixed to use "^" as sed separator since
using a comma was problematic when using "-Wl,-z,now" and the like in
TARGET_CFLAGS.
Currently enabling SSP on user space depends on enabling SSP kernel
side, this is due to the fact that TARGET_CFLAGS are used to build
kernel modules (at least). Suggestions on how to avoid this are welcome.
Using "select" instead of "depends on" doesn't seem to work with choice
entries.
Tested with a lantiq (WBMR) router, GCC 4.8, uClibc and a subset of
the available packages.
Needs to be tested with GCC 4.9 and the remaining packages.
PIE not currently included.
Signed-off-by: Alessandro Di Federico <ale+owrt@clearmind.me>
SVN-Revision: 44005
2015-01-17 14:31:30 +00:00
Felix Fietkau
d081edf7eb
build: clean up and optimize ipkg control generator code
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 43017
2014-10-22 08:57:16 +00:00
John Crispin
7a1f4c50fa
PKG_CHECK_FORMAT_SECURITY: add a menuconfig option, disable by default
...
The idea is still to enable it by default at some point
I've tested all ar71xx packages (except oldpackages) using CONFIG_ALL=y
Failing packages have been marked with PKG_CHECK_FORMAT_SECURITY:=0 for now
I can test more targets but i have no idea which are the most used
Signed-off-by: Etienne CHAMPETIER <champetier.etienne@gmail.com>
SVN-Revision: 42282
2014-08-25 06:36:06 +00:00
Felix Fietkau
5249fc8491
build: temporarily disable PKG_CHECK_FORMAT_SECURITY until after the release
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 41504
2014-07-04 06:23:57 +00:00
Felix Fietkau
ff9595dbcf
build: Introduce PKG_CHECK_FORMAT_SECURITY
...
The idea is to get rid of
http://en.wikipedia.org/wiki/Uncontrolled_format_string
by using "-Wformat -Werror=format-security" by default
Signed-off-by: Etienne CHAMPETIER <etienne.champetier@free.fr>
SVN-Revision: 41412
2014-06-30 08:19:52 +00:00
Felix Fietkau
79f1326d73
build: reimplement package build directory override
...
Remove leftover pieces from package-version-override.mk support
Add a new variable USE_SOURCE_DIR to use a custom build directory.
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 40527
2014-04-18 14:58:01 +00:00
Felix Fietkau
c2a3791000
build: add alternative PKG_CONFIG_PATH
...
This is a cryptographically signed message in MIME format.
udev Makefile.am has two different .pc files and put them
into two locations. Don't know if changing the udev Makefile
or changing the pkgconfig paths is the right way - someone
has to decide :)
udev and vala use an additional pkg-config dir
add it to the path
discovered because openobex did not find udev.pc
Signed-off-by: Dirk Neukirchen <dirkneukirchen@web.de>
SVN-Revision: 39792
2014-03-07 18:18:56 +00:00
Felix Fietkau
623825103e
build: allow packages to declare ABI versions to detect necessary package rebuilds
...
If a package directly depends on another package that recently changed
its ABI version, it will be cleaned up and rebuilt (assuming quilt is
not used).
This helps with packages that have no stable ABI, e.g. libubox, ubus,
etc.
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 39720
2014-02-23 17:32:04 +00:00
Felix Fietkau
a5ce3f2cbf
build: fix typo in mips16 changes
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 37776
2013-08-14 14:55:49 +00:00
Felix Fietkau
a1a5f59ea3
build: decouple the mips16 support flag from the toolchain
...
Add the flags from package.mk instead, and leave libc and gcc
unaffected.
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 37770
2013-08-14 13:02:29 +00:00
Felix Fietkau
6f4cb088a0
build: clean up stale files from a previous build when installing a package build to the staging dir
...
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
SVN-Revision: 36755
2013-05-29 10:31:45 +00:00
Felix Fietkau
de707ac97e
build: reduce the size of package metadata a bit to keep package list files smaller
...
SVN-Revision: 34871
2012-12-22 19:56:21 +00:00
Jo-Philipp Wich
d3e90ba7a7
buildroot: isolate the .install stamp files for build variants ( #12279 )
...
This fixes missing embedded packages if multiple build variants are selected in
the build config, e.g. missing ppp if CONFIG_PACKAGE_ppp=y and
CONFIG_PACKAGE_ppp-multilink=m .
SVN-Revision: 34106
2012-11-07 16:15:22 +00:00
Felix Fietkau
6f752c725a
build: create pkginfo dir earlier to avoid build breakage
...
SVN-Revision: 33633
2012-10-06 22:42:57 +00:00
Felix Fietkau
44cd20b802
build: rework the package/install step - collect package install lists during package/compile, then install all packages at once
...
SVN-Revision: 33631
2012-10-06 16:01:06 +00:00
Felix Fietkau
b086475e1e
build: ensure that package/host-build build system code does not run in parallel, fixes rare spurious parallel build failures
...
SVN-Revision: 33445
2012-09-17 11:17:26 +00:00
Felix Fietkau
c4198ce48d
build: move the -j flag to package.mk instead of grabbing it from makeflags, otherwise it occasionally gets omitted on full builds
...
SVN-Revision: 33422
2012-09-15 12:16:14 +00:00
Felix Fietkau
be6f437649
build: add a config option for passing the top-level make jobserver to packages that have parallel build enabled, significantly improves parallelization and gets rid of CPU overcommit during intra-package parallel builds
...
SVN-Revision: 33414
2012-09-15 10:21:24 +00:00
John Crispin
584bc13d38
use autoreconf hook instead of manual call
...
SVN-Revision: 32837
2012-07-25 10:34:06 +00:00
Felix Fietkau
cf788fc731
build: add a config option for choosing the prefered standard c++ library and add uclibc++.mk to make this easy to handle in packages
...
SVN-Revision: 32369
2012-06-14 20:26:04 +00:00
Felix Fietkau
3051de8701
build: add a variable for injecting config variable dependencies for the .prepared stamp
...
SVN-Revision: 32368
2012-06-14 20:26:00 +00:00
Felix Fietkau
16a34b222a
package.mk: unexport the QUIET variable, it affects some packages like xapian-bindings
...
SVN-Revision: 32196
2012-06-11 15:07:51 +00:00
Felix Fietkau
031990cf95
build: generate a list of provided libraries for each ipkg file (includes provided libraries from packages that the exporting package depends on)
...
SVN-Revision: 32172
2012-06-10 20:27:41 +00:00
Felix Fietkau
edb862e8ec
build: improve reliability of PKG_CONFIG_DEPENDS, remove old .configured_* stamps before creating a new one
...
SVN-Revision: 28770
2011-11-05 19:09:40 +00:00
Felix Fietkau
f63daa85a2
fix a small logic error in package download
...
SVN-Revision: 28395
2011-10-09 16:54:03 +00:00
Felix Fietkau
874622d004
build system: add a feature that allows you to pull sources from a git tree instead of the usual tarball
...
SVN-Revision: 28394
2011-10-09 16:33:59 +00:00
Felix Fietkau
1b8dd6ed1c
build system: add support for download-time make hooks
...
SVN-Revision: 28322
2011-09-30 11:12:13 +00:00
Felix Fietkau
b568a64f8c
add support for md5sum checks for mirrored tarballs of packages with version control source urls
...
SVN-Revision: 26260
2011-03-21 23:02:06 +00:00
Felix Fietkau
73c1dd9473
build: move the CCACHE_DIR to the build targets so that it doesn't interfere with a host ccache setup
...
SVN-Revision: 26181
2011-03-15 19:58:32 +00:00
Felix Fietkau
de4fdd0ce6
add a stamp that can forcibly disable autorebuild for a specific package - useful for testing changes to packages with extremely long recompilation times
...
SVN-Revision: 25838
2011-03-03 00:17:08 +00:00
Felix Fietkau
7e4a29fbe2
use := instead of = for PKG_CONFIG_PATH to prevent recursion
...
SVN-Revision: 25388
2011-02-06 16:04:33 +00:00
Felix Fietkau
e8b193f10b
allow packages to override/extend PKG_CONFIG_PATH
...
SVN-Revision: 25386
2011-02-06 15:18:30 +00:00
Jo-Philipp Wich
dbf8d9c516
- implement hooks for hostbuilds - use host build hooks to implement fixups for host build - move separator declaration to rules.mk
...
SVN-Revision: 24551
2010-12-13 19:04:33 +00:00
Michael Büsch
995cedb319
InstallDev: Move the "find" out of the lock critical section.
...
SVN-Revision: 23858
2010-11-04 12:42:37 +00:00
Michael Büsch
e5fc77edd9
Lock copying of directory trees to the staging dir with the "staging-dir" lock. This lock probably has to be taken elsewhere, too.
...
SVN-Revision: 23857
2010-11-04 12:28:55 +00:00
Michael Büsch
dc7a68165d
Fix typo
...
SVN-Revision: 23482
2010-10-16 18:46:22 +00:00
Michael Büsch
d4807cf557
Support force-disabling per-package parallel build with {PKG,HOST}_BUILD_PARALLEL:=0
...
SVN-Revision: 23480
2010-10-16 18:42:58 +00:00
Michael Büsch
fde498904f
Add an option to default the default build rule to parallel build.
...
SVN-Revision: 22737
2010-08-20 14:48:59 +00:00
Michael Büsch
7ed7784f59
Support parallel build of certain packages
...
SVN-Revision: 22696
2010-08-18 13:57:58 +00:00
Lars-Peter Clausen
b4a1337cf9
Add build variants support to InstallDev
...
Before building a build variant would have removed the staging files installed
by the previous build variant from the same makefile.
SVN-Revision: 22668
2010-08-16 09:45:21 +00:00
Felix Fietkau
6117c04c94
remove linux 2.4 specific build system code
...
SVN-Revision: 21951
2010-06-26 20:42:38 +00:00
Felix Fietkau
15fecc9e6c
remove support for DEBUG_DIR, it has lost its purpose since STAGING_DIR_ROOT was added
...
SVN-Revision: 19849
2010-02-24 23:43:05 +00:00
Felix Fietkau
79fcadc146
hostapd: fix rebuild checks ( #6210 )
...
SVN-Revision: 18497
2009-11-23 17:12:54 +00:00
Felix Fietkau
94cdcbde6d
add experimental support for a new menuconfig submenu "Package features". allows selection between multiple packages providing the same feature, which affects dependencies of other packages. will be used e.g. for choosing between DirectFB and X.org for libraries like GTK2
...
SVN-Revision: 18056
2009-10-17 22:11:21 +00:00
Felix Fietkau
5af113eb7c
add support for build system overlays that alter package build instructions currently unused, will probably be managed by the feeds system later
...
SVN-Revision: 17445
2009-08-31 01:11:25 +00:00
Ralph Hempel
6f29703625
add dist and distcheck target (to create new source balls)
...
SVN-Revision: 16230
2009-05-31 12:01:05 +00:00
Ralph Hempel
3dc92527a3
add package source path override - use external source tree instead of source ball - the external package source tree will be included as symlink - make package/<name>/clean will delete the symlink instead of whole source tree - usefull in conjunction with external SCM like ClearCase - package-version-override.mk has to be included before package.mk
...
SVN-Revision: 16227
2009-05-31 11:35:13 +00:00
Nicolas Thill
f0a3d4d501
add missing bits from [15451]
...
SVN-Revision: 15453
2009-04-27 16:02:21 +00:00
Nicolas Thill
7658ef1316
introduce a generic PKG_CONFIG_DEPENDS for packages that need to be reconfigured when certain CONFIG options changed, rename PKG_BUILD_DEPEND to PKG_BUILD_DEPENDS
...
SVN-Revision: 15451
2009-04-27 15:53:00 +00:00
Felix Fietkau
63129f9b4c
clean up automake/pkg-config handling, move separate host/package variable exports to templates, fix automake path for host builds
...
SVN-Revision: 15339
2009-04-22 22:05:55 +00:00
Felix Fietkau
729e0fa4d1
move pkg config stuff to per-target exports to prevent interference with host builds
...
SVN-Revision: 15299
2009-04-20 18:56:57 +00:00
Felix Fietkau
34939cad39
get rid of $Id$ - it has never helped us and it has broken too many patches ;)
...
SVN-Revision: 15242
2009-04-17 14:09:46 +00:00
Felix Fietkau
7ec4ad271e
add PKG_HOST_ONLY variable to prevent target builds
...
SVN-Revision: 14906
2009-03-17 02:37:04 +00:00
Felix Fietkau
ddcfaeb1e5
move host build in packages into a separate namespace: package/<name>/host/<target> this allows dependencies between host and target packages, and saves unnecessary host builds for packages that contain both variants
...
SVN-Revision: 14905
2009-03-17 02:20:34 +00:00
Felix Fietkau
e4a5d86b54
fix the target-local CONFIG_SITE export. apparently make can't do more than one of them in a single line
...
SVN-Revision: 14863
2009-03-13 16:16:54 +00:00
Felix Fietkau
76683dc7b2
move the CONFIG_SITE export to target-local exports
...
SVN-Revision: 14851
2009-03-12 13:57:56 +00:00
Felix Fietkau
b6f0cb5366
prepend $(STAGING_DIR)/host to the PATH only in target-package stampfile targets, should fix usage of cross tools with host builds
...
SVN-Revision: 14800
2009-03-09 01:15:59 +00:00
Felix Fietkau
fb4a318970
fix the host vs native stampfile dependencies to improve quilt support
...
SVN-Revision: 14629
2009-02-22 23:54:05 +00:00
Felix Fietkau
aa0778f77e
allow concurrent use of host-build.mk and package.mk as well as their templates
...
SVN-Revision: 14621
2009-02-22 18:10:05 +00:00
Felix Fietkau
6ccc1c8e3c
fix typo
...
SVN-Revision: 14609
2009-02-22 04:36:56 +00:00
Felix Fietkau
eb1c4db039
add support for an optional staging directory for debug binaries
...
SVN-Revision: 14018
2009-01-13 03:21:25 +00:00
Nicolas Thill
a3edea1b91
add support for alternative C libraries (currently only glibc/eglibc) other (related) changes: - kernel headers are now installed using "make headers_install" on 2.6 - target names now contain an openwrt "vendor" tag (e.g. mips-openwrt-linux-gnu) - build directory names now contain gcc/libc name/version - default cpu for x86 is now i486 (required to build glibc/eglibc)
...
SVN-Revision: 13931
2009-01-08 01:49:11 +00:00
Felix Fietkau
cb73e4ad91
fix inotify detection for linux 2.4 (fixes glib2 and packages that depend on it on brcm-2.4)
...
SVN-Revision: 12896
2008-10-08 12:07:14 +00:00
Lars-Peter Clausen
3601e8b9bb
oops, previous commit was broken. remove wrong line break.
...
SVN-Revision: 12570
2008-09-11 16:17:28 +00:00
Lars-Peter Clausen
013d074603
Add InstallDev/(Pre|Post) hooks.
...
SVN-Revision: 12569
2008-09-11 16:13:14 +00:00
Felix Fietkau
3b937f85e8
add default Build/Install template, which is activated by setting PKG_INSTALL=1
...
SVN-Revision: 12512
2008-09-03 13:19:50 +00:00
Felix Fietkau
5719247ae3
add an extra build step Build/Install which allows you to run a make install target after the post-compile hooks have run - will be necessary for some libtool dependent stuff
...
SVN-Revision: 12452
2008-09-01 11:03:58 +00:00
Felix Fietkau
291e775fcd
allow packages to forcibly disable the svn/git mirror downloading attempt by setting PKG_SOURCE_MIRROR:=0 ( #3815 )
...
SVN-Revision: 12034
2008-07-31 02:43:33 +00:00
Felix Fietkau
4c665e6ca4
large improvement for parallel builds. works without V=99 now and without warnings. tested with -j on an 2x dual core opteron machine
...
SVN-Revision: 11414
2008-06-09 15:38:45 +00:00
Felix Fietkau
82572cf767
revert ARM to oabi by default, add some eabi patches for fixing up the toolchain, which unfortunately break eabi userland, but are IMHO a necessary basis for further eabi fixes
...
SVN-Revision: 10458
2008-02-14 14:31:31 +00:00
Felix Fietkau
f75b9f6815
fix packages that use -f on other build system makefiles
...
SVN-Revision: 10088
2008-01-03 02:12:46 +00:00
Andy Boyett
6343c3be59
expunge find GNUism
...
SVN-Revision: 9955
2007-12-27 11:31:27 +00:00
Felix Fietkau
5c2991d8bc
add improved autotools fixups
...
SVN-Revision: 9942
2007-12-27 02:11:07 +00:00
Felix Fietkau
28922775b6
add $(STAGING_DIR)/host, which contains target specific, but host executable files
...
SVN-Revision: 9939
2007-12-27 02:10:54 +00:00
Felix Fietkau
3de5e1d29a
clean up after staging packages
...
SVN-Revision: 9909
2007-12-25 02:19:48 +00:00
Felix Fietkau
957103c337
add automatic file tracking and uninstallation for files installed in $(STAGING_DIR) and $(STAGING_DIR_HOST)
...
SVN-Revision: 9905
2007-12-25 01:39:15 +00:00
Felix Fietkau
3c228ee88f
add a second parameter to InstallDev/UninstallDev for specifying the path to STAGING_DIR_HOST
...
SVN-Revision: 9853
2007-12-23 00:41:40 +00:00
John Crispin
a49f06f5e7
fixed copy paste error
...
SVN-Revision: 9792
2007-12-17 22:24:40 +00:00
Felix Fietkau
407b75436d
fix build issues that happen when the staging dir is cleared and the build directories stay
...
SVN-Revision: 9588
2007-11-20 22:43:38 +00:00
Felix Fietkau
87d0b29540
better scope handling for the configured stamp
...
SVN-Revision: 9566
2007-11-16 03:48:43 +00:00
Felix Fietkau
e66a211078
fix default downloads from svn
...
SVN-Revision: 9471
2007-10-31 22:37:56 +00:00
John Crispin
9f73ab51f3
refreshed madwifi patches
...
SVN-Revision: 9380
2007-10-20 19:13:53 +00:00
John Crispin
7558f0281f
DESCRIPTION:= is obselete, so complain if it is used and use TITLE if no description is set
...
SVN-Revision: 9307
2007-10-14 04:49:05 +00:00
John Crispin
5a4b6b5f4e
changed pkg_install_files so one can specify the folder to install from
...
SVN-Revision: 9192
2007-10-08 19:49:11 +00:00
John Crispin
33ecac1f24
added a function, that packages can call to make installing files/folders much cleaner and easier
...
SVN-Revision: 9171
2007-10-07 01:55:03 +00:00
Felix Fietkau
e2f7a60283
fixes for refresh/update handling
...
SVN-Revision: 9063
2007-09-29 04:29:11 +00:00
Felix Fietkau
97b6135462
add a packaging method that installs files into a subdirectory of bin/ instead of an ipkg
...
SVN-Revision: 9060
2007-09-29 01:21:56 +00:00
Felix Fietkau
dbeb0fad24
Refactor downloading code into download.mk Support multiple file downloads Support svn downloads
...
SVN-Revision: 9057
2007-09-29 00:05:48 +00:00
Felix Fietkau
969ac7459e
add $(STAGING_DIR) as argument to the InstallDev template and update packages accordingly - this way we can reuse InstallDev to automatically generate UninstallDev or create -dev packages
...
SVN-Revision: 9052
2007-09-28 01:45:11 +00:00
Felix Fietkau
800ef0f56c
some minor fixes, cleanups, package build abstraction
...
SVN-Revision: 9051
2007-09-28 01:23:56 +00:00