848 Commits

Author SHA1 Message Date
Ian Leonard
8d8ca6cee7 config/options: general cleanup
brackets around variable names
shell builtin for inserting values into empty variables
line indent
variable quotes

Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-25 20:35:43 +00:00
Ian Leonard
ae29226181 config/options: convert to die
Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-25 20:35:39 +00:00
Ian Leonard
df4858f5c2 config/options: set project independent variables early
Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-25 20:15:24 +00:00
Ian Leonard
74668b7cf7 config/source: use https for SOURCEFORGE_SRC
Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-25 20:15:24 +00:00
Ian Leonard
2162e3efe6 config/show_config: only show kodi info when MEDIACENTER=kodi
Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-25 20:15:24 +00:00
Ian Leonard
2a12f77b6e functions: break check_config into its constituent parts; add check_distro
Take the opportunity to cleanup the check_foobar() too.

Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-19 17:44:27 +00:00
Ian Leonard
0727f4c685 config/functions: eliminate use of which; convert to using die
Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-19 17:40:04 +00:00
Ian Leonard
bb8b8322c3 config/functions: add copyright statement
Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-19 17:27:49 +00:00
Ian Leonard
aa00529d3a config/functions: add die() function
die is meant to be a more flexible exit, printing a message to go with
the exit call. It works like:

die -- same as "exit 1"
die "It just broke." -- echo statement, exit value 1
die "Tried to do the thing." "2" -- echo statement, exit value 2

Exit codes other than 1 require a message to go with it.

it would replace existing code that looks like:

echo "ERROR: Everything went wrong. Sorry!"
exit 1

or be more helpful in picking up the pieces when something unexpected
happens then:

do_something || exit 1

Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-19 17:25:18 +00:00
Ian Leonard
f0c1537041 config/functions: reorganize
This reorganizes functions based on their purpose as well as strives to declare
a function prior to another function calling it. No changes in how any function
is implemented.

Purpose groupings:

Function - functions that make it easier to implement other functions
Buildsystem - functions around the build environment
Package - functions that work with packages or configure them
Kernel - functions for getting information on the kernel/firmware
Addon - functions around building kodi addons
Target Configuration - Functions that set something up on the target

Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-19 17:22:15 +00:00
Ian Leonard
520391bb46 config/functions: retire unused functions
eglibc ceased active development years ago and is no longer in tree, so no need
to check for it.

tolower() has been around since 2010 and is unused anywhere. Wish it well!

Should it return, tr '[:upper:]' '[:lower:]' is likely better.

Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-05 15:04:07 +00:00
Ian Leonard
df1cffa51e config/options: cleanup
Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-10-04 20:35:43 +00:00
CvH
3bcd1b67d9 config/options: make VERBOSE usable from promt 2018-09-23 11:58:12 +02:00
MilhouseVH
19f463af05 config/options: include project and device package files in linux depends 2018-09-08 21:10:15 +01:00
MilhouseVH
7d8cd7dbf9
Merge pull request #2921 from mglae/le9_toolchain_nm
Kodi: use toolchain nm for generating wrapper.def
2018-08-29 18:15:43 +01:00
mglae
e8cb05bf23 gcc: install lto plugin for binutils ar/nm/ranlib
config/functions: setup_toolchain(): remove $TARGET_AR_NM_RANLIB_PREFIX handling
2018-08-28 22:30:35 +02:00
MilhouseVH
d949dcb7d0 config/functions: clean up recursion test 2018-08-22 04:45:36 +01:00
MilhouseVH
b1e543c13a kodi: drop ENABLE_SSH after xbmc/12005 2018-08-18 10:01:03 +01:00
Sascha Kuehndel (InuSasha)
a5fd4a44aa
create_addon: do not include addons, embedded in image 2018-07-28 10:50:52 +02:00
CvH
4cc2fbd875 spdx: config/ 2018-07-17 23:58:49 +02:00
Christian Hewitt
a3df92074b
Merge pull request #2803 from MilhouseVH/le90_debug_with_depends
debug: dependencies don't build with debug by default. use + suffix t…
2018-07-15 07:32:52 +04:00
MilhouseVH
dc596457d7
Merge pull request #2808 from HiassofT/le9-revert-dash
Revert "dash: add package, configure as CONFIG_SHELL"
2018-07-01 23:39:05 +01:00
Matthias Reichl
670a95c1ae config/functions: store package caches in build dir
Storing the cache in an exported environment variable can
result in build failures if the cache exceeds the MAX_ARG_STRLEN
limit (128k on linux) which can be triggered by building in a
rather deeply nested directory.

