The Buildroot coding style defines one space around make assignments and
does not align the assignment symbols.
This patch does a bulk fix of offending packages. The package
infrastructures (or more in general assignments to calculated variable
names, like $(2)_FOO) are not touched.
Alignment of line continuation characters (\) is kept as-is.
The sed command used to do this replacement is:
find * -name "*.mk" | xargs sed -i \
-e 's#^\([A-Z0-9a-z_]\+\)\s*\([?:+]\?=\)\s*$#\1 \2#'
-e 's#^\([A-Z0-9a-z_]\+\)\s*\([?:+]\?=\)\s*\([^\\]\+\)$#\1 \2 \3#'
-e 's#^\([A-Z0-9a-z_]\+\)\s*\([?:+]\?=\)\s*\([^\\ \t]\+\s*\\\)\s*$#\1 \2 \3#'
-e 's#^\([A-Z0-9a-z_]\+\)\s*\([?:+]\?=\)\(\s*\\\)#\1 \2\3#'
Brief explanation of this command:
^\([A-Z0-9a-z_]\+\) a regular variable at the beginning of the line
\([?:+]\?=\) any assignment character =, :=, ?=, +=
\([^\\]\+\) any string not containing a line continuation
\([^\\ \t]\+\s*\\\) string, optional whitespace, followed by a
line continuation character
\(\s*\\\) optional whitespace, followed by a line
continuation character
Hence, the first subexpression handles empty assignments, the second
handles regular assignments, the third handles regular assignments with
line continuation, and the fourth empty assignments with line
continuation.
This expression was tested on following test text: (initial tab not
included)
FOO = spaces before
FOO = spaces before and after
FOO = tab before
FOO = tab and spaces before
FOO = tab after
FOO = tab and spaces after
FOO = spaces and tab after
FOO = \
FOO = bar \
FOO = bar space \
FOO = \
GENIMAGE_DEPENDENCIES = host-pkgconf libconfuse
FOO += spaces before
FOO ?= spaces before and after
FOO :=
FOO =
FOO =
FOO =
FOO =
$(MAKE1) CROSS_COMPILE=$(TARGET_CROSS) -C
AT91BOOTSTRAP3_DEFCONFIG = \
AXEL_DISABLE_I18N=--i18n=0
After this bulk change, following manual fixups were done:
- fix line continuation alignment in cegui06 and spice (the sed
expression leaves the number of whitespace between the value and line
continuation character intact, but the whitespace before that could have
changed, causing misalignment.
- qt5base was reverted, as this package uses extensive alignment which
actually makes the code more readable.
Finally, the end result was manually reviewed.
Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire@gmail.com>
Cc: Yann E. Morin <yann.morin.1998@free.fr>
Cc: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Since the trailing slash is stripped from $($(PKG)_SITE) by pkg-generic.mk:
$(call DOWNLOAD,$($(PKG)_SITE:/=)/$($(PKG)_SOURCE))
so it is redundant.
This patch removes it from $(PKG)_SITE variable for BR consistency.
Signed-off-by: Jerzy Grzegorek <jerzy.grzegorek@trzebnica.net>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
For some reason, libffi installs some header files in
/usr/lib/libffi-<version>/include, which is a non-standard location
and therefore they do not get removed automatically by the
target-finalize logic. This commit adds a post-install hook in
libffi.mk to get rid of these unneeded headers on the target.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Status of the patches:
- libffi-001-Fix-installation-location-of-libffi.patch, preserved.
- libffi-002-Fix-use-of-compact-eh-frames-on-MIPS.patch, preserved
- libffi-arc-01-Add-ARC-support.patch, removed, ARC support was
merged upstream as of commit b082e15091961373c03d10ed0251f619ebb6ed76.
- libffi-arc-02-Rebuild-for-ARC-additions.patch, removed, this patch
was merged upstream as of commit
0f8690a84c874ec09a090c8c6adfb93c594acac6.
- libffi-003-fix-typo.patch, added, reported on the upstream mailing
list as being necessary, will be part of the next 3.1.1 release.
- libffi-004-Add-missing-GNU-stack-markings-in-win32.S.patch, same
status as patch 003.
- libffi-005-Fix-paths-in-libffi.pc.in.patch, same status as patch
003.
The 3.1 release adds support for a number of architectures: ARC
support, ppc64le support, NIOS II support. See
https://sourceware.org/ml/libffi-announce/2014/msg00000.html for
details.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
Since 97c687000 (pkg-autotools.mk: default host AUTORECONF{,_OPT} to the
target values) we automatically enable autoreconf for host builds if it
is enabled for the target, so these can go.
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
In order to be sure that we just deal with the includes related with
the actual package described into libffi.mk it is better to explicitly
specify the version of the libffi we deal with into the post install
hook.
As dev files are deprecated in target rootfs target post install
hook was also deleted.
Signed-off-by: Nicolas Ménégale <nicolas.menegale@openwide.fr>
Reviewed-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
It makes more sense to use a released version for 2013.02 rather than a
git snapshot.
The build system now correctly installs libffi.pc, so we can drop the
manual install.
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
We already had backported patches for the Blackfin and AArch64
support, and now we would have needed to also backport the Xtensa
support and the Microblaze support. This starts to get crazy.
Let's switch to using a Git version from Github, until libffi finally
releases a new stable version.
In order to achieve this, we also need to:
* autoreconf the package, so that a libffi.pc file gets generated
* manually install the libffi.pc file, because it doesn't get
installed by libffi Makefile, for some reason
* remove the part of the target post install hook that was messing
with libffi.pc, since it was modifying the one in STAGING_DIR
(which is odd for a target post install hook), and the libffi.pc
file is anyway not installed to the target anymore.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: Sagaert Johan <sagaert.johan@skynet.be>
Acked-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
libffi is a new requirement for libglib, and as libglib has to be built
for the host as well, libffi has to follow.
Signed-off-by: Daniel Mack <zonque@gmail.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Fixes the following error:
Variable 'includedir' not defined in '/home/daniel/buildroot/output/host/usr/arm-unknown-linux-gnueabi/sysroot/usr/lib/pkgconfig/libffi.pc'
Also, use $(SED) instead of 'sed -i'.
Signed-off-by: Daniel Mack <zonque@gmail.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Thanks to the pkgparentdir and pkgname functions, we can rewrite the
AUTOTARGETS macro in a way that avoids the need for each package to
repeat its name and the directory in which it is present.
[Peter: pkgdir->pkgparentdir]
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
libffi is needed by the Python interpreter.
The libffi library provides a portable, high level programming
interface to various calling conventions. This allows a programmer to
call any function specified by a call interface description at
run-time.
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>