Commit Graph

31 Commits (18451644ffba004395bb016adbdb0bfe7d6ff50e)

Author SHA1 Message Date
Alexander Larsson 4e15d9a5f8 common: Add GSubprocessFlags to flatpak_spawnv
This is useful to e.g. hide stderr
2017-08-18 10:56:15 +02:00
Alexander Larsson 9c06cbb360 Add support for --extra-sources-url=URL
This makes flatpak-builder look in the specified URL for mirrored
sources before downloading the original URL.
2017-07-29 17:43:10 +02:00
Philip Withnall 548f60ebc0 general: Add missing `static` modifier to various local methods
The compiler warning flag which was supposed to warn about this was not
being included in the CFLAGS for these targets. That will be fixed in an
upcoming commit.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
2017-07-06 14:41:21 +01:00
Alexander Larsson a5157d445b builder: Use context_find_in_sources_dirs to simplify code
Instead of open-coding the search everywhere. Also some places
are changed to use flatpak_build_file to further simplify
the code.
2017-04-24 09:02:42 +02:00
Alexander Larsson 3058d413f0 builder: Use flatpak_mkdir_p instead of query + mkdir 2017-04-21 16:38:05 +02:00
Simon Schampijer bb11ef3c37 Merge remote-tracking branch 'upstream/master' into bundle-sources 2017-04-21 00:13:01 +02:00
Alexander Larsson 2f24c9bc31 builder: Use module-relative paths for archive sources too 2017-04-20 15:06:06 +02:00
Simon Schampijer d567b31d3d Bundle sources: initialize app_dir_path later 2017-04-13 13:32:33 +02:00
Simon Schampijer 4357ba6844 Bundle sources: allow use case to mix local and online sources
Fix checksum check for archives and files when sources are from
a local directory.
2017-04-13 13:32:33 +02:00
Simon Schampijer 894311e243 flatpak-builder: bundle module sources as runtime
This adds a step to the build process to bundle
the module sources, used for building the flatpak,
as a runtime extension.

The sources can then be installed like the
debug or translation runtime.

This also adds an option to flatpak-builder
for specifying sources directories. One can specify
source dirctories with the use-sources argument. This
will skip the download part of the processing
and will extract the sources from the given sources
directory directly for further processing.

Those source directories do need the same
structure as the ones that flatpak-builder
creates during processing in .flatpak-builder
and which is also used in the exported sources
runtime.
2017-04-13 13:32:33 +02:00
Mario Sanchez Prada df680dc0a6 Fix clang build: remove unused variables 2017-02-14 09:00:57 +01:00
Alexander Larsson 08ea3baf49 builder: Download files and archives directly to disk, don't keep them in memory.
This works much better for larger sources.
2017-02-09 12:26:05 +01:00
Alexander Larsson bf316c1a82 builder: Compute SHA256 while downloading archives 2017-02-09 12:17:10 +01:00
Alexander Larsson 91c9d474dd flatpak-builder: Add support for --show-deps 2016-09-20 15:58:43 +02:00
Alexander Larsson e792686892 builder: Propagate build-args to shell sources
This way you can e.g. do network i/o in them.
Thats not a recommended way to do it though, as you work around
a lot of the feature in flatpak-builder like the caching and
verification.
2016-09-05 22:01:56 +02:00
Simon McVittie 5b8fdb4998 unrpm: prevent shell injection
Substituting into a shell command-line without escaping is a bad idea.
If the argument is attacker-controlled, it's a security vulnerability;
if the argument is legitimate-user-controlled (as I think it is here)
it's merely wrong.

We could escape the filename with g_shell_quote(), but it's more
straightforward to take advantage of the shell's argument processing.
The first positional parameter (if given) is $0, and the rest are $@.

Signed-off-by: Simon McVittie <smcv@debian.org>
2016-07-18 14:32:14 +01:00
Christophe Fergeau 2b609c6624 Add RPM archive support 2016-07-15 11:13:28 +02:00
Christophe Fergeau 543d81c2fe Factor some zip uncompression code in a helper func 2016-07-15 11:13:28 +02:00
Alexander Larsson 9d6bc99649 builder: Untar with --no-same-owner
Without this if you run as root (which is generally a poor idea) it will
extract the sources with the user/group specified on the archive, which
is never what you want when building code.
2016-05-12 19:35:32 +02:00
Alexander Larsson c24528d369 Rename source files to flatpak 2016-05-09 09:00:20 +02:00
Alexander Larsson 6a613d1fab Rename all non-autogenerated symbols to flatpak 2016-05-09 09:00:20 +02:00
Alexander Larsson 1ffdf27d92 uncruftify: Initial run, all non-problematic changes 2016-05-06 16:03:27 +02:00
Alexander Larsson 71259fa711 builder: Support local archives with path property 2016-02-17 14:50:01 +01:00
Alexander Larsson 93e8d8bd78 builder: Add some spew when downloading files 2016-01-14 16:45:44 +01:00
Alexander Larsson 1264335458 builder: Add --disable-updates
Download sources, but never update existing sources (like git or bzr).
2015-12-21 10:39:23 +01:00
Alexander Larsson f16cc44a30 builder: Use SoupRequest to simplify download helpers
Also, this allows us to support data: uris, etc
2015-12-09 12:55:10 +01:00
Alexander Larsson e39192b3d6 builder: Break out download_uri helper function in SourceFile 2015-12-09 11:42:04 +01:00
Alexander Larsson e76da99cdc builder: Merge spawn helpers to single base helper 2015-12-03 13:29:08 +01:00
Alexander Larsson a8eefe6844 Remove stray semicolons 2015-12-01 12:31:20 +01:00
Alexander Larsson f710eb9322 Correct license, we're LGPL 2+, not 3+
Some files accidentally got the LGPL 3+ header, but we
want to be LGPL2+.
2015-11-26 14:50:21 +01:00
Alexander Larsson b2790349d6 Add xdg-app-builder
This is a tool that makes it easy to build applications and their
dependecies by automating the configure && make && make install steps.
2015-11-25 15:26:32 +01:00