Signed-off-by: Matthias Reichl <hias@horus.com>
2018-07-01 10:44:17 +02:00
Matthias Reichl
25f254890f Revert "dash: add package, configure as CONFIG_SHELL"
This reverts commit 3b5986704e002602cf72c9e34206d2938dcc0a0b.

The config shell is set as an interpreter in libtool scripts
and as Linux has a hard limit of 127 bytes on the first line
in scripts (including the hashbang) this causes the build to
fail with a "bad interpreter" error if the path to the config
shell exceeds this limit.

These errors were first noticed on jenkins builds but can be
easily reproduced by building LibreELEC in a longer build dir.

eg RPi2 clean build failing on libtool invocation in kmod build:

./doltlibtool: /home/hias/rpi/libreelec-testing-with-a-long-directory-path-as-on-jenkins/build.LibreELEC-RPi2.arm-9.0-devel/kmod-24/.x86_64-linux-gnu/libtool: /home/hias/rpi/libreelec-testing-with-a-long-directory-path-as-on-jenkins/build.LibreELEC-RPi2.arm-9.0-devel/toolchain/bin/d: bad interpreter: No such file or directory

Signed-off-by: Matthias Reichl <hias@horus.com>
2018-06-30 12:31:22 +02:00
Matthias Reichl
f1977c91aa
Merge pull request #2785 from MilhouseVH/le90_dash_config_shell
dash: add package, configure as default CONFIG_SHELL [RFC]
2018-06-27 07:38:50 +02:00
MilhouseVH
5f91f0cf49 debug: dependencies don't build with debug by default. use + suffix to enable 2018-06-26 22:30:49 +01:00
Matthias Reichl
13c7a4a2ca
Merge pull request #2761 from Kwiboo/linaro-toolchain
linux: use linaro toolchain when KERNEL_LINARO_TOOLCHAIN is set
2018-06-18 10:10:03 +02:00
CvH
dd4eaa1487
Merge pull request #2776 from MilhouseVH/linux4170
linux (Generic): update to linux-4.17.2
2018-06-17 21:53:12 +02:00
MilhouseVH
3b5986704e dash: add package, configure as CONFIG_SHELL 2018-06-17 18:17:42 +01:00
Matthias Reichl
423242fda6 config_functions: add kernel_make
Signed-off-by: Matthias Reichl <hias@horus.com>
2018-06-16 18:28:21 +01:00
Jonas Karlman
f28faae236 linux: use linaro toolchain when KERNEL_LINARO_TOOLCHAIN is set 2018-06-14 07:42:40 +02:00
MilhouseVH
700b54c13a
Merge pull request #2748 from antonlacon/hashstyle
build: only use gnu-style hash table in binaries
2018-06-14 01:41:49 +01:00
MilhouseVH
e6d3d74a7b
Merge pull request #2766 from lrusak/v4l2
some v4l2 and libdrm updates
2018-06-13 00:34:21 +01:00
awiouy
bd7ab2657f debug_strip: use PKG_BUILD_FLAGS 2018-06-12 19:48:41 +02:00
Lukas Rusak
487df8b8b0
config/graphic: add support for etnaviv 2018-06-11 10:18:51 -07:00
Lukas Rusak
bc6edc4fed
config/graphic: add support for freedreno 2018-06-11 10:18:51 -07:00
Lukas Rusak
42b160894f
config/graphic: add V4L2_SUPPORT for vc4 2018-06-11 10:18:51 -07:00
Lukas Rusak
8c24c78231
config/graphic: add default value for V4L2_SUPPORT 2018-06-11 10:18:50 -07:00
Ian Leonard
c7952a9539 build: set hash-style to gnu via gcc default
Builds use a mix of styles for the hash table in the ELF header. Only
one style of table is necessary, and the GNU one is more performant
for lookups. Eliminating the SysV style hash table trims ~450kb. This
is done via setting the default linker in gcc instead of LDFLAGS as
some packages ignore LDFLAGS.

