Cowington Post
7e82b6a34b
newapkbuild: do not expand $CTARGET
2023-06-22 07:13:25 -07:00
Rodrigo Lourenço
1679651370
newapkbuild: fix generating wrong URL with new github urls
...
When giving GitHub URLs like
https://github.com/USER/REPO/archive/refs/tags/TAG.tar.gz
Strip away the /refs/tags part so a valid URL is generated.
Fixes #10034 .
2023-06-22 06:10:54 +02:00
psykose
49ebbd94e9
newapkbuild: update gpep517 template for new style
2023-06-07 07:30:38 +02:00
psykose
fc2f1d628a
newapkbuild: make cmake crossopts less aggressive
2023-05-26 00:14:23 +02:00
psykose
f1d8172827
newapkbuild: don't add python to depends by default
...
this is already traced by abuild python changes
2023-05-24 02:09:48 +02:00
Lauren N. Liberda
a9e06de217
newapkbuild: add gpep517 buildtype
2023-05-24 00:08:39 +00:00
psykose
19d620e8b4
newapkbuild: use cargo-auditable for rust builds
2023-05-20 01:04:12 +02:00
psykose
7bc993400f
newapkbuild: fetch --target for rust
...
this fetches only things for the target triple, so it usually skips e.g.
all the windows crates.
we do this in aports already, in places where it doesn't work we just
unset it.
2023-05-10 15:01:07 +02:00
psykose
f810a11cfb
newapkbuild: improve default cmake
...
- -G Ninja because that is always preferred
- remove inferred trailing dot
- use =ON as that is what we usually use most of the time for true/false
- add samurai to makedeps for -G Ninja
- use flatter ctest invocation
2023-05-10 14:57:48 +02:00
psykose
2c8b0cd1ed
newapkbuild: cleanup meson
...
the jobs are useless because SAMUFLAGS already reads the jobs.
we made a cross file in abuild-meson in aports too.
2023-04-20 18:44:59 +02:00
bjorn3
28bba53928
Replace the rust install preset with an empty section
...
Using install -Dm755 ... is preferable over cargo install
2023-03-28 11:44:45 +02:00
ptrcnull
e261a84f2d
newapkbuild: allow for underscore version separator
2022-12-29 14:57:20 +00:00
psykose
4e855560a7
newapkbuild: make meson test use --print-errorlogs
...
-v outputs everything from the tests, which has a lot of very
uninteresting and spammy data. all we really care about is failures, so
print only the errorlogs on failure by default. this is analogous to the
cmake output on failure
2022-10-25 09:25:56 +00:00
Leo
8219a3219f
newapkbuild: use meson-abuild helper instead of meson
...
abuild-meson is a shellscript that wraps around meson and passes options
meant for packaging software that uses meson, for Alpine Linux.
2022-06-14 13:45:20 +00:00
Jakub Jirutka
140d8ab82c
newapkbuild: do not run cargo test with --release
...
It takes a longer time to compile and, most importantly, it may cause
unnecessary rebuild of everything in the package phase (installation).
2022-06-14 12:25:28 +00:00
Jakub Jirutka
bf1dae494b
newapkbuild: fetch rust dependencies in prepare phase
...
Fetch all dependencies in the prepare phase and do not access network
in the following phases.
2022-06-14 12:25:28 +00:00
Samanta Navarro
dc99ce423a
abuild: fix typos
...
Typos found with codespell
2021-09-21 09:15:34 +00:00
Sören Tempel
33957133ec
newapkbuild: automatically add perl to $depends
...
The same thing is already done for other scripting languages (e.g.
python).
2021-06-10 14:32:52 +00:00
Bart Ribbers
65c9a3d8e5
newapkbuild: use pytest for Python tests
2021-04-20 15:08:36 +00:00
Luca Weiss
f92b56d8c9
newapkbuild: generate check for meson
...
The function already exists but it was never called.
2021-04-12 15:02:18 +00:00
Luca Weiss
05d36a90ce
newapkbuild: escape meson variables
...
Otherwise we'll generate e.g. 'meson compile -j 7 -C output'
2021-04-12 15:02:18 +00:00
Bart Ribbers
700bdb552f
newapkbuild: don't try to build in the package target when using cmake, just install
2021-01-07 14:05:47 +00:00
Jakub Jirutka
b78073f663
newapkbuild: remove /usr/.cargo* after cargo install
...
cargo is now generating two files: .cargo.toml and .cargo2.json.
2020-12-14 07:23:20 +00:00
Newbyte
55be1feb02
newapkbuild.1: remove redundant parenthesis in CMake generator so apkbuild-lint stops complaining
2020-11-08 14:31:46 +00:00
Leo
8eeca0adad
*: say we are using GPL-2.0-only
2020-10-23 11:39:18 -03:00
Rasmus Thomsen
2cc63809ad
newapkbuild: invoke meson directly for build/test/install instead of ninja
...
This has multiple advantages:
* It's tool agnostic (e.g. if we were to drop the ninja symlink
for samu, we wouldn't have to change anything here)
* It allows for more fine grained control, e.g. in meson test,
where we can increase timeouts and print the test log to stdout,
something which we can't control when invoking it via ninja.
* We can pass --no-rebuild to test and install, so ninja doesn't
have to check if anything has to be rebuild against in the test
and install phase, when we built everything in the build phase
already
This is similiar to dd24cdf85f
, but
for meson.
2020-07-06 18:34:29 +00:00
Rasmus Thomsen
d3c93a3d15
abuild: set --locked for all cargo invocations
...
That ensures that we always use the versions specified in the Cargo.lock
file, which is required for reproducible builds
2020-07-06 10:00:13 +00:00
Bart Ribbers
dd24cdf85f
newapkbuild: make CMake packages use cmake --build directly rather than through make
2020-07-06 09:47:29 +00:00
Natanael Copa
7779e913e7
newapkbuild: allow -n option without url
2020-04-14 13:53:10 +00:00
Leo
d0ce42112f
newapkbuild: treat packages that start with py[0-9]- as python packages.
2020-03-30 10:59:06 +00:00
Sören Tempel
5cc73d98c3
newapkbuild: do not pass CFLAGS and CXXFLAGS explicitly
...
With the None build type used nowadays these should be picked up
automatically by the environment. If not, we would also need to pass
CPPFLAGS and LDFLAGS explicitly.
2020-03-30 10:58:02 +00:00
TBK
1888007c38
newapkbuild.in: Allign with CODINGSTYLE quoting
2020-03-23 13:58:59 +00:00
Rasmus Thomsen
69fc8b8fc1
newapkbuild: use 'plain' buildtype for meson and 'None' buildtype for CMake
...
This way Meson and CMake will use the C{,PP,XX}FLAGS we've set in
`/etc/abuild.conf`. Without this change CMake and meson will overwrite
our CFLAGS with custom flags. Most importantly, they prefer -O1/-O2 over
our -Os.
See also: https://lists.alpinelinux.org/~alpine/devel/%3C2896c13070c508a49cbaa72c8fb7f34ea947358b.camel%40cogitri.dev%3E
2020-02-21 18:01:48 +01:00
Leo
e125a76489
newapkbuild: do out-of-source CMake builds by default
...
It is recommended by upstream CMake (it will warn when you do in-source
builds) to keep generated files away from the source.
2020-02-16 19:05:42 +01:00
Natanael Copa
c486b3b4f3
allow override sharedir for testing
...
Aloow overrid sharedir with global ABUILD_SHAREDIR so we test the local
functions.sh instead of a system installed functions.sh
2019-11-07 11:42:23 +00:00
Natanael Copa
f3dc428ea0
rename datadir -> sharedir
...
abuild uses datadir as local variable in various functions. Rename the
global datadir to sharedir to avoid confusion.
2019-11-07 11:42:23 +00:00
Jakub Jirutka
a8f564287e
newapkbuild: simplify source URL derived from GitHub URL
...
GitHub allows to reference https://github.com/ <user>/<proj>/archive/<ver>.tar.gz
also as https://github.com/ <user>/<proj>/archive/<ver>/<anything>.tar.gz.
2019-10-27 20:35:10 +01:00
Jakub Jirutka
6c3b2e6b58
newapkbuild: run cargo install with --locked
...
This forces cargo to install the exact versions of the dependencies
specified in Cargo.lock. This is essential for reproducible builds!
2019-10-27 13:50:53 +01:00
Rasmus Thomsen
05eee44039
newapkbuild: add rust support
2019-10-01 17:12:19 +01:00
Natanael Copa
b7fd57f681
newapkbuild: make python packages only depend on setuptools
...
They normally don't need the python3-dev.
2019-07-17 12:00:57 +00:00
Russ
bffe0efc06
newapkbuild: add py3-setuptools to python apkbuild
...
Seeing as the default python build/check/package apkbuild functions call `setup.py` and that relies on `py3-setuptools`, perhaps it should be added to the makedepends.
Inspiration from https://github.com/alpinelinux/aports/pull/7641#pullrequestreview-234326397
2019-07-17 12:00:11 +00:00
Russ
2122fa7476
newapkbuild: use current directory for cmake
2019-06-12 12:21:19 +00:00
tcely
49c7560c86
newapkbuild: quote pkgname and pkgver
...
These are strings after all and should be quoted even if not strictly necessary because of tradition excluding spaces from package names.
2019-06-12 12:20:35 +00:00
Leo
b743186dfe
newapkbuild.in: add default check() for meson packages.
2019-06-12 12:19:58 +00:00
Oliver Smith
da4aca278f
Cosmetic: newapkbuild: comment for check sections
...
Add a '# Check sections' comment, for consistency with the equally
commented build and package sections.
2019-06-12 12:18:59 +00:00
Oliver Smith
635a699365
newapkbuild: fix empty function regression
...
Since the obsolete 'cd "$builddir"' statements have been removed in [1],
build(), check() and package() can generate empty functions if no build
system is specified or if there is no default for the given build
system. newapkbuild will then fail, as it tries to parse the script it
generated:
$ cd /home/pmos && newapkbuild test
/usr/bin/abuild: /home/pmos/test/APKBUILD: line 18: syntax error: unexpected "}"
$ cat test/APKBUILD
...
build() {
}
...
Fix this by placing ":" in functions that would be empty.
[1]: f83d19ce79
2019-06-12 12:18:59 +00:00
Ikke
f83d19ce79
newapkbuild: remove obsolete cd statements
...
Since `$builddir` is officially supported and abuild automatically cd's to `$builddir`, it does not need to be part of the template anymore.
2019-04-29 18:34:03 +00:00
Natanael Copa
51830efbb5
newapkbuild: fix checksums to be last in ABPKUILD
...
ref https://github.com/alpinelinux/abuild/pull/42
2018-10-03 10:50:25 +00:00
prspkt
9aef4769d1
newapkbuild: use https for sourceforge download links
2018-09-24 21:43:49 +02:00
Jakub Jirutka
1820691b94
newapkbuild: fix default check function for python3
...
`setup.py check` does not run package tests, it performs just some check
of the package metadata. The correct command is `setup.py test`.
2018-07-29 16:21:29 +02:00