Commit graph

10 commits

Author SHA1 Message Date
Giulio Benetti 160f0a033b package/gettext-tiny: bump version
On current version msgmerge doesn't work properly, it exits with:

  fopen: No such file or directory

The problem has been reported at
https://github.com/sabotage-linux/gettext-tiny/issues/42 and fixed
with commit
a597aaebd1

Signed-off-by: Giulio Benetti <giulio.benetti@micronovasrl.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-10-25 23:27:37 +02:00
Vadim Kochan 554fa317ba package/gettext: ensure GETTEXTIZE is always defined
After introducing gettext-tiny in:

	5367a1b253 package/gettext-tiny: new package

GETTEXTIZE variable is conditionally defined separately by gettext-gnu
or gettext-tiny package depending on which of them is
enabled. However, gettext-gnu only defines it when the target
gettext-gnu package is enabled. This is wrong, because the target
gettext-gnu package is only needed when the C library doesn't provide
a proper gettext implementation (uClibc, musl). When glibc is used,
gettext functionality is provided by the toolchain, and the target
gettext-gnu package is not enabled, causing GETTEXTIZE to not be
defined. This causes build failures in packages that need
gettextizing, in configurations that have BR2_SYSTEM_ENABLE_NLS=y and
use glibc.

This commit fixes this issue by defining GETTEXTIZE unconditionally in
package/gettext/gettext.mk. It is not needed to define it in each
gettext-*.mk because the difference is only in passing the 'data_dir'
parameter which points to ${PREFIX}/share/gettext-tiny (in case of
gettext-tiny provider), but a simple symlink:

	${PREFIX}/share/gettext -> ${PREFIX}/share/gettext-tiny

solves this issue.

Reported-by: Romain Naour <romain.naour@gmail.com>
Signed-off-by: Vadim Kochan <vadim4j@gmail.com>
Reviewed-by: Romain Naour <romain.naour@smile.fr>
[Thomas: improve commit log]
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-04-10 13:35:05 +02:00
Vadim Kochan 63af60fae3 package/gettext-tiny: drop dependency of host-variant on libiconv
The host variant of gettext-tiny incorrectly has a dependency on the
target libiconv. Not only this is wrong (a host package cannot use a
target library), but it also causes a circular dependencies:
host-gettext-tiny is needed as part of the toolchain build in some
configurations, and all target packages depend on the toolchain being
available.

For host packages, we assume that iconv functionnality is provided by
the host system, so there is no host-libiconv package.

Signed-off-by: Vadim Kochan <vadim4j@gmail.com>
Reviewed-by: Alexey Brodkin <abrokdin@synopsys.com>
[Thomas: rework commit log]
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-04-10 12:01:27 +02:00
Vadim Kochan acb142c3fb package/gettext-tiny: do not install headers
Since:

    58187329ad

gettext macrosesss are used by default (if no LIBINTL_NO_MACROS is
included in CPPFLAGS). It causes packages such as libglib2 to fail
building with argument format errors because in case of error the
formatted string is passed as argument.

Fix it by prevent the installation of libintl.h header from
gettext-tiny by passing LIBINTL=NONE, because each kind of toolchain
already provides gettext stubs. Also with this change the following
patch is not needed:

	0001-libintl-Fix-format-not-a-string-literal-error-for-gc.patch

Fixes:
	http://autobuild.buildroot.net/results/89fcc4e80ea8c031c1abb350362c19c57eb80e7c/
	http://autobuild.buildroot.net/results/84f3eb70fc1c58986dfa7c79d45aaabdf4c011cf/

and a lot other autobuild reports.

Signed-off-by: Vadim Kochan <vadim4j@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-04-07 15:09:26 +02:00
Giulio Benetti 758ea0e518 package/gettext-tiny: bump version to add --template option
Some packages (i.e. rygel) uses the msgfmt tool with its --template
option. However, the current version of gettext-tiny (0.3.1) doesn't
support --template flag and exits giving: "fopen: No such file or
directory".

In upstream gettext-tiny they have added support for --template after
lots of modifications, so it's hard to produce a patch to be applied
against 0.3.1. Therefore, we bump the version to the latest master
branch commit.

Fixes:

  http://autobuild.buildroot.net/results/77b1854c914915d3205d915a0f01001f6f3555df/

Signed-off-by: Giulio Benetti <giulio.benetti@micronovasrl.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-04-04 21:52:09 +02:00
Yann E. MORIN 9766d7eec1 package/gettext-tiny: host and target legal-info are different
For the target, we only ever use the gettext-tiny source, while for
the host we also use that of gettext-gnu.

Fixes:
    http://autobuild.buildroot.org/results/572/5724b246cf411d95702fcff6dbf2b809b899108c/

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Vadim Kochan <vadim4j@gmail.com>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Tested-by: "Giulio Benetti" <giulio.benetti@micronovasrl.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-04-01 21:52:12 +02:00
Yann E. MORIN 01e0fec161 package/gettext-tiny: fix build of libintl.a
Since libintl.a can be pulled in during the build of other shared libs,
it must be compiled with -fPIC, which is what gettext-tiny's Makefile
would do.

Since we provide our own CFLAGS, they override those in the Makefile.

Fix that by ensuring that -fPIC is used when building the static
library.

Fixes:
    http://autobuild.buildroot.org/results/a38/a3800fd4ef2536cc2b82d38ea752baa2b227bc64/

Also, since GETTEXT_TINY_OPTS is used only once and contains a single
definition, get rid of it altogether.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Vadim Kochan <vadim4j@gmail.com>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-31 20:54:43 +02:00
Yann E. MORIN 916f02c7d9 package/gettext-tiny: fix licensing
Fix the license list: it should be a space-separated list of files, it
is not a comma-separated list.

Fixes:
    http://autobuild.buildroot.org/results/74b/74be940e5757d18452b0eb97b9973c278be20345/

Add hashes for the license files while at it, and cleanup the hash file
as well.

Signed-off-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Cc: Vadim Kochan <vadim4j@gmail.com>
Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-31 20:54:22 +02:00
Thomas Petazzoni 038dda0cd5 package/gettext-tiny: take GNU gettext from our own directory
Even though gettext-tiny re-uses the gettext-gnu source code, it makes
a separate download in the gettext-tiny download folder, so use this
one, and not the one from the gettext-gnu download folder, which may
not exist.

Fixes:

  http://autobuild.buildroot.net/results/4e289f30bc6e58ad81611e8e04779134dcbe1241/

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-31 15:23:45 +02:00
Vadim Kochan 5367a1b253 package/gettext-tiny: new package
Add gettext-tiny package from the sabotage-linux project:

    gettext-tiny provides lightweight replacements for tools typically used
    from the GNU gettext suite, which is incredibly bloated and takes a lot
    of time to build (in the order of an hour on slow devices). the most
    notable component is msgfmt which is used to create binary translation
    files in the .mo format out of textual input files in .po format. this
    is the most important tool for building software from source, because it
    is used from the build processes of many software packages.

Some files were taken from gettext-gnu (some po/* files and gettextize
script) to make possible perform gettextizing of packages.

The main purpose of gettext-tiny is to replace gettext for the "host" if
NLS support is not needed. There is no option to manually select
gettext-gnu or gettext-tiny, it is done automatically by virtual gettext
package. For the target gettext-tiny only installs gettext tool echo-wrapper
which might be called from shell scripts (i.e. ecryptfs-utils).

Signed-off-by: Vadim Kochan <vadim4j@gmail.com>
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
2019-03-31 14:04:30 +02:00