Note that if MIPS is ever added as a supported architecture, it
does not support hash-style=gnu at this time.

Signed-off-by: Ian Leonard <antonlacon@gmail.com>
2018-06-09 21:17:31 +00:00
Lukas Rusak
926ad175ca
config/functions: add llvm-config to meson cross file 2018-06-05 10:26:25 -07:00
Sascha Kuehndel (InuSasha)
ca54a7f1a9
WC/WP: use older linaro compiler for WeTek_Core/Play
- linux-3.10 are not able to build with gcc-8.1
2018-06-04 20:17:29 +02:00
Sascha Kuehndel (InuSasha)
58d7972dad
buildsystem: add -mtune to CFLAGS, to be in sync with LDFLAGS. Else segfault is triggered in lto build 2018-06-04 20:07:06 +02:00
Matthias Reichl
fc6144ba37 config/functions: support lto-parallel, lto-fat and lto-off build flags
Signed-off-by: Matthias Reichl <hias@horus.com>
2018-06-04 19:54:29 +02:00
Matthias Reichl
b03cb4cc2f config/optimize, config/functions: refactor lto flags
Split up the LTO flags in config/optimize and assemble
full C/CXX/LDFLAGS in config/functions.

Add flags for parallel/single-threaded lto and fat/non-fat
lto object creation.

Change the default lto build flag to use non-fat lto objects.

Signed-off-by: Matthias Reichl <hias@horus.com>
2018-06-04 19:54:29 +02:00
Matthias Reichl
57832185cc config/functions: use gcc-ar/gcc-nm/gcc-ranlib when LTO is enabled
This is needed to properly create static libs with LTO objects.

Signed-off-by: Matthias Reichl <hias@horus.com>
2018-06-04 19:54:29 +02:00
Matthias Reichl
7608095b4e config/functions: don't enable LTO by default
Packages are only built with LTO if it's explicitly enabled via
the lto build flag or if a package enables LTO via configure / cmake
options.

Enabling LTO via configure / cmake is the preferred way as this
gives packages more fine grained control, eg enable parallel LTO
linking etc. When doing this packages should respect the
LTO_SUPPORT setting so LTO can be disabled globally.

To avoid conflicting C/CXX/LDFLAGS no FLAGS are added when the
lto build flag is not set.

Signed-off-by: Matthias Reichl <hias@horus.com>
2018-06-04 19:54:28 +02:00
CvH
fe1d278963
Merge pull request #2689 from MilhouseVH/le90_init_sky42_patches
init: add sky42 enhancements/bug fixes
2018-05-23 02:27:33 +02:00
MilhouseVH
1626fdb8df
Merge pull request #2711 from lrusak/graphics-default
config/graphic: reset variables when calling get_graphicsdrivers()
2018-05-21 17:28:51 +01:00
Lukas Rusak
e23f0cb5f2
config/graphic: remove duplicate entries in XORG_DRIVERS variable 2018-05-20 21:15:42 -07:00
Lukas Rusak
32a7930b9a
config/graphic: optimize get_graphicsdrivers by removing for loop 2018-05-20 20:11:55 -07:00