Compare commits
1 commit
Author | SHA1 | Date | |
---|---|---|---|
|
be5540fc78 |
333 changed files with 9075 additions and 7922 deletions
2
.github/workflows/cycles.yml
vendored
2
.github/workflows/cycles.yml
vendored
|
@ -10,7 +10,7 @@ jobs:
|
|||
permissions:
|
||||
issues: write
|
||||
container:
|
||||
image: 'ghcr.io/void-linux/xbps-src-masterdir:20230425RC01-x86_64-musl'
|
||||
image: 'ghcr.io/void-linux/xbps-src-masterdir:20220527RC01-x86_64-musl'
|
||||
steps:
|
||||
- name: Prepare container
|
||||
run: |
|
||||
|
|
2
.github/workflows/manual_check_cycles.yml
vendored
2
.github/workflows/manual_check_cycles.yml
vendored
|
@ -8,7 +8,7 @@ jobs:
|
|||
permissions:
|
||||
issues: write
|
||||
container:
|
||||
image: 'ghcr.io/void-linux/xbps-src-masterdir:20230425RC01-x86_64-musl'
|
||||
image: 'ghcr.io/void-linux/xbps-src-masterdir:20220527RC01-x86_64-musl'
|
||||
steps:
|
||||
- name: Prepare container
|
||||
run: |
|
||||
|
|
22
.gitignore
vendored
22
.gitignore
vendored
|
@ -2,23 +2,13 @@
|
|||
*.swp
|
||||
*~
|
||||
\#*#
|
||||
|
||||
# exclude everything in root except files and directories from void-packages
|
||||
/*
|
||||
!/.gitattributes
|
||||
!/.github
|
||||
!/.gitignore
|
||||
!/.mailmap
|
||||
!/CONTRIBUTING.md
|
||||
!/COPYING
|
||||
!/Manual.md
|
||||
!/README.md
|
||||
!/common
|
||||
!/etc
|
||||
!/srcpkgs
|
||||
!/xbps-src
|
||||
*.o
|
||||
masterdir*
|
||||
hostdir*
|
||||
masterdir*/
|
||||
hostdir*/
|
||||
etc/conf
|
||||
etc/conf.*
|
||||
etc/virtual
|
||||
etc/xbps.d/custom
|
||||
etc/repo-keys
|
||||
.xbps-checkvers*.plist
|
||||
|
|
|
@ -20,7 +20,6 @@ while not meeting any of the following requirements, is a good candidate for the
|
|||
In particular, new themes are highly unlikely to be accepted.
|
||||
Simple shell scripts are unlikely to be accepted unless they provide considerable value to a broad user base.
|
||||
New fonts may be accepted if they provide value beyond aesthetics (e.g. they contain glyphs for a script missing in already packaged fonts).
|
||||
Packages related to cryptocurrencies (wallets, miners, nodes, etc) are not accepted.
|
||||
|
||||
Browser forks, including those based on Chromium and Firefox, are generally not accepted.
|
||||
Such forks require heavy patching, maintenance and hours of build time.
|
||||
|
@ -57,7 +56,7 @@ This automatically sets up the `upstream` remote, so `git pull --rebase upstream
|
|||
|
||||
Using the GitHub web editor for making changes is strongly discouraged, because you will need to clone the repo anyways to edit and test your changes.
|
||||
|
||||
Using the `master` branch of your fork for contributing is also strongly discouraged.
|
||||
using the the `master` branch of your fork for contributing is also strongly discouraged.
|
||||
It can cause many issues with updating your pull request (also called a PR), and having multiple PRs open at once.
|
||||
To create a new branch:
|
||||
|
||||
|
@ -82,29 +81,6 @@ The checksum can be updated automatically with the `xgensum` helper from the [xt
|
|||
|
||||
$ xgensum -i <pkgname>
|
||||
|
||||
### Adopting a template
|
||||
|
||||
If a template is orphaned (maintained by `orphan@voidlinux.org`) or the current `maintainer` has not contributed to
|
||||
Void in over a year, template maintainership can be adopted by someone else. To ensure a template gets the care it needs,
|
||||
template adopters should be familiar with the package and have an established history of contributions to Void.
|
||||
Those who have contributed several updates, especially for the template in question, are good candidates for template
|
||||
maintainership.
|
||||
|
||||
It is best to adopt a template when making another change to it. When adopting the template, add your name or username
|
||||
and email to the `maintainer` field in the template, and mention the adoption in your commit message, for example:
|
||||
|
||||
libfoo: update to 1.2.3, adopt.
|
||||
|
||||
### Orphaning a template
|
||||
|
||||
If you no longer wish to maintain a template, you can remove yourself as maintainer by setting the `maintainer` field in
|
||||
the template to `Orphaned <orphan@voidlinux.org>`. The commit message should mention this, for example:
|
||||
|
||||
libfoo: orphan.
|
||||
|
||||
It is not necessary to make other changes to the template when orphaning, and incrementing the revision (triggering a
|
||||
rebuild) is not necessary either.
|
||||
|
||||
### Committing your changes
|
||||
|
||||
After making your changes, please check that the package builds successfully. From the top level directory of your local copy of the `void-packages` repository, run:
|
||||
|
|
2
COPYING
2
COPYING
|
@ -1,5 +1,5 @@
|
|||
Copyright (c) 2008-2020 Juan Romero Pardines and contributors
|
||||
Copyright (c) 2017-2024 The Void Linux team and contributors
|
||||
Copyright (c) 2017-2022 The Void Linux team and contributors
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
|
|
251
Manual.md
251
Manual.md
|
@ -5,8 +5,7 @@ packages for XBPS, the `Void Linux` native packaging system.
|
|||
|
||||
*Table of Contents*
|
||||
|
||||
* The XBPS source packages manual
|
||||
* [Introduction](#Introduction)
|
||||
* [Introduction](#Introduction)
|
||||
* [Package build phases](#buildphase)
|
||||
* [Package naming conventions](#namingconventions)
|
||||
* [Libraries](#libs)
|
||||
|
@ -28,20 +27,20 @@ packages for XBPS, the `Void Linux` native packaging system.
|
|||
* [Build helper scripts](#build_helper)
|
||||
* [Functions](#functions)
|
||||
* [Build options](#build_options)
|
||||
* [Runtime dependencies](#deps_runtime)
|
||||
* [INSTALL and REMOVE files](#install_remove_files)
|
||||
* [INSTALL.msg and REMOVE.msg files](#install_remove_files_msg)
|
||||
* [Creating system accounts/groups at runtime](#runtime_account_creation)
|
||||
* [Writing runit services](#writing_runit_services)
|
||||
* [32bit packages](#32bit_pkgs)
|
||||
* [Subpackages](#pkgs_sub)
|
||||
* [Some package classes](#pkgs_classes)
|
||||
* [Development packages](#pkgs_development)
|
||||
* [Data packages](#pkgs_data)
|
||||
* [Documentation packages](#pkgs_documentation)
|
||||
* [Python packages](#pkgs_python)
|
||||
* [Go packages](#pkgs_go)
|
||||
* [Haskell packages](#pkgs_haskell)
|
||||
* [Font packages](#pkgs_font)
|
||||
* [Development packages](#pkgs_development)
|
||||
* [Data packages](#pkgs_data)
|
||||
* [Documentation packages](#pkgs_documentation)
|
||||
* [Python packages](#pkgs_python)
|
||||
* [Go packages](#pkgs_go)
|
||||
* [Haskell packages](#pkgs_haskell)
|
||||
* [Font packages](#pkgs_font)
|
||||
* [Renaming a package](#pkg_rename)
|
||||
* [Removing a package](#pkg_remove)
|
||||
* [XBPS Triggers](#xbps_triggers)
|
||||
|
@ -62,6 +61,7 @@ packages for XBPS, the `Void Linux` native packaging system.
|
|||
* [kernel-hooks](#triggers_kernel_hooks)
|
||||
* [mimedb](#triggers_mimedb)
|
||||
* [mkdirs](#triggers_mkdirs)
|
||||
* [openjdk-profile](#triggers_openjdk_profile)
|
||||
* [pango-modules](#triggers_pango_module)
|
||||
* [pycompile](#triggers_pycompile)
|
||||
* [register-shell](#triggers_register_shell)
|
||||
|
@ -73,10 +73,10 @@ packages for XBPS, the `Void Linux` native packaging system.
|
|||
* [Void specific documentation](#documentation)
|
||||
* [Notes](#notes)
|
||||
* [Contributing via git](#contributing)
|
||||
* [Help](#help)
|
||||
* [Help](#help)
|
||||
|
||||
<a id="Introduction"></a>
|
||||
### Introduction
|
||||
## Introduction
|
||||
|
||||
The `void-packages` repository contains all the
|
||||
recipes to download, compile and build binary packages for Void Linux.
|
||||
|
@ -304,7 +304,7 @@ The following functions are defined by `xbps-src` and can be used on any templat
|
|||
`$DESTDIR`. The optional 2nd argument can be used to change the
|
||||
`file name`. See [license](#var_license) for when to use it.
|
||||
|
||||
- *vsv()* `vsv <service> [<facility>]`
|
||||
- *vsv()* `vsv <service>`
|
||||
|
||||
Installs `service` from `${FILESDIR}` to /etc/sv. The service must
|
||||
be a directory containing at least a run script. Note the `supervise`
|
||||
|
@ -312,11 +312,6 @@ The following functions are defined by `xbps-src` and can be used on any templat
|
|||
is automatically made executable by this function.
|
||||
For further information on how to create a new service directory see
|
||||
[The corresponding section the FAQ](http://smarden.org/runit/faq.html#create).
|
||||
A `log` sub-service will be automatically created if one does not exist in
|
||||
`${FILESDIR}/$service`, containing `exec vlogger -t $service -p $facility`.
|
||||
if a second argument is not specified, the `daemon` facility is used.
|
||||
For more information about `vlogger` and available values for the facility,
|
||||
see [vlogger(8)](https://man.voidlinux.org/vlogger.8).
|
||||
|
||||
- *vsed()* `vsed -i <file> -e <regex>`
|
||||
|
||||
|
@ -335,29 +330,6 @@ The following functions are defined by `xbps-src` and can be used on any templat
|
|||
it will default to `pkgname`. The `shell` argument can be one of `bash`,
|
||||
`fish` or `zsh`.
|
||||
|
||||
- *vextract()* `[-C <target directory>] [--no-strip-components|--strip-components=<n>] <file>`
|
||||
|
||||
Extracts `file` to `target directory` with `n` directory components stripped. If
|
||||
`target directory` not specified, defaults to the working directory. If
|
||||
`--strip-components` or `--no-strip-components` is not specified, defaults to
|
||||
`--strip-components=1`.
|
||||
|
||||
- *vsrcextract()* `[-C <target directory>] [--no-strip-components|--strip-components=<n>] <file>`
|
||||
|
||||
Extracts `$XBPS_SRCDISTDIR/$pkgname-$version/<file>` to `target directory`
|
||||
with `n` directory components stripped. If `target directory` not specified,
|
||||
defaults to the working directory. If `--strip-components` or `--no-strip-components`
|
||||
is not specified, defaults to `--strip-components=1`.
|
||||
|
||||
This is useful when used in conjunction with `skip_extraction` and for submodule distfiles.
|
||||
|
||||
- *vsrccopy()* `<file>... <target>`
|
||||
|
||||
Copies `file`s from `$XBPS_SRCDISTDIR/$pkgname-$version/` into the `target` directory,
|
||||
creating `target` if it does not exist.
|
||||
|
||||
This is useful when used in conjunction with `skip_extraction`.
|
||||
|
||||
> Shell wildcards must be properly quoted, Example: `vmove "usr/lib/*.a"`.
|
||||
|
||||
<a id="global_vars"></a>
|
||||
|
@ -445,7 +417,7 @@ Multiple licenses should be separated by commas, Example: `GPL-3.0-or-later, cus
|
|||
and thus have and require no license should use
|
||||
`Public Domain`.
|
||||
|
||||
Note: `AGPL`, `MIT`, `BSD`, `ISC`, `X11`, and custom licenses
|
||||
Note: `MIT`, `BSD`, `ISC` and custom licenses
|
||||
require the license file to be supplied with the binary package.
|
||||
|
||||
- `maintainer` A string in the form of `name <user@domain>`. The email for this field
|
||||
|
@ -463,8 +435,8 @@ the generated `binary packages` have been modified.
|
|||
- `version` A string with the package version. Must not contain dashes or underscore
|
||||
and at least one digit is required. Shell's variable substitution usage is not allowed.
|
||||
|
||||
`pkgname` and `version` are forbidden to contain special characters. Hence, they don't
|
||||
need to be quoted, and by convention, they shouldn't be.
|
||||
Neither `pkgname` or `version` should contain special characters which make it
|
||||
necessary to quote them, so they shouldn't be quoted in the template.
|
||||
|
||||
<a id="optional_vars"></a>
|
||||
#### Optional variables
|
||||
|
@ -759,9 +731,9 @@ built for, available architectures can be found under `common/cross-profiles`.
|
|||
In general, `archs` should only be set if the upstream software explicitly targets
|
||||
certain architectures or there is a compelling reason why the software should not be
|
||||
available on some supported architectures.
|
||||
Prepending a pattern with a tilde means disallowing build on the indicated archs.
|
||||
The first matching pattern is taken to allow/deny build. When no pattern matches,
|
||||
the package is built if the last pattern includes a tilde.
|
||||
Prepending pattern with tilde means disallowing build on indicated archs.
|
||||
First matching pattern is taken to allow/deny build. When no pattern matches,
|
||||
package is build if last pattern includes tilde.
|
||||
Examples:
|
||||
|
||||
```
|
||||
|
@ -810,65 +782,20 @@ should be listed in `checkdepends` and will be installed as if they were part of
|
|||
a D-Bus session for applications that need it
|
||||
- `git`: some test suites run the `git` command
|
||||
|
||||
<a id="deps_runtime"></a>
|
||||
Lastly, a package may require certain dependencies at runtime, without which it
|
||||
is unusable. These dependencies, when they aren't detected automatically by
|
||||
XBPS, should be listed in `depends`.
|
||||
|
||||
Libraries linked by ELF objects are detected automatically by `xbps-src`, hence they
|
||||
must not be specified in templates via `depends`. This variable should list:
|
||||
|
||||
- executables called as separate processes.
|
||||
- ELF objects using dlopen(3).
|
||||
- non-object code, e.g. C headers, perl/python/ruby/etc modules.
|
||||
- data files.
|
||||
- overriding the minimal version specified in the `common/shlibs` file.
|
||||
|
||||
The runtime dependencies for ELF objects are detected by checking which SONAMEs
|
||||
they require and then the SONAMEs are mapped to a binary package name with a minimal
|
||||
required version. The `common/shlibs` file
|
||||
sets up the `<SONAME> <pkgname>>=<version>` mappings.
|
||||
|
||||
For example the `foo-1.0_1` package provides the `libfoo.so.1` SONAME and
|
||||
software requiring this library will link to `libfoo.so.1`; the resulting binary
|
||||
package will have a run-time dependency on `foo>=1.0_1` package as specified in
|
||||
`common/shlibs`:
|
||||
|
||||
```
|
||||
# common/shlibs
|
||||
...
|
||||
libfoo.so.1 foo-1.0_1
|
||||
...
|
||||
```
|
||||
|
||||
- The first field specifies the SONAME.
|
||||
- The second field specified the package name and minimal version required.
|
||||
- A third optional field (usually set to `ignore`) can be used to skip checks in soname bumps.
|
||||
|
||||
Dependencies declared via `depends` are not installed to the master directory, rather they are
|
||||
only checked if they exist as binary packages, and are built automatically by `xbps-src` if
|
||||
the specified version is not in the local repository.
|
||||
|
||||
As a special case, `virtual` dependencies may be specified as runtime dependencies in the
|
||||
`depends` template variable. Several different packages can provide common functionality by
|
||||
declaring a virtual name and version in the `provides` template variable (e.g.
|
||||
`provides="vpkg-0.1_1"`). Packages that rely on the common functionality without concern for the
|
||||
specific provider can declare a dependency on the virtual package name with the prefix `virtual?`
|
||||
(e.g., `depends="virtual?vpkg-0.1_1"`). When a package is built by `xbps-src`, providers for any
|
||||
virtual packages will be confirmed to exist and will be built if necessary. A map from virtual
|
||||
packages to their default providers is defined in `etc/defaults.virtual`. Individual mappings can be
|
||||
overridden by local preferences in `etc/virtual`. Comments in `etc/defaults.virtual` provide more
|
||||
information on this map.
|
||||
XBPS, should be listed in `depends`. This is mostly relevant for Perl and Python
|
||||
modules and other programs that use `dlopen(3)` instead of dynamically linking.
|
||||
|
||||
Finally, as a general rule, if a package is built the exact same way whether or
|
||||
not a particular package is present in `makedepends` or `hostmakedepends`, that
|
||||
package shouldn't be added as a build time dependency.
|
||||
|
||||
<a id="repositories"></a>
|
||||
### Repositories
|
||||
#### Repositories
|
||||
|
||||
<a id="repo_by_branch"></a>
|
||||
#### Repositories defined by Branch
|
||||
##### Repositories defined by Branch
|
||||
|
||||
The global repository takes the name of
|
||||
the current branch, except if the name of the branch is master. Then the resulting
|
||||
|
@ -876,19 +803,17 @@ repository will be at the global scope. The usage scenario is that the user can
|
|||
update multiple packages in a second branch without polluting his local repository.
|
||||
|
||||
<a id="pkg_defined_repo"></a>
|
||||
#### Package defined Repositories
|
||||
##### Package defined Repositories
|
||||
|
||||
The second way to define a repository is by setting the `repository` variable in
|
||||
a template. This way the maintainer can define repositories for a specific
|
||||
package or a group of packages. This is currently used to distinguish between
|
||||
certain classes of packages.
|
||||
closed source packages, which are put in the `nonfree` repository and other
|
||||
packages which are at the root-repository.
|
||||
|
||||
The following repository names are valid:
|
||||
|
||||
* `bootstrap`: Repository for xbps-src-specific packages.
|
||||
* `debug`: Repository for packages containing debug symbols. In almost all cases,
|
||||
these packages are generated automatically.
|
||||
* `nonfree`: Repository for packages that are closed source or have nonfree licenses.
|
||||
* `nonfree`: Repository for closed source packages.
|
||||
|
||||
<a id="updates"></a>
|
||||
### Checking for new upstream releases
|
||||
|
@ -929,10 +854,6 @@ in url. Defaults to `(|v|$pkgname)[-_.]*`.
|
|||
part that follows numeric part of version directory
|
||||
in url. Defaults to `(|\.x)`.
|
||||
|
||||
- `disabled` can be set to disable update checking for the package,
|
||||
in cases where checking for updates is impossible or does not make sense.
|
||||
This should be set to a string describing why it is disabled.
|
||||
|
||||
<a id="patches"></a>
|
||||
### Handling patches
|
||||
|
||||
|
@ -985,8 +906,8 @@ should be passed in via `configure_args`.
|
|||
|
||||
- `fetch` For packages that only fetch files and are installed as is via `do_install()`.
|
||||
|
||||
- `gnu-configure` For packages that use GNU autotools-compatible configure scripts,
|
||||
additional configuration arguments can be passed in via `configure_args`.
|
||||
- `gnu-configure` For packages that use GNU configure scripts, additional configuration
|
||||
arguments can be passed in via `configure_args`.
|
||||
|
||||
- `gnu-makefile` For packages that use GNU make, build arguments can be passed in via
|
||||
`make_build_args` and install arguments via `make_install_args`. The build
|
||||
|
@ -1069,11 +990,13 @@ system. Additional arguments may be passed to the `zig build` invocation using
|
|||
For packages that use the Python module build method (`setup.py` or
|
||||
[PEP 517](https://www.python.org/dev/peps/pep-0517/)), you can choose one of the following:
|
||||
|
||||
- `python2-module` to build Python 2.x modules
|
||||
- `python-module` to build *both* Python 2.x and 3.x modules
|
||||
|
||||
- `python3-module` to build Python 3.x modules
|
||||
- `python2-module` to build Python 2.x only modules
|
||||
|
||||
- `python3-pep517` to build Python 3.x modules that provide a PEP 517 build description without
|
||||
- `python3-module` to build Python 3.x only modules
|
||||
|
||||
- `python3-pep517` to build Python 3.x only modules that provide a PEP 517 build description without
|
||||
a `setup.py` script
|
||||
|
||||
Environment variables for a specific `build_style` can be declared in a filename
|
||||
|
@ -1092,7 +1015,8 @@ suitable environment for working with certain sets of packages.
|
|||
|
||||
The current list of available `build_helper` scripts is the following:
|
||||
|
||||
- `cmake-wxWidgets-gtk3` sets the `WX_CONFIG` variable which is used by FindwxWidgets.cmake
|
||||
- `rust` specifies environment variables required for cross-compiling crates via cargo and
|
||||
for compiling cargo -sys crates.
|
||||
|
||||
- `gir` specifies dependencies for native and cross builds to deal with
|
||||
GObject Introspection. The following variables may be set in the template to handle
|
||||
|
@ -1102,20 +1026,6 @@ additional paths to be searched when linking target binaries to be introspected.
|
|||
`qemu-<target_arch>-static` when running the target binary. You can for example specify
|
||||
`GIR_EXTRA_OPTIONS="-strace"` to see a trace of what happens when running that binary.
|
||||
|
||||
- `meson` creates a cross file, `${XBPS_WRAPPERDIR}/meson/xbps_meson.cross`, which configures
|
||||
meson for cross builds. This is particularly useful for building packages that wrap meson
|
||||
invocations (e.g., `python3-pep517` packages that use a meson backend) and is added by default
|
||||
for packages that use the `meson` build style.
|
||||
|
||||
- `numpy` configures the environment for cross-compilation of python packages that provide
|
||||
compiled extensions linking to NumPy C libraries. If the `meson` build helper is also
|
||||
configured, a secondary cross file, `${XBPS_WRAPPERDIR}/meson/xbps_numpy.cross`, will be
|
||||
written to inform meson where common NumPy components may be found.
|
||||
|
||||
- `python3` configures the cross-build environment to use Python libraries, header files, and
|
||||
interpreter configurations in the target root. The `python3` helper is added by default for
|
||||
packages that use the `python3-module` or `python3-pep517` build styles.
|
||||
|
||||
- `qemu` sets additional variables for the `cmake` and `meson` build styles to allow
|
||||
executing cross-compiled binaries inside qemu.
|
||||
It sets `CMAKE_CROSSCOMPILING_EMULATOR` for cmake and `exe_wrapper` for meson
|
||||
|
@ -1129,9 +1039,7 @@ This aims to fix cross-builds for when the build-style is mixed: e.g. when in a
|
|||
`gnu-configure` style the configure script calls `qmake` or a `Makefile` in
|
||||
`gnu-makefile` style, respectively.
|
||||
|
||||
- `rust` specifies environment variables required for cross-compiling crates via cargo and
|
||||
for compiling cargo -sys crates. This helper is added by default for packages that use the
|
||||
`cargo` build style.
|
||||
- `cmake-wxWidgets-gtk3` sets the `WX_CONFIG` variable which is used by FindwxWidgets.cmake
|
||||
|
||||
<a id="functions"></a>
|
||||
### Functions
|
||||
|
@ -1247,11 +1155,6 @@ package accordingly. Additionally, the following functions are available:
|
|||
Outputs `-D<property>=true` if the option is set, or
|
||||
`-D<property>=false` otherwise.
|
||||
|
||||
- *vopt_feature()* `vopt_feature <option> <property>`
|
||||
|
||||
Same as `vopt_bool`, but uses `-D<property=enabled` and
|
||||
`-D<property>=disabled` respectively.
|
||||
|
||||
The following example shows how to change a source package that uses GNU
|
||||
configure to enable a new build option to support PNG images:
|
||||
|
||||
|
@ -1308,6 +1211,52 @@ Example: `XBPS_PKG_OPTIONS_xorg_server=opt`.
|
|||
The list of supported package build options and its description is defined in the
|
||||
`common/options.description` file.
|
||||
|
||||
<a id="deps_runtime"></a>
|
||||
#### Runtime dependencies
|
||||
|
||||
Dependencies for ELF objects are detected automatically by `xbps-src`, hence runtime
|
||||
dependencies must not be specified in templates via `$depends` with the following exceptions:
|
||||
|
||||
- ELF objects using dlopen(3).
|
||||
- non ELF objects, i.e perl/python/ruby/etc modules.
|
||||
- Overriding the minimal version specified in the `shlibs` file.
|
||||
|
||||
The runtime dependencies for ELF objects are detected by checking which SONAMEs
|
||||
they require and then the SONAMEs are mapped to a binary package name with a minimal
|
||||
required version. The `shlibs` file in the `void-packages/common` directory
|
||||
sets up the `<SONAME> <pkgname>>=<version>` mappings.
|
||||
|
||||
For example the `foo-1.0_1` package provides the `libfoo.so.1` SONAME and
|
||||
software requiring this library will link to `libfoo`; the resulting binary
|
||||
package will have a run-time dependency to `foo>=1.0_1` package as specified in
|
||||
`common/shlibs`:
|
||||
|
||||
```
|
||||
# common/shlibs
|
||||
...
|
||||
libfoo.so.1 foo-1.0_1
|
||||
...
|
||||
```
|
||||
|
||||
- The first field specifies the SONAME.
|
||||
- The second field specified the package name and minimal version required.
|
||||
- A third optional field (usually set to `ignore`) can be used to skip checks in soname bumps.
|
||||
|
||||
Dependencies declared via `${depends}` are not installed to the master directory, rather are
|
||||
only checked if they exist as binary packages, and are built automatically by `xbps-src` if
|
||||
the specified version is not in the local repository.
|
||||
|
||||
As a special case, `virtual` dependencies may be specified as runtime dependencies in the
|
||||
`${depends}` template variable. Several different packages can provide common functionality by
|
||||
declaring a virtual name and version in the `${provides}` template variable (e.g.,
|
||||
`provides="vpkg-0.1_1"`). Packages that rely on the common functionality without concern for the
|
||||
specific provider can declare a dependency on the virtual package name with the prefix `virtual?`
|
||||
(e.g., `depends="virtual?vpkg-0.1_1"`). When a package is built by `xbps-src`, providers for any
|
||||
virtual packages will be confirmed to exist and will be built if necessary. A map from virtual
|
||||
packages to their default providers is defined in `etc/defaults.virtual`. Individual mappings can be
|
||||
overridden by local preferences in `etc/virtual`. Comments in `etc/defaults.virtual` provide more
|
||||
information on this map.
|
||||
|
||||
<a id="install_remove_files"></a>
|
||||
### INSTALL and REMOVE files
|
||||
|
||||
|
@ -1363,8 +1312,6 @@ Ideally those files should not exceed 80 chars per line.
|
|||
subpackages can also have their own `INSTALL.msg` and `REMOVE.msg` files, simply create them
|
||||
as `srcpkgs/<pkgname>/<subpkg>.INSTALL.msg` or `srcpkgs/<pkgname>/<subpkg>.REMOVE.msg` respectively.
|
||||
|
||||
This should only be used for critical messages, like warning users of breaking changes.
|
||||
|
||||
<a id="runtime_account_creation"></a>
|
||||
### Creating system accounts/groups at runtime
|
||||
|
||||
|
@ -1526,11 +1473,8 @@ destdir (`$DESTDIR`) to the `subpackage` destdir (`$PKGDESTDIR`).
|
|||
Subpackages are processed always in alphabetical order; To force a custom order,
|
||||
the `subpackages` variable can be declared with the wanted order.
|
||||
|
||||
<a id="pkgs_classes"></a>
|
||||
### Some package classes
|
||||
|
||||
<a id="pkgs_development"></a>
|
||||
#### Development packages
|
||||
### Development packages
|
||||
|
||||
A development package, commonly generated as a subpackage, shall only contain
|
||||
files required for development, that is, headers, static libraries, shared
|
||||
|
@ -1560,7 +1504,7 @@ following subset of files from the main package:
|
|||
* Vala bindings `usr/share/vala`
|
||||
|
||||
<a id="pkgs_data"></a>
|
||||
#### Data packages
|
||||
### Data packages
|
||||
|
||||
Another common subpackage type is the `-data` subpackage. This subpackage
|
||||
type used to split architecture independent, big(ger) or huge amounts
|
||||
|
@ -1572,7 +1516,7 @@ The main package must then have `depends="${pkgname}-data-${version}_${revision}
|
|||
possibly in addition to other, non-automatic depends.
|
||||
|
||||
<a id="pkgs_documentation"></a>
|
||||
#### Documentation packages
|
||||
### Documentation packages
|
||||
|
||||
Packages intended for user interaction do not always unconditionally require
|
||||
their documentation part. A user who does not want to e.g. develop
|
||||
|
@ -1587,7 +1531,7 @@ amounts of documentation for no reason. Thus the size of the documentation part
|
|||
be your guidance to decide whether or not to split off a `-doc` subpackage.
|
||||
|
||||
<a id="pkgs_python"></a>
|
||||
#### Python packages
|
||||
### Python packages
|
||||
|
||||
Python packages should be built with the `python{,2,3}-module` build style, if possible.
|
||||
This sets some environment variables required to allow cross compilation. Support to allow
|
||||
|
@ -1630,8 +1574,6 @@ In most cases version is inferred from shebang, install path or build style.
|
|||
Only required for some multi-language
|
||||
applications (e.g., the application is written in C while the command is
|
||||
written in Python) or just single Python file ones that live in `/usr/bin`.
|
||||
If `python_version` is set to `ignore`, python-containing shebangs will not be rewritten.
|
||||
Use this only if a package should not be using a system version of python.
|
||||
|
||||
Also, a set of useful variables are defined to use in the templates:
|
||||
|
||||
|
@ -1650,7 +1592,7 @@ Also, a set of useful variables are defined to use in the templates:
|
|||
python versions.
|
||||
|
||||
<a id="pkgs_go"></a>
|
||||
#### Go packages
|
||||
### Go packages
|
||||
|
||||
Go packages should be built with the `go` build style, if possible.
|
||||
The `go` build style takes care of downloading Go dependencies and
|
||||
|
@ -1684,7 +1626,7 @@ The path to the package's source inside `$GOPATH` is available as
|
|||
`$GOSRCPATH`.
|
||||
|
||||
<a id="pkgs_haskell"></a>
|
||||
#### Haskell packages
|
||||
### Haskell packages
|
||||
|
||||
We build Haskell package using `stack` from
|
||||
[Stackage](http://www.stackage.org/), generally the LTS versions.
|
||||
|
@ -1702,7 +1644,7 @@ The following variables influence how Haskell packages are built:
|
|||
you can add your `--flag ...` parameters there.
|
||||
|
||||
<a id="pkgs_font"></a>
|
||||
#### Font packages
|
||||
### Font packages
|
||||
|
||||
Font packages are very straightforward to write, they are always set with the
|
||||
following variables:
|
||||
|
@ -1959,7 +1901,7 @@ If it is running under another architecture it tries to use the host's `install-
|
|||
utility.
|
||||
|
||||
<a id="triggers_initramfs_regenerate"></a>
|
||||
#### initramfs-regenerate
|
||||
### initramfs-regenerate
|
||||
|
||||
The initramfs-regenerate trigger will trigger the regeneration of all kernel
|
||||
initramfs images after package installation or removal. The trigger must be
|
||||
|
@ -2040,6 +1982,13 @@ During removal it will delete the directory using `rmdir`.
|
|||
To include this trigger use the `make_dirs` variable, as the trigger won't do anything
|
||||
unless it is defined.
|
||||
|
||||
<a id="triggers_openjdk_profile"></a>
|
||||
#### openjdk-profile
|
||||
|
||||
The openjdk-profile trigger is responsible for creating an entry in /etc/profile.d that
|
||||
sets the `JAVA_HOME` environment variable to the currently-selected alternative for
|
||||
`/usr/bin/java` on installation. This trigger must be manually requested.
|
||||
|
||||
<a id="triggers_pango_module"></a>
|
||||
#### pango-modules
|
||||
|
||||
|
@ -2184,7 +2133,7 @@ otherwise the `debug` packages won't have debugging symbols.
|
|||
<a id="contributing"></a>
|
||||
### Contributing via git
|
||||
|
||||
To get started, [fork](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/fork-a-repo) the void-linux `void-packages` git repository on GitHub and clone it:
|
||||
To get started, [fork](https://help.github.com/articles/fork-a-repo) the void-linux `void-packages` git repository on GitHub and clone it:
|
||||
|
||||
$ git clone git@github.com:<user>/void-packages.git
|
||||
|
||||
|
@ -2201,7 +2150,7 @@ to pull in new changes:
|
|||
$ git pull --rebase upstream master
|
||||
|
||||
<a id="help"></a>
|
||||
### Help
|
||||
## Help
|
||||
|
||||
If after reading this `manual` you still need some kind of help, please join
|
||||
us at `#xbps` via IRC at `irc.libera.chat`.
|
||||
|
|
36
README.md
36
README.md
|
@ -87,7 +87,7 @@ Once built, the package will be available in `hostdir/binpkgs` or an appropriate
|
|||
Alternatively, packages can be installed with the `xi` utility, from the `xtools` package. `xi` takes the repository of the current working directory into account.
|
||||
|
||||
```
|
||||
$ xi <package_name>
|
||||
# xi <package_name>
|
||||
```
|
||||
|
||||
<a name="chroot-methods"></a>
|
||||
|
@ -217,7 +217,7 @@ The following directory hierarchy is used with a default configuration file:
|
|||
| |- repocache ...
|
||||
| |- sources ...
|
||||
|
|
||||
|- masterdir-<arch>
|
||||
|- masterdir
|
||||
| |- builddir -> ...
|
||||
| |- destdir -> ...
|
||||
| |- host -> bind mounted from <hostdir>
|
||||
|
@ -226,7 +226,7 @@ The following directory hierarchy is used with a default configuration file:
|
|||
|
||||
The description of these directories is as follows:
|
||||
|
||||
- `masterdir-<arch>`: master directory to be used as rootfs to build/install packages.
|
||||
- `masterdir`: master directory to be used as rootfs to build/install packages.
|
||||
- `builddir`: to unpack package source tarballs and where packages are built.
|
||||
- `destdir`: to install packages, aka **fake destdir**.
|
||||
- `hostdir/ccache`: to store ccache data if the `XBPS_CCACHE` option is enabled.
|
||||
|
@ -331,7 +331,7 @@ And then make a signature per package:
|
|||
If the RSA key was protected with a passphrase you'll have to type it, or alternatively set
|
||||
it via the `XBPS_PASSPHRASE` environment variable.
|
||||
|
||||
Once the binary packages have been signed, check if the repository contains the appropriate `hex fingerprint`:
|
||||
Once the binary packages have been signed, check the repository contains the appropriate `hex fingerprint`:
|
||||
|
||||
$ xbps-query --repository=hostdir/binpkgs -vL
|
||||
...
|
||||
|
@ -340,14 +340,11 @@ Each time a binary package is created, a package signature must be created with
|
|||
|
||||
> It is not possible to sign a repository with multiple RSA keys.
|
||||
|
||||
If packages in `hostdir/binpkgs` are signed, the key in `.plist` format (as imported by xbps) can be placed
|
||||
in `etc/repo-keys/` to prevent xbps-src from prompting to import that key.
|
||||
|
||||
<a name="rebuilding"></a>
|
||||
### Rebuilding and overwriting existing local packages
|
||||
|
||||
Packages are overwritten on every build to make getting package with changed build options easy.
|
||||
To make xbps-src skip build and preserve first package build with given version and revision,
|
||||
To make xbps-src skip build and preserve first package build with with given version and revision,
|
||||
same as in official void repository, set `XBPS_PRESERVE_PKGS=yes` in `etc/conf` file.
|
||||
|
||||
Reinstalling a package in your target `rootdir` can be easily done too:
|
||||
|
@ -362,7 +359,7 @@ the package from the desired repository.
|
|||
<a name="distcc"></a>
|
||||
### Enabling distcc for distributed compilation
|
||||
|
||||
Setup the workers (machines that will compile the code):
|
||||
Setup the slaves (machines that will compile the code):
|
||||
|
||||
# xbps-install -Sy distcc
|
||||
|
||||
|
@ -375,7 +372,7 @@ Enable and start the `distccd` service:
|
|||
# ln -s /etc/sv/distccd /var/service
|
||||
|
||||
Install distcc on the host (machine that executes xbps-src) as well.
|
||||
Unless you want to use the host as worker from other machines, there is no need
|
||||
Unless you want to use the host as slave from other machines, there is no need
|
||||
to modify the configuration.
|
||||
|
||||
On the host you can now enable distcc in the `void-packages/etc/conf` file:
|
||||
|
@ -386,8 +383,8 @@ On the host you can now enable distcc in the `void-packages/etc/conf` file:
|
|||
|
||||
The example values assume a localhost CPU with 4 cores of which at most 2 are used for compiler jobs.
|
||||
The number of slots for preprocessor jobs is set to 24 in order to have enough preprocessed data for other CPUs to compile.
|
||||
The worker 192.168.2.101 has a CPU with 8 cores and the /9 for the number of jobs is a saturating choice.
|
||||
The worker 192.168.2.102 is set to run at most 2 compile jobs to keep its load low, even if its CPU has 4 cores.
|
||||
The slave 192.168.2.101 has a CPU with 8 cores and the /9 for the number of jobs is a saturating choice.
|
||||
The slave 192.168.2.102 is set to run at most 2 compile jobs to keep its load low, even if its CPU has 4 cores.
|
||||
The XBPS_MAKEJOBS setting is increased to 16 to account for the possible parallelism (2 + 9 + 2 + some slack).
|
||||
|
||||
<a name="distfiles-mirrors"></a>
|
||||
|
@ -434,7 +431,7 @@ xbps-src can be used in any recent Linux distribution matching the CPU architect
|
|||
|
||||
To use xbps-src in your Linux distribution use the following instructions. Let's start downloading the xbps static binaries:
|
||||
|
||||
$ wget http://repo-default.voidlinux.org/static/xbps-static-latest.<arch>-musl.tar.xz
|
||||
$ wget http://alpha.de.repo.voidlinux.org/static/xbps-static-latest.<arch>-musl.tar.xz
|
||||
$ mkdir ~/XBPS
|
||||
$ tar xvf xbps-static-latest.<arch>-musl.tar.xz -C ~/XBPS
|
||||
$ export PATH=~/XBPS/usr/bin:$PATH
|
||||
|
@ -450,7 +447,7 @@ and `xbps-src` should be fully functional; just start the `bootstrap` process, i
|
|||
|
||||
$ ./xbps-src binary-bootstrap
|
||||
|
||||
The default masterdir is created in the current working directory, i.e. `void-packages/masterdir-<arch>`, where `<arch>` for the default masterdir is is the native xbps architecture.
|
||||
The default masterdir is created in the current working directory, i.e `void-packages/masterdir`.
|
||||
|
||||
<a name="remaking-masterdir"></a>
|
||||
### Remaking the masterdir
|
||||
|
@ -477,21 +474,20 @@ Two ways are available to build 32bit packages on x86\_64:
|
|||
|
||||
The canonical mode (native) needs a new x86 `masterdir`:
|
||||
|
||||
$ ./xbps-src -A i686 binary-bootstrap
|
||||
$ ./xbps-src -A i686 ...
|
||||
$ ./xbps-src -m masterdir-x86 binary-bootstrap i686
|
||||
$ ./xbps-src -m masterdir-x86 ...
|
||||
|
||||
<a name="building-for-musl"></a>
|
||||
### Building packages natively for the musl C library
|
||||
|
||||
The canonical way of building packages for same architecture but different C library is through a dedicated masterdir by using the host architecture flag `-A`.
|
||||
Canonical way of building packages for same architecture but different C library is through dedicated masterdir.
|
||||
To build for x86_64-musl on glibc x86_64 system, prepare a new masterdir with the musl packages:
|
||||
|
||||
$ ./xbps-src -A x86_64-musl binary-bootstrap
|
||||
$ ./xbps-src -m masterdir-x86_64-musl binary-bootstrap x86_64-musl
|
||||
|
||||
This will create and bootstrap a new masterdir called `masterdir-x86_64-musl` that will be used when `-A x86_64-musl` is specified.
|
||||
Your new masterdir is now ready to build packages natively for the musl C library:
|
||||
|
||||
$ ./xbps-src -A x86_64-musl pkg ...
|
||||
$ ./xbps-src -m masterdir-x86_64-musl pkg ...
|
||||
|
||||
<a name="building-base-system"></a>
|
||||
### Building void base-system from scratch
|
||||
|
|
|
@ -1,86 +0,0 @@
|
|||
# This build helper writes a Meson cross-file, allowing other build styles
|
||||
# to properly drive cross-builds in Meson when appropriate
|
||||
|
||||
# Action is only taken for cross builds
|
||||
[ -z "$CROSS_BUILD" ] && return 0
|
||||
|
||||
# The cross file should only be written once, unless forced
|
||||
[ -e "${XBPS_WRAPPERDIR}/meson/xbps_meson.cross" ] && [ -z "$XBPS_BUILD_FORCEMODE" ] && return 0
|
||||
|
||||
mkdir -p "${XBPS_WRAPPERDIR}/meson"
|
||||
|
||||
_MESON_TARGET_ENDIAN=little
|
||||
# drop the -musl suffix to the target cpu, meson doesn't recognize it
|
||||
_MESON_TARGET_CPU=${XBPS_TARGET_MACHINE/-musl/}
|
||||
case "$XBPS_TARGET_MACHINE" in
|
||||
mips|mips-musl|mipshf-musl)
|
||||
_MESON_TARGET_ENDIAN=big
|
||||
_MESON_CPU_FAMILY=mips
|
||||
;;
|
||||
armv*)
|
||||
_MESON_CPU_FAMILY=arm
|
||||
;;
|
||||
i686*)
|
||||
_MESON_CPU_FAMILY=x86
|
||||
;;
|
||||
ppc64le*)
|
||||
_MESON_CPU_FAMILY=ppc64
|
||||
;;
|
||||
ppc64*)
|
||||
_MESON_TARGET_ENDIAN=big
|
||||
_MESON_CPU_FAMILY=ppc64
|
||||
;;
|
||||
ppcle*)
|
||||
_MESON_CPU_FAMILY=ppc
|
||||
;;
|
||||
ppc*)
|
||||
_MESON_TARGET_ENDIAN=big
|
||||
_MESON_CPU_FAMILY=ppc
|
||||
;;
|
||||
*)
|
||||
# if we reached here that means that the cpu and cpu_family
|
||||
# are the same like 'x86_64' and 'aarch64'
|
||||
_MESON_CPU_FAMILY=${_MESON_TARGET_CPU}
|
||||
;;
|
||||
esac
|
||||
|
||||
# Tell meson to run binaries with qemu if desired
|
||||
_MESON_EXE_WRAPPER=""
|
||||
if [[ "${build_helper}" = *qemu* ]]; then
|
||||
_MESON_EXE_WRAPPER="exe_wrapper = '/usr/bin/qemu-${XBPS_TARGET_QEMU_MACHINE}-static'"
|
||||
fi
|
||||
|
||||
# Record cross-compiling information in cross file.
|
||||
#
|
||||
# CFLAGS, CXXFLAGS and LDFLAGS are not yet available and
|
||||
# will be taken from the environment at configure time.
|
||||
cat > "${XBPS_WRAPPERDIR}/meson/xbps_meson.cross" <<-EOF
|
||||
[binaries]
|
||||
${_MESON_EXE_WRAPPER:-# exe_wrapper is not set}
|
||||
c = '${CC}'
|
||||
cpp = '${CXX}'
|
||||
ar = '${XBPS_CROSS_TRIPLET}-gcc-ar'
|
||||
nm = '${NM}'
|
||||
strip = '${STRIP}'
|
||||
readelf = '${READELF}'
|
||||
objcopy = '${OBJCOPY}'
|
||||
pkg-config = '${PKG_CONFIG}'
|
||||
rust = ['rustc', '--target', '${RUST_TARGET}' ,'--sysroot', '${XBPS_CROSS_BASE}/usr']
|
||||
g-ir-scanner = '${XBPS_CROSS_BASE}/usr/bin/g-ir-scanner'
|
||||
g-ir-compiler = '${XBPS_CROSS_BASE}/usr/bin/g-ir-compiler'
|
||||
g-ir-generate = '${XBPS_CROSS_BASE}/usr/bin/g-ir-generate'
|
||||
llvm-config = '/usr/bin/llvm-config'
|
||||
cups-config = '${XBPS_CROSS_BASE}/usr/bin/cups-config'
|
||||
|
||||
[properties]
|
||||
needs_exe_wrapper = true
|
||||
bindgen_clang_arguments = ['-target', '${XBPS_CROSS_TRIPLET}']
|
||||
|
||||
[host_machine]
|
||||
system = 'linux'
|
||||
cpu_family = '${_MESON_CPU_FAMILY}'
|
||||
cpu = '${_MESON_TARGET_CPU}'
|
||||
endian = '${_MESON_TARGET_ENDIAN}'
|
||||
EOF
|
||||
|
||||
unset _MESON_CPU_FAMILY _MESON_TARGET_CPU _MESON_TARGET_ENDIAN _MESON_EXE_WRAPPER
|
|
@ -11,43 +11,27 @@ if [[ $hostmakedepends != *"python3-numpy"* ]]; then
|
|||
hostmakedepends+=" python3-numpy"
|
||||
fi
|
||||
|
||||
[ -z "$CROSS_BUILD" ] && return 0
|
||||
|
||||
if [[ $makedepends != *"python3-numpy"* ]]; then
|
||||
makedepends+=" python3-numpy"
|
||||
fi
|
||||
|
||||
# python3-setuptools finds numpy libs and headers on the host first;
|
||||
# adding search paths up front allows the target to take priority
|
||||
CFLAGS+=" -I${XBPS_CROSS_BASE}/${py3_sitelib}/numpy/core/include"
|
||||
LDFLAGS+=" -L${XBPS_CROSS_BASE}/${py3_sitelib}/numpy/core/lib"
|
||||
LDFLAGS+=" -L${XBPS_CROSS_BASE}/${py3_sitelib}/numpy/random/lib"
|
||||
|
||||
# distutils from python3-numpy looks to environment variables F77 and
|
||||
# F90 rather than the XBPS-set FC
|
||||
export F77="${FC}"
|
||||
export F90="${FC}"
|
||||
|
||||
# When compiling and linking FORTRAN, distutils from python3-numpy
|
||||
# refuses respect any linker name except "gfortran"; symlink to the
|
||||
# cross-compiler to that the right linker and compiler will be used
|
||||
if _gfortran=$(command -v "${FC}"); then
|
||||
ln -sf "${_gfortran}" "${XBPS_WRAPPERDIR}/gfortran"
|
||||
fi
|
||||
unset _gfortran
|
||||
|
||||
# Write a secondary meson cross file for numpy configuration
|
||||
if [[ "${build_helper}" = *meson* ]]; then
|
||||
_npy_meson_cross="${XBPS_WRAPPERDIR}/meson/xbps_numpy.cross"
|
||||
_cross_py_site="${XBPS_CROSS_BASE}/${py3_sitelib}"
|
||||
|
||||
if [ ! -e "${_npy_meson_cross}" ] || [ -n "$XBPS_BUILD_FORCEMODE" ]; then
|
||||
mkdir -p "${XBPS_WRAPPERDIR}/meson"
|
||||
cat > "${_npy_meson_cross}" <<-EOF
|
||||
[properties]
|
||||
numpy-include-dir = '${_cross_py_site}/numpy/core/include'
|
||||
pythran-include-dir = '${_cross_py_site}/pythran'
|
||||
EOF
|
||||
if [ "$CROSS_BUILD" ]; then
|
||||
if [[ $makedepends != *"python3-numpy"* ]]; then
|
||||
makedepends+=" python3-numpy"
|
||||
fi
|
||||
unset _npy_meson_cross _cross_py_site
|
||||
|
||||
# python3-setuptools finds numpy libs and headers on the host first;
|
||||
# adding search paths up front allows the target to take priority
|
||||
CFLAGS+=" -I${XBPS_CROSS_BASE}/${py3_sitelib}/numpy/core/include"
|
||||
LDFLAGS+=" -L${XBPS_CROSS_BASE}/${py3_sitelib}/numpy/core/lib"
|
||||
LDFLAGS+=" -L${XBPS_CROSS_BASE}/${py3_sitelib}/numpy/random/lib"
|
||||
|
||||
# distutils from python3-numpy looks to environment variables F77 and
|
||||
# F90 rather than the XBPS-set FC
|
||||
export F77="${FC}"
|
||||
export F90="${FC}"
|
||||
|
||||
# When compiling and linking FORTRAN, distutils from python3-numpy
|
||||
# refuses respect any linker name except "gfortran"; symlink to the
|
||||
# cross-compiler to that the right linker and compiler will be used
|
||||
if _gfortran=$(command -v "${FC}"); then
|
||||
ln -sf "${_gfortran}" "${XBPS_WRAPPERDIR}/gfortran"
|
||||
fi
|
||||
unset _gfortran
|
||||
fi
|
||||
|
|
|
@ -25,21 +25,14 @@ if [ "$CROSS_BUILD" ]; then
|
|||
export HOST_CFLAGS="-O2"
|
||||
|
||||
# Crates that use bindgen via build.rs are not cross-aware unless these are set
|
||||
export BINDGEN_EXTRA_CLANG_ARGS+=" --sysroot=${XBPS_CROSS_BASE} -I${XBPS_CROSS_BASE}/usr/include"
|
||||
export BINDGEN_EXTRA_CLANG_ARGS="--sysroot=${XBPS_CROSS_BASE} -I${XBPS_CROSS_BASE}/usr/include"
|
||||
else
|
||||
unset CARGO_BUILD_TARGET
|
||||
fi
|
||||
|
||||
# prevent cargo stripping debug symbols
|
||||
export CARGO_PROFILE_RELEASE_STRIP=false
|
||||
|
||||
# For cross-compiling rust -sys crates
|
||||
export PKG_CONFIG_ALLOW_CROSS=1
|
||||
|
||||
# For cross-compiling pyo3 bindings
|
||||
export PYO3_CROSS_LIB_DIR="${XBPS_CROSS_BASE}/usr/lib"
|
||||
export PYO3_CROSS_INCLUDE_DIR="${XBPS_CROSS_BASE}/usr/include"
|
||||
|
||||
# gettext-rs
|
||||
export GETTEXT_BIN_DIR=/usr/bin
|
||||
export GETTEXT_LIB_DIR="${XBPS_CROSS_BASE}/usr/lib/gettext"
|
||||
|
@ -58,18 +51,3 @@ export OPENSSL_NO_VENDOR=1
|
|||
|
||||
# pcre2-sys, only necessary for musl targets
|
||||
export PCRE2_SYS_STATIC=0
|
||||
|
||||
# zstd-sys
|
||||
export ZSTD_SYS_USE_PKG_CONFIG=1
|
||||
|
||||
# onig-sys
|
||||
export RUSTONIG_SYSTEM_LIBONIG=1
|
||||
|
||||
# libsqlite3-sys
|
||||
export LIBSQLITE3_SYS_USE_PKG_CONFIG=1
|
||||
|
||||
# jemalloc-sys
|
||||
export JEMALLOC_SYS_WITH_LG_PAGE=16
|
||||
|
||||
# libgit2-sys
|
||||
export LIBGIT2_NO_VENDOR=1
|
||||
|
|
|
@ -1,7 +0,0 @@
|
|||
XBPS_TARGET_CFLAGS="-march=rv64imafdc"
|
||||
XBPS_TARGET_CXXFLAGS="$XBPS_TARGET_CFLAGS"
|
||||
XBPS_TARGET_FFLAGS="$XBPS_TARGET_CFLAGS"
|
||||
XBPS_TRIPLET="riscv64-unknown-linux-musl"
|
||||
XBPS_RUST_TARGET="riscv64gc-unknown-linux-musl"
|
||||
XBPS_ZIG_TARGET="riscv64-linux-musl"
|
||||
XBPS_ZIG_CPU="baseline"
|
|
@ -1,7 +0,0 @@
|
|||
XBPS_TARGET_CFLAGS="-march=rv64imafdc"
|
||||
XBPS_TARGET_CXXFLAGS="$XBPS_TARGET_CFLAGS"
|
||||
XBPS_TARGET_FFLAGS="$XBPS_TARGET_CFLAGS"
|
||||
XBPS_TRIPLET="riscv64-unknown-linux-gnu"
|
||||
XBPS_RUST_TARGET="riscv64gc-unknown-linux-gnu"
|
||||
XBPS_ZIG_TARGET="riscv64-linux-gnu"
|
||||
XBPS_ZIG_CPU="baseline"
|
|
@ -5,14 +5,14 @@
|
|||
do_build() {
|
||||
: ${make_cmd:=cargo auditable}
|
||||
|
||||
${make_cmd} build --release --locked --target ${RUST_TARGET} ${configure_args}
|
||||
${make_cmd} build --release --target ${RUST_TARGET} ${configure_args}
|
||||
}
|
||||
|
||||
do_check() {
|
||||
: ${make_cmd:=cargo auditable}
|
||||
|
||||
${make_check_pre} ${make_cmd} test --release --locked --target ${RUST_TARGET} \
|
||||
${configure_args} ${make_check_args}
|
||||
${make_check_pre} ${make_cmd} test --release --target ${RUST_TARGET} ${configure_args} \
|
||||
${make_check_args}
|
||||
}
|
||||
|
||||
do_install() {
|
||||
|
|
|
@ -31,7 +31,6 @@ _EOF
|
|||
ppc64*) _CMAKE_SYSTEM_PROCESSOR=ppc64 ;;
|
||||
ppcle*) _CMAKE_SYSTEM_PROCESSOR=ppcle ;;
|
||||
ppc*) _CMAKE_SYSTEM_PROCESSOR=ppc ;;
|
||||
riscv64*) _CMAKE_SYSTEM_PROCESSOR=riscv64 ;;
|
||||
*) _CMAKE_SYSTEM_PROCESSOR=generic ;;
|
||||
esac
|
||||
cat > cross_${XBPS_CROSS_TRIPLET}.cmake <<_EOF
|
||||
|
@ -40,7 +39,6 @@ SET(CMAKE_SYSTEM_VERSION 1)
|
|||
|
||||
SET(CMAKE_C_COMPILER ${CC})
|
||||
SET(CMAKE_CXX_COMPILER ${CXX})
|
||||
SET(Rust_CARGO_TARGET ${XBPS_CROSS_RUST_TARGET})
|
||||
SET(CMAKE_CROSSCOMPILING TRUE)
|
||||
|
||||
SET(CMAKE_SYSTEM_PROCESSOR ${_CMAKE_SYSTEM_PROCESSOR})
|
||||
|
@ -53,10 +51,10 @@ SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
|||
_EOF
|
||||
cmake_args+=" -DCMAKE_TOOLCHAIN_FILE=${wrksrc}/${build_wrksrc}/${cmake_builddir}/cross_${XBPS_CROSS_TRIPLET}.cmake"
|
||||
fi
|
||||
cmake_args+=" -DCMAKE_INSTALL_PREFIX:PATH=/usr"
|
||||
cmake_args+=" -DCMAKE_INSTALL_PREFIX=/usr"
|
||||
cmake_args+=" -DCMAKE_BUILD_TYPE=None"
|
||||
cmake_args+=" -DCMAKE_INSTALL_LIBDIR:PATH=lib${XBPS_TARGET_WORDSIZE}"
|
||||
cmake_args+=" -DCMAKE_INSTALL_SYSCONFDIR:PATH=/etc"
|
||||
cmake_args+=" -DCMAKE_INSTALL_LIBDIR=lib${XBPS_TARGET_WORDSIZE}"
|
||||
cmake_args+=" -DCMAKE_INSTALL_SYSCONFDIR=/etc"
|
||||
|
||||
if [ "$CROSS_BUILD" ]; then
|
||||
cmake_args+=" -DQT_HOST_PATH=/usr"
|
||||
|
@ -70,7 +68,7 @@ _EOF
|
|||
>> cross_${XBPS_CROSS_TRIPLET}.cmake
|
||||
fi
|
||||
|
||||
cmake_args+=" -DCMAKE_INSTALL_SBINDIR:PATH=bin"
|
||||
cmake_args+=" -DCMAKE_INSTALL_SBINDIR=bin"
|
||||
|
||||
export CMAKE_GENERATOR="${CMAKE_GENERATOR:-Ninja}"
|
||||
# Remove -pipe: https://gitlab.kitware.com/cmake/cmake/issues/19590
|
||||
|
|
|
@ -32,16 +32,6 @@ do_build() {
|
|||
go_package=${go_package:-$go_import_path}
|
||||
# Build using Go modules if there's a go.mod file
|
||||
if [ "${go_mod_mode}" != "off" ] && [ -f go.mod ]; then
|
||||
|
||||
if [[ -n "${_go_mod_path}" ]]; then
|
||||
pushd $(dirname ${_go_mod_path})
|
||||
fi
|
||||
|
||||
# Check if go_import_path matches module
|
||||
if [ "module $go_import_path" != "$(grep '^module' go.mod | head -n1)" ]; then
|
||||
msg_error "\"\$go_import_path\" doesn't match the one defined in go.mod!\n"
|
||||
fi
|
||||
|
||||
if [ -z "${go_mod_mode}" ] && [ -d vendor ]; then
|
||||
msg_normal "Using vendor dir for $pkgname Go dependencies.\n"
|
||||
go_mod_mode=vendor
|
||||
|
@ -50,13 +40,10 @@ do_build() {
|
|||
# default behavior.
|
||||
go_mod_mode=
|
||||
fi
|
||||
go install -p "$XBPS_MAKEJOBS" -mod="${go_mod_mode}" -modcacherw -v -tags "${go_build_tags}" -ldflags "${go_ldflags}" ${go_package}
|
||||
if [[ -n "${_go_mod_path}" ]]; then
|
||||
popd
|
||||
fi
|
||||
go install -p "$XBPS_MAKEJOBS" -mod="${go_mod_mode}" -x -tags "${go_build_tags}" -ldflags "${go_ldflags}" ${go_package}
|
||||
else
|
||||
# Otherwise, build using GOPATH
|
||||
go install -p "$XBPS_MAKEJOBS" -v -tags "${go_build_tags}" -ldflags "${go_ldflags}" ${go_package}
|
||||
go get -p "$XBPS_MAKEJOBS" -x -tags "${go_build_tags}" -ldflags "${go_ldflags}" ${go_package}
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
|
@ -1,11 +1,94 @@
|
|||
#
|
||||
# This helper is for templates using meson.
|
||||
#
|
||||
do_patch() {
|
||||
: ${meson_crossfile:=xbps_meson.cross}
|
||||
|
||||
if [ "$CROSS_BUILD" ]; then
|
||||
_MESON_TARGET_ENDIAN=little
|
||||
# drop the -musl suffix to the target cpu, meson doesn't recognize it
|
||||
_MESON_TARGET_CPU=${XBPS_TARGET_MACHINE/-musl/}
|
||||
case "$XBPS_TARGET_MACHINE" in
|
||||
mips|mips-musl|mipshf-musl)
|
||||
_MESON_TARGET_ENDIAN=big
|
||||
_MESON_CPU_FAMILY=mips
|
||||
;;
|
||||
armv*)
|
||||
_MESON_CPU_FAMILY=arm
|
||||
;;
|
||||
i686*)
|
||||
_MESON_CPU_FAMILY=x86
|
||||
;;
|
||||
ppc64le*)
|
||||
_MESON_CPU_FAMILY=ppc64
|
||||
;;
|
||||
ppc64*)
|
||||
_MESON_TARGET_ENDIAN=big
|
||||
_MESON_CPU_FAMILY=ppc64
|
||||
;;
|
||||
ppcle*)
|
||||
_MESON_CPU_FAMILY=ppc
|
||||
;;
|
||||
ppc*)
|
||||
_MESON_TARGET_ENDIAN=big
|
||||
_MESON_CPU_FAMILY=ppc
|
||||
;;
|
||||
*)
|
||||
# if we reached here that means that the cpu and cpu_family
|
||||
# are the same like 'x86_64' and 'aarch64'
|
||||
_MESON_CPU_FAMILY=${_MESON_TARGET_CPU}
|
||||
;;
|
||||
esac
|
||||
|
||||
# Record cross-compiling information in cross file.
|
||||
# CFLAGS and LDFLAGS must be set as c_args and c_link_args.
|
||||
cat > ${meson_crossfile} <<EOF
|
||||
[binaries]
|
||||
c = '${CC}'
|
||||
cpp = '${CXX}'
|
||||
ar = '${XBPS_CROSS_TRIPLET}-gcc-ar'
|
||||
nm = '${NM}'
|
||||
ld = '${LD}'
|
||||
strip = '${STRIP}'
|
||||
readelf = '${READELF}'
|
||||
objcopy = '${OBJCOPY}'
|
||||
pkgconfig = '${PKG_CONFIG}'
|
||||
rust = ['rustc', '--target', '${RUST_TARGET}' ,'--sysroot', '${XBPS_CROSS_BASE}/usr']
|
||||
g-ir-scanner = '${XBPS_CROSS_BASE}/usr/bin/g-ir-scanner'
|
||||
g-ir-compiler = '${XBPS_CROSS_BASE}/usr/bin/g-ir-compiler'
|
||||
g-ir-generate = '${XBPS_CROSS_BASE}/usr/bin/g-ir-generate'
|
||||
llvm-config = '/usr/bin/llvm-config'
|
||||
cups-config = '${XBPS_CROSS_BASE}/usr/bin/cups-config'
|
||||
|
||||
[properties]
|
||||
needs_exe_wrapper = true
|
||||
|
||||
[built-in options]
|
||||
c_args = ['$(echo ${CFLAGS} | sed -r "s/\s+/','/g")']
|
||||
c_link_args = ['$(echo ${LDFLAGS} | sed -r "s/\s+/','/g")']
|
||||
|
||||
cpp_args = ['$(echo ${CXXFLAGS} | sed -r "s/\s+/','/g")']
|
||||
cpp_link_args = ['$(echo ${LDFLAGS} | sed -r "s/\s+/','/g")']
|
||||
|
||||
[host_machine]
|
||||
system = 'linux'
|
||||
cpu_family = '${_MESON_CPU_FAMILY}'
|
||||
cpu = '${_MESON_TARGET_CPU}'
|
||||
endian = '${_MESON_TARGET_ENDIAN}'
|
||||
EOF
|
||||
if [[ $build_helper = *"qemu"* ]]; then
|
||||
sed -e "/\[binaries\]/ a exe_wrapper = '/usr/bin/qemu-${XBPS_TARGET_QEMU_MACHINE}-static'" \
|
||||
-i ${meson_crossfile}
|
||||
fi
|
||||
|
||||
unset _MESON_CPU_FAMILY _MESON_TARGET_CPU _MESON_TARGET_ENDIAN
|
||||
fi
|
||||
}
|
||||
|
||||
do_configure() {
|
||||
: ${meson_cmd:=meson}
|
||||
: ${meson_builddir:=build}
|
||||
: ${meson_crossfile:="${XBPS_WRAPPERDIR}/meson/xbps_meson.cross"}
|
||||
: ${meson_crossfile:=xbps_meson.cross}
|
||||
|
||||
if [ "$CROSS_BUILD" ]; then
|
||||
configure_args+=" --cross-file=${meson_crossfile}"
|
||||
|
|
96
common/build-style/python-module.sh
Normal file
96
common/build-style/python-module.sh
Normal file
|
@ -0,0 +1,96 @@
|
|||
#
|
||||
# This helper is for templates installing python modules.
|
||||
#
|
||||
|
||||
do_build() {
|
||||
: ${python_versions:="2.7 $py3_ver"}
|
||||
local pyver= tmp_cflags="$CFLAGS" tmp_ldflags="$LDFLAGS"
|
||||
|
||||
for pyver in $python_versions; do
|
||||
if [ -n "$CROSS_BUILD" ]; then
|
||||
CFLAGS="$tmp_cflags"
|
||||
LDFLAGS="$tmp_ldflags"
|
||||
ADDENV=
|
||||
|
||||
PYPREFIX="$XBPS_CROSS_BASE"
|
||||
CFLAGS+=" -I${XBPS_CROSS_BASE}/include/python${pyver} -I${XBPS_CROSS_BASE}/usr/include"
|
||||
LDFLAGS+=" -L${XBPS_CROSS_BASE}/lib/python${pyver} -L${XBPS_CROSS_BASE}/usr/lib"
|
||||
CC="${XBPS_CROSS_TRIPLET}-gcc -pthread $CFLAGS $LDFLAGS"
|
||||
LDSHARED="${CC} -shared $LDFLAGS"
|
||||
case $pyver in
|
||||
3.*)
|
||||
for f in ${XBPS_CROSS_BASE}/${py3_lib}/_sysconfigdata_*; do
|
||||
f=${f##*/}
|
||||
_PYTHON_SYSCONFIGDATA_NAME=${f%.py}
|
||||
done
|
||||
ADDENV+=" PYTHONPATH=${XBPS_CROSS_BASE}/${py3_lib}"
|
||||
ADDENV+=" _PYTHON_SYSCONFIGDATA_NAME="$_PYTHON_SYSCONFIGDATA_NAME""
|
||||
esac
|
||||
env CC="$CC" LDSHARED="$LDSHARED" $ADDENV \
|
||||
PYPREFIX="$PYPREFIX" CFLAGS="$CFLAGS" \
|
||||
LDFLAGS="$LDFLAGS" python${pyver} setup.py \
|
||||
build --build-base=build-${pyver} ${make_build_args}
|
||||
else
|
||||
python${pyver} setup.py build --build-base=build-${pyver} ${make_build_args}
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
||||
do_check() {
|
||||
: ${python_versions:="2.7 $py3_ver"}
|
||||
|
||||
for pyver in $python_versions; do
|
||||
ln -s build-${pyver} build
|
||||
if [ -z "$make_check_target" ]; then
|
||||
if ! python${pyver} setup.py --help test >/dev/null 2>&1; then
|
||||
msg_warn "No command 'test' defined by setup.py for python${pyver}.\n"
|
||||
rm build
|
||||
return 0
|
||||
fi
|
||||
fi
|
||||
|
||||
${make_check_pre} python${pyver} setup.py ${make_check_target:-test} ${make_check_args}
|
||||
rm build
|
||||
done
|
||||
}
|
||||
|
||||
do_install() {
|
||||
: ${python_versions:="2.7 $py3_ver"}
|
||||
local pyver=
|
||||
|
||||
for pyver in $python_versions; do
|
||||
if [ -n "$CROSS_BUILD" ]; then
|
||||
ADDENV=
|
||||
PYPREFIX="$XBPS_CROSS_BASE"
|
||||
CFLAGS+=" -I${XBPS_CROSS_BASE}/include/python${pyver} -I${XBPS_CROSS_BASE}/usr/include"
|
||||
LDFLAGS+=" -L${XBPS_CROSS_BASE}/lib/python${pyver} -L${XBPS_CROSS_BASE}/usr/lib"
|
||||
CC="${XBPS_CROSS_TRIPLET}-gcc -pthread $CFLAGS $LDFLAGS"
|
||||
LDSHARED="${CC} -shared $LDFLAGS"
|
||||
case $pyver in
|
||||
3.*)
|
||||
for f in ${XBPS_CROSS_BASE}/${py3_lib}/_sysconfigdata_*; do
|
||||
f=${f##*/}
|
||||
_PYTHON_SYSCONFIGDATA_NAME=${f%.py}
|
||||
done
|
||||
ADDENV+=" PYTHONPATH=${XBPS_CROSS_BASE}/${py3_lib}"
|
||||
ADDENV+=" _PYTHON_SYSCONFIGDATA_NAME="$_PYTHON_SYSCONFIGDATA_NAME""
|
||||
esac
|
||||
env CC="$CC" LDSHARED="$LDSHARED" $ADDENV \
|
||||
PYPREFIX="$PYPREFIX" CFLAGS="$CFLAGS" \
|
||||
LDFLAGS="$LDFLAGS" python${pyver} setup.py \
|
||||
build --build-base=build-${pyver} \
|
||||
install --prefix=/usr --root=${DESTDIR} ${make_install_args}
|
||||
else
|
||||
python${pyver} setup.py build --build-base=build-${pyver} \
|
||||
install --prefix=/usr --root=${DESTDIR} ${make_install_args}
|
||||
fi
|
||||
|
||||
# Rename unversioned scripts to avoid name conflicts.
|
||||
if [ -d ${DESTDIR}/usr/bin ]; then
|
||||
find ${DESTDIR}/usr/bin -type f ! -name "*[[:digit:]]" | while IFS= read -r f _; do
|
||||
mv "${f}" "${f}${pyver%.*}"
|
||||
echo "[python-module] Unversioned script renamed to '${f#$DESTDIR}${pyver%.*}'"
|
||||
done
|
||||
fi
|
||||
done
|
||||
}
|
|
@ -12,7 +12,7 @@ do_check() {
|
|||
if python3 -c 'import xdist' >/dev/null 2>&1; then
|
||||
testjobs="-n $XBPS_MAKEJOBS"
|
||||
fi
|
||||
PYTHONPATH="$(cd build/lib* && pwd)" PY_IGNORE_IMPORTMISMATCH=1 \
|
||||
PYTHONPATH="$(cd build/lib* && pwd)" \
|
||||
${make_check_pre} \
|
||||
python3 -m pytest ${testjobs} ${make_check_args} ${make_check_target}
|
||||
else
|
||||
|
|
|
@ -4,42 +4,29 @@
|
|||
|
||||
do_build() {
|
||||
: ${make_build_target:=.}
|
||||
|
||||
if [ "${CROSS_BUILD}" ] && [[ "${build_helper}" = *meson* ]]; then
|
||||
local mcross="-Csetup-args=--cross-file=${XBPS_WRAPPERDIR}/meson"
|
||||
make_build_args+=" ${mcross}/xbps_meson.cross"
|
||||
|
||||
if [[ "${build_helper}" = *numpy* ]]; then
|
||||
make_build_args+=" ${mcross}/xbps_numpy.cross"
|
||||
fi
|
||||
fi
|
||||
|
||||
python3 -m build --no-isolation --wheel \
|
||||
${make_build_args} ${make_build_target}
|
||||
: ${make_build_args:=--no-isolation --wheel}
|
||||
python3 -m build ${make_build_args} ${make_build_target}
|
||||
}
|
||||
|
||||
do_check() {
|
||||
if ! python3 -c 'import pytest' >/dev/null 2>&1; then
|
||||
msg_warn "Testing of python3-pep517 templates requires pytest\n"
|
||||
local testjobs
|
||||
if python3 -c 'import pytest' >/dev/null 2>&1; then
|
||||
if python3 -c 'import xdist' >/dev/null 2>&1; then
|
||||
testjobs="-n $XBPS_MAKEJOBS"
|
||||
fi
|
||||
${make_check_pre} python3 -m pytest ${testjobs} ${make_check_args} ${make_check_target}
|
||||
else
|
||||
msg_warn "Unable to determine tests for PEP517 Python templates\n"
|
||||
return 0
|
||||
fi
|
||||
|
||||
local testjobs
|
||||
if python3 -c 'import xdist' >/dev/null 2>&1; then
|
||||
testjobs="-n $XBPS_MAKEJOBS"
|
||||
fi
|
||||
|
||||
local testdir="${wrksrc}/.xbps-testdir/$(date +%s)"
|
||||
python3 -m installer --destdir "${testdir}" \
|
||||
${make_install_args} ${make_install_target:-dist/*.whl}
|
||||
|
||||
PATH="${testdir}/usr/bin:${PATH}" PYTHONPATH="${testdir}/${py3_sitelib}" PY_IGNORE_IMPORTMISMATCH=1 \
|
||||
${make_check_pre} pytest3 ${testjobs} ${make_check_args} ${make_check_target}
|
||||
}
|
||||
|
||||
do_install() {
|
||||
: ${make_install_args:=--no-compile-bytecode}
|
||||
: ${make_install_target:="dist/*.whl"}
|
||||
if [ -z "${make_install_target}" ]; then
|
||||
# Default wheel name normalizes hyphens to underscores
|
||||
local wheelbase="${pkgname#python3-}"
|
||||
make_install_target="dist/${wheelbase//-/_}-${version}-*-*-*.whl"
|
||||
fi
|
||||
|
||||
python3 -m installer --destdir ${DESTDIR} \
|
||||
${make_install_args} ${make_install_target}
|
||||
|
|
|
@ -4,23 +4,13 @@
|
|||
do_configure() {
|
||||
local qmake
|
||||
local qmake_args
|
||||
local qt=${QT:-}
|
||||
local builddir="${wrksrc}/${build_wrksrc}"
|
||||
cd ${builddir}
|
||||
if [ "${QT}" ]; then
|
||||
qt=${QT}
|
||||
if [ ! -x "/usr/lib/${qt}/bin/qmake" ]; then
|
||||
msg_error "${QT} is requested, but not found\n"
|
||||
fi
|
||||
elif [ -x "/usr/lib/qt5/bin/qmake" ]; then
|
||||
qt="qt5"
|
||||
elif [ -x "/usr/lib/qt6/bin/qmake" ]; then
|
||||
qt="qt6"
|
||||
else
|
||||
if [ -x "/usr/lib/qt5/bin/qmake" ]; then
|
||||
qmake="/usr/lib/qt5/bin/qmake"
|
||||
fi
|
||||
if [ -z "${qmake}" ]; then
|
||||
msg_error "${pkgver}: Could not find qmake - missing in hostmakedepends?\n"
|
||||
fi
|
||||
qmake="/usr/lib/${qt}/bin/qmake"
|
||||
if [ "$CROSS_BUILD" ]; then
|
||||
if [ "$CROSS_BUILD" ] && [ "$qmake" == "/usr/lib/qt5/bin/qmake" ]; then
|
||||
case $XBPS_TARGET_MACHINE in
|
||||
i686*) _qt_arch=i386;;
|
||||
x86_64*) _qt_arch=x86_64;;
|
||||
|
@ -30,19 +20,19 @@ do_configure() {
|
|||
ppc64*) _qt_arch=power64;;
|
||||
ppc*) _qt_arch=power;;
|
||||
esac
|
||||
mkdir -p "${builddir}/.target-spec/linux-g++"
|
||||
cat > "${builddir}/.target-spec/linux-g++/qmake.conf" <<_EOF
|
||||
mkdir -p "${wrksrc}/.target-spec/linux-g++"
|
||||
cat > "${wrksrc}/.target-spec/linux-g++/qmake.conf" <<_EOF
|
||||
MAKEFILE_GENERATOR = UNIX
|
||||
CONFIG += incremental no_qt_rpath
|
||||
QMAKE_INCREMENTAL_STYLE = sublib
|
||||
|
||||
include(/usr/lib/${qt}/mkspecs/common/linux.conf)
|
||||
include(/usr/lib/${qt}/mkspecs/common/gcc-base-unix.conf)
|
||||
include(/usr/lib/${qt}/mkspecs/common/g++-unix.conf)
|
||||
include(/usr/lib/qt5/mkspecs/common/linux.conf)
|
||||
include(/usr/lib/qt5/mkspecs/common/gcc-base-unix.conf)
|
||||
include(/usr/lib/qt5/mkspecs/common/g++-unix.conf)
|
||||
|
||||
QMAKE_TARGET_CONFIG = ${XBPS_CROSS_BASE}/usr/lib/${qt}/mkspecs/qconfig.pri
|
||||
QMAKE_TARGET_MODULE = ${XBPS_CROSS_BASE}/usr/lib/${qt}/mkspecs/qmodule.pri
|
||||
QMAKEMODULES = ${XBPS_CROSS_BASE}/usr/lib/${qt}/mkspecs/modules
|
||||
QMAKE_TARGET_CONFIG = ${XBPS_CROSS_BASE}/usr/lib/qt5/mkspecs/qconfig.pri
|
||||
QMAKE_TARGET_MODULE = ${XBPS_CROSS_BASE}/usr/lib/qt5/mkspecs/qmodule.pri
|
||||
QMAKEMODULES = ${XBPS_CROSS_BASE}/usr/lib/qt5/mkspecs/modules
|
||||
QMAKE_CC = ${CC}
|
||||
QMAKE_CXX = ${CXX}
|
||||
QMAKE_LINK = ${CXX}
|
||||
|
@ -59,20 +49,20 @@ QMAKE_CXXFLAGS = ${CXXFLAGS}
|
|||
QMAKE_LFLAGS = ${LDFLAGS}
|
||||
load(qt_config)
|
||||
_EOF
|
||||
echo "#include \"${XBPS_CROSS_BASE}/usr/lib/${qt}/mkspecs/linux-g++/qplatformdefs.h\"" > "${builddir}/.target-spec/linux-g++/qplatformdefs.h"
|
||||
echo "#include \"${XBPS_CROSS_BASE}/usr/lib/qt5/mkspecs/linux-g++/qplatformdefs.h\"" > "${wrksrc}/.target-spec/linux-g++/qplatformdefs.h"
|
||||
|
||||
mkdir -p "${builddir}/.host-spec/linux-g++"
|
||||
cat > "${builddir}/.host-spec/linux-g++/qmake.conf" <<_EOF
|
||||
mkdir -p "${wrksrc}/.host-spec/linux-g++"
|
||||
cat > "${wrksrc}/.host-spec/linux-g++/qmake.conf" <<_EOF
|
||||
MAKEFILE_GENERATOR = UNIX
|
||||
CONFIG += incremental no_qt_rpath
|
||||
QMAKE_INCREMENTAL_STYLE = sublib
|
||||
|
||||
include(/usr/lib/${qt}/mkspecs/common/linux.conf)
|
||||
include(/usr/lib/${qt}/mkspecs/common/gcc-base-unix.conf)
|
||||
include(/usr/lib/${qt}/mkspecs/common/g++-unix.conf)
|
||||
include(/usr/lib/qt5/mkspecs/common/linux.conf)
|
||||
include(/usr/lib/qt5/mkspecs/common/gcc-base-unix.conf)
|
||||
include(/usr/lib/qt5/mkspecs/common/g++-unix.conf)
|
||||
|
||||
QMAKE_TARGET_CONFIG = ${XBPS_CROSS_BASE}/usr/lib/${qt}/mkspecs/qconfig.pri
|
||||
QMAKE_TARGET_MODULE = ${XBPS_CROSS_BASE}/usr/lib/${qt}/mkspecs/qmodule.pri
|
||||
QMAKE_TARGET_CONFIG = ${XBPS_CROSS_BASE}/usr/lib/qt5/mkspecs/qconfig.pri
|
||||
QMAKE_TARGET_MODULE = ${XBPS_CROSS_BASE}/usr/lib/qt5/mkspecs/qmodule.pri
|
||||
QMAKE_CC = ${CC_host}
|
||||
QMAKE_CXX = ${CXX_host}
|
||||
QMAKE_LINK = ${CXX_host}
|
||||
|
@ -89,34 +79,33 @@ QMAKE_CXXFLAGS = ${CXXFLAGS_host}
|
|||
QMAKE_LFLAGS = ${LDFLAGS_host}
|
||||
load(qt_config)
|
||||
_EOF
|
||||
echo '#include "/usr/lib/${qt}/mkspecs/linux-g++/qplatformdefs.h"' > "${builddir}/.host-spec/linux-g++/qplatformdefs.h"
|
||||
cat > "${builddir}/qt.conf" <<_EOF
|
||||
echo '#include "/usr/lib/qt5/mkspecs/linux-g++/qplatformdefs.h"' > "${wrksrc}/.host-spec/linux-g++/qplatformdefs.h"
|
||||
cat > "${wrksrc}/qt.conf" <<_EOF
|
||||
[Paths]
|
||||
Sysroot=${XBPS_CROSS_BASE}
|
||||
Prefix=/usr
|
||||
ArchData=${XBPS_CROSS_BASE}/usr/lib/${qt}
|
||||
Data=${XBPS_CROSS_BASE}/usr/share/${qt}
|
||||
Documentation=${XBPS_CROSS_BASE}/usr/share/doc/${qt}
|
||||
Headers=${XBPS_CROSS_BASE}/usr/include/${qt}
|
||||
ArchData=${XBPS_CROSS_BASE}/usr/lib/qt5
|
||||
Data=${XBPS_CROSS_BASE}/usr/share/qt5
|
||||
Documentation=${XBPS_CROSS_BASE}/usr/share/doc/qt5
|
||||
Headers=${XBPS_CROSS_BASE}/usr/include/qt5
|
||||
Libraries=${XBPS_CROSS_BASE}/usr/lib
|
||||
LibraryExecutables=/usr/lib/${qt}/libexec
|
||||
Binaries=/usr/lib/${qt}/bin
|
||||
LibraryExecutables=/usr/lib/qt5/libexec
|
||||
Binaries=/usr/lib/qt5/bin
|
||||
Tests=${XBPS_CROSS_BASE}/usr/tests
|
||||
Plugins=/usr/lib/${qt}/plugins
|
||||
Imports=${XBPS_CROSS_BASE}/usr/lib/${qt}/imports
|
||||
Qml2Imports=${XBPS_CROSS_BASE}/usr/lib/${qt}/qml
|
||||
Translations=${XBPS_CROSS_BASE}/usr/share/${qt}/translations
|
||||
Plugins=/usr/lib/qt5/plugins
|
||||
Imports=${XBPS_CROSS_BASE}/usr/lib/qt5/imports
|
||||
Qml2Imports=${XBPS_CROSS_BASE}/usr/lib/qt5/qml
|
||||
Translations=${XBPS_CROSS_BASE}/usr/share/qt5/translations
|
||||
Settings=${XBPS_CROSS_BASE}/etc/xdg
|
||||
Examples=${XBPS_CROSS_BASE}/usr/share/${qt}/examples
|
||||
Examples=${XBPS_CROSS_BASE}/usr/share/qt5/examples
|
||||
HostPrefix=/usr
|
||||
HostData=/usr/lib/${qt}
|
||||
HostBinaries=/usr/lib/${qt}/bin
|
||||
HostData=/usr/lib/qt5
|
||||
HostBinaries=/usr/lib/qt5/bin
|
||||
HostLibraries=/usr/lib
|
||||
HostLibraryExecutables=/usr/lib/${qt}/libexec
|
||||
Spec=${builddir}/.host-spec/linux-g++
|
||||
TargetSpec=${builddir}/.target-spec/linux-g++
|
||||
Spec=${wrksrc}/.host-spec/linux-g++
|
||||
TargetSpec=${wrksrc}/.target-spec/linux-g++
|
||||
_EOF
|
||||
qmake_args="-qtconf ${builddir}/qt.conf PKG_CONFIG_EXECUTABLE=${XBPS_WRAPPERDIR}/${PKG_CONFIG}"
|
||||
qmake_args="-qtconf ${wrksrc}/qt.conf PKG_CONFIG_EXECUTABLE=${XBPS_WRAPPERDIR}/${PKG_CONFIG}"
|
||||
${qmake} ${qmake_args} \
|
||||
PREFIX=/usr \
|
||||
QT_INSTALL_PREFIX=/usr \
|
||||
|
@ -139,7 +128,6 @@ _EOF
|
|||
}
|
||||
|
||||
do_build() {
|
||||
cd "${wrksrc}/${build_wrksrc}"
|
||||
: ${make_cmd:=make}
|
||||
|
||||
${make_cmd} ${makejobs} ${make_build_args} ${make_build_target} \
|
||||
|
@ -147,7 +135,6 @@ do_build() {
|
|||
}
|
||||
|
||||
do_install() {
|
||||
cd "${wrksrc}/${build_wrksrc}"
|
||||
: ${make_cmd:=make}
|
||||
: ${make_install_target:=install}
|
||||
|
||||
|
|
|
@ -3,11 +3,14 @@ do_build() {
|
|||
# Extract the source files
|
||||
mkdir -p "build/usr/share/texmf-dist"
|
||||
find . -maxdepth 1 -print -name "*.tar.xz" \
|
||||
-exec bsdtar \
|
||||
-s '|^texmf-dist/||' \
|
||||
-C "build/usr/share/texmf-dist" \
|
||||
-xf {} \;
|
||||
-exec bsdtar -C "build/usr/share/texmf-dist" -xf {} \;
|
||||
cd "build/usr/share/texmf-dist/"
|
||||
# Everything in usr/share/texmf-dist/texmf-dist should really be in
|
||||
# usr/share/texmf-dist, so we move it
|
||||
if [ -d "texmf-dist" ] ; then
|
||||
rsync -ar texmf-dist/ ./
|
||||
rm -rf texmf-dist/
|
||||
fi
|
||||
# LICENSEs are unneeded
|
||||
rm -f LICENSE*
|
||||
|
||||
|
|
|
@ -53,7 +53,6 @@ _void_cross_build_binutils() {
|
|||
--sbindir=/usr/bin \
|
||||
--libdir=/usr/lib \
|
||||
--libexecdir=/usr/lib \
|
||||
--sysconfdir=/etc \
|
||||
--target=${tgt} \
|
||||
--with-sysroot=/usr/${tgt} \
|
||||
--disable-nls \
|
||||
|
@ -61,9 +60,7 @@ _void_cross_build_binutils() {
|
|||
--disable-multilib \
|
||||
--disable-werror \
|
||||
--disable-gold \
|
||||
--disable-gprofng \
|
||||
--enable-relro \
|
||||
--enable-new-dtags \
|
||||
--enable-plugins \
|
||||
--enable-64-bit-bfd \
|
||||
--enable-deterministic-archives \
|
||||
|
@ -134,8 +131,7 @@ _void_cross_build_bootstrap_gcc() {
|
|||
--disable-libmudflap \
|
||||
--disable-libssp \
|
||||
--disable-libitm \
|
||||
--disable-libatomic --disable-autolink-libatomic \
|
||||
--disable-gcov \
|
||||
--disable-libatomic \
|
||||
--disable-threads \
|
||||
--disable-sjlj-exceptions \
|
||||
--enable-languages=c \
|
||||
|
@ -264,10 +260,9 @@ _void_cross_build_glibc() {
|
|||
|
||||
CC="${tgt}-gcc" CXX="${tgt}-g++" CPP="${tgt}-cpp" LD="${tgt}-ld" \
|
||||
AR="${tgt}-ar" AS="${tgt}-as" NM="${tgt}-nm" \
|
||||
OBJDUMP="${tgt}-objdump" OBJCOPY="${tgt}-objcopy" \
|
||||
CFLAGS="-pipe ${cross_glibc_cflags}" \
|
||||
CXXFLAGS="-pipe ${cross_glibc_cflags}" \
|
||||
CPPFLAGS="" \
|
||||
CPPFLAGS="${cross_glibc_cflags}" \
|
||||
LDFLAGS="${cross_glibc_ldflags}" \
|
||||
../glibc-${ver}/configure \
|
||||
--prefix=/usr \
|
||||
|
@ -320,14 +315,6 @@ _void_cross_build_musl() {
|
|||
make ${makejobs}
|
||||
make DESTDIR=${wrksrc}/build_root/usr/${tgt} install
|
||||
|
||||
CFLAGS="-pipe -fPIC ${cross_musl_cflags}" \
|
||||
CPPFLAGS="${cross_musl_cflags}" LDFLAGS="${cross_musl_ldflags}" \
|
||||
${tgt}-gcc -pipe -fPIC ${cross_musl_cflags} ${cross_musl_ldflags} -fpie \
|
||||
-c ${XBPS_SRCPKGDIR}/musl/files/__stack_chk_fail_local.c \
|
||||
-o __stack_chk_fail_local.o
|
||||
${tgt}-ar r libssp_nonshared.a __stack_chk_fail_local.o
|
||||
cp libssp_nonshared.a ${wrksrc}/build_root/usr/${tgt}/usr/lib
|
||||
|
||||
touch ${wrksrc}/.musl_build_done
|
||||
}
|
||||
|
||||
|
@ -378,10 +365,6 @@ _void_cross_build_gcc() {
|
|||
|
||||
msg_normal "Building gcc for ${tgt}\n"
|
||||
|
||||
# GIANT HACK: create an empty libatomic.a so gcc cross-compile
|
||||
# below works.
|
||||
ar r ${wrksrc}/build_root/usr/${tgt}/usr/lib/libatomic.a
|
||||
|
||||
mkdir -p ${wrksrc}/gcc_build
|
||||
cd ${wrksrc}/gcc_build
|
||||
|
||||
|
@ -398,14 +381,18 @@ _void_cross_build_gcc() {
|
|||
extra_args+=" --disable-gnu-unique-object"
|
||||
extra_args+=" libat_cv_have_ifunc=no"
|
||||
else
|
||||
extra_args+=" --enable-clocale=gnu"
|
||||
extra_args+=" --enable-gnu-unique-object"
|
||||
fi
|
||||
|
||||
# note on --disable-libquadmath:
|
||||
# on some platforms the library is actually necessary for the
|
||||
# fortran frontend to build, platforms where this is a problem
|
||||
# should explicitly force libquadmath to be on via cross_gcc_configure_args
|
||||
# fortran frontend to build, but still disable it because it
|
||||
# should not be in the resulting packages; it conflicts with
|
||||
# the libquadmath you can install into the cross root
|
||||
#
|
||||
# platforms where this is a problem should explicitly force
|
||||
# libquadmath to be on via cross_gcc_configure_args, the
|
||||
# do_install in this build-style automatically removes it
|
||||
#
|
||||
../gcc-${ver}/configure \
|
||||
--prefix=/usr \
|
||||
|
@ -425,7 +412,6 @@ _void_cross_build_gcc() {
|
|||
--disable-libvtv \
|
||||
--disable-libsanitizer \
|
||||
--disable-libstdcxx-pch \
|
||||
--disable-libssp \
|
||||
--enable-shared \
|
||||
--enable-threads=posix \
|
||||
--enable-__cxa_atexit \
|
||||
|
@ -434,6 +420,7 @@ _void_cross_build_gcc() {
|
|||
--enable-lto \
|
||||
--enable-default-pie \
|
||||
--enable-default-ssp \
|
||||
--enable-libssp \
|
||||
--with-gnu-ld \
|
||||
--with-gnu-as \
|
||||
--with-linker-hash-style=gnu \
|
||||
|
@ -473,14 +460,6 @@ do_build() {
|
|||
local binutils_ver linux_ver gcc_ver libc_ver libucontext_ver
|
||||
local tgt=${sourcepkg/cross-}
|
||||
|
||||
export CFLAGS="${CFLAGS/-D_FORTIFY_SOURCE=2/}"
|
||||
export CXXFLAGS="${CXXFLAGS/-D_FORTIFY_SOURCE=2/}"
|
||||
|
||||
# Disable explicit -fno-PIE, gcc/binutils/libc will figure this out itself.
|
||||
export CFLAGS="${CFLAGS//-fno-PIE/}"
|
||||
export CXXFLAGS="${CXXFLAGS//-fno-PIE/}"
|
||||
export LDFLAGS="${LDFLAGS//-no-pie/}"
|
||||
|
||||
_void_cross_test_ver binutils
|
||||
_void_cross_test_ver linux
|
||||
_void_cross_test_ver gcc
|
||||
|
@ -608,8 +587,6 @@ do_install() {
|
|||
for f in ${DESTDIR}/${sysroot}/usr/lib/ld-musl-*.so.*; do
|
||||
ln -sf libc.so ${f}
|
||||
done
|
||||
|
||||
cp libssp_nonshared.a ${DESTDIR}/${sysroot}/usr/lib/
|
||||
else
|
||||
# Install glibc
|
||||
cd ${wrksrc}/glibc_build
|
||||
|
@ -641,12 +618,12 @@ do_install() {
|
|||
ln -sf libgnat-${gcc_major}.so ${DESTDIR}/${sysroot}/usr/lib/libgnat.so
|
||||
rm -vf ${DESTDIR}/${adalib}/libgna{rl,t}.so
|
||||
|
||||
# Remove libgomp library because it conflicts with libgomp and
|
||||
# libgomp-devel packages
|
||||
rm -f ${DESTDIR}/${sysroot}/usr/lib/libgomp*
|
||||
# Remove unnecessary libatomic which is only built for gccgo
|
||||
rm -rf ${DESTDIR}/${sysroot}/usr/lib/libatomic.*
|
||||
|
||||
# Remove libdep linker plugin because it conflicts with system binutils
|
||||
rm -f ${DESTDIR}/usr/lib/bfd-plugins/libdep*
|
||||
# If libquadmath was forced (needed for gfortran on some platforms)
|
||||
# then remove it because it conflicts with libquadmath package
|
||||
rm -rf ${DESTDIR}/${sysroot}/usr/lib/libquadmath.*
|
||||
|
||||
# Remove leftover symlinks
|
||||
rm -f ${DESTDIR}/usr/lib${XBPS_TARGET_WORDSIZE}
|
||||
|
|
|
@ -9,27 +9,12 @@ readonly EXTRA_ARGS="$4"
|
|||
readonly CMD="$5"
|
||||
shift 5
|
||||
|
||||
msg_red() {
|
||||
# error messages in bold/red
|
||||
[ -n "$NOCOLORS" ] || printf >&2 "\033[1m\033[31m"
|
||||
printf "=> ERROR: %s\\n" "$@" >&2
|
||||
[ -n "$NOCOLORS" ] || printf >&2 "\033[m"
|
||||
}
|
||||
|
||||
readonly XBPS_UCHROOT_CMD="$(command -v xbps-uchroot 2>/dev/null)"
|
||||
|
||||
if [ -z "$XBPS_UCHROOT_CMD" ]; then
|
||||
msg_red "could not find xbps-uchroot"
|
||||
if ! command -v xbps-uchroot >/dev/null 2>&1; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if ! [ -x "$XBPS_UCHROOT_CMD" ]; then
|
||||
msg_red "xbps-uchroot is not executable. Are you in the $(stat -c %G "$XBPS_UCHROOT_CMD") group?"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -z "$MASTERDIR" ] || [ -z "$DISTDIR" ]; then
|
||||
msg_red "$0: MASTERDIR/DISTDIR not set"
|
||||
if [ -z "$MASTERDIR" -o -z "$DISTDIR" ]; then
|
||||
echo "$0 MASTERDIR/DISTDIR not set"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
|
|
|
@ -1,35 +0,0 @@
|
|||
# syntax=docker/dockerfile:1
|
||||
FROM --platform=${BUILDPLATFORM} alpine:3.18 AS bootstrap
|
||||
ARG TARGETPLATFORM
|
||||
ARG MIRROR=https://repo-ci.voidlinux.org
|
||||
ARG LIBC
|
||||
RUN apk add ca-certificates curl && \
|
||||
curl "${MIRROR}/static/xbps-static-static-0.59_5.$(uname -m)-musl.tar.xz" | tar vJx
|
||||
COPY common/repo-keys/* /target/var/db/xbps/keys/
|
||||
COPY common/container/setup.sh /bootstrap/setup.sh
|
||||
RUN --mount=type=cache,sharing=locked,target=/target/var/cache/xbps,id=repocache-${LIBC} \
|
||||
. /bootstrap/setup.sh; \
|
||||
XBPS_TARGET_ARCH=${ARCH} xbps-install -S \
|
||||
-R "${REPO}" -R "${REPO}/bootstrap" \
|
||||
-r /target
|
||||
|
||||
FROM --platform=${BUILDPLATFORM} bootstrap AS install
|
||||
ARG TARGETPLATFORM
|
||||
ARG MIRROR
|
||||
ARG LIBC
|
||||
COPY --from=bootstrap /target /target
|
||||
COPY common/container/noextract.conf /target/etc/xbps.d/noextract.conf
|
||||
RUN --mount=type=cache,sharing=locked,target=/target/var/cache/xbps,id=repocache-${LIBC} \
|
||||
. /bootstrap/setup.sh; \
|
||||
XBPS_TARGET_ARCH=${ARCH} xbps-install -y \
|
||||
-R "${REPO}" -R "${REPO}/bootstrap" \
|
||||
-r /target \
|
||||
base-chroot void-repo-bootstrap
|
||||
|
||||
FROM scratch AS image
|
||||
COPY --link --from=install /target /
|
||||
RUN \
|
||||
install -dm1777 tmp; \
|
||||
xbps-reconfigure -fa; \
|
||||
rm -rf /var/cache/xbps/*
|
||||
CMD ["/bin/sh"]
|
|
@ -1,9 +0,0 @@
|
|||
## void-packages buildroot containers
|
||||
|
||||
These containers are used for CI and should contain everything needed to run xbps-src.
|
||||
|
||||
### Updating
|
||||
|
||||
To build a new version, kick off a CI run by pushing something to `common/container/` on `master` or using the `Run workflow` button [here](https://github.com/void-linux/void-packages/actions/workflows/container.yaml).
|
||||
|
||||
Once this is built, update the version where it is used in `.github/workflows/` (typically in the value of a `container.image` key) to the newly-built tag.
|
|
@ -1,29 +0,0 @@
|
|||
variable "MIRROR" {
|
||||
default = "https://repo-ci.voidlinux.org/"
|
||||
}
|
||||
|
||||
target "docker-metadata-action" {}
|
||||
|
||||
target "_common" {
|
||||
inherits = ["docker-metadata-action"]
|
||||
dockerfile = "common/container/Containerfile"
|
||||
no-cache-filter = ["bootstrap"]
|
||||
cache-to = ["type=local,dest=/tmp/buildx-cache"]
|
||||
cache-from = ["type=local,src=/tmp/buildx-cache"]
|
||||
target = "image"
|
||||
args = {
|
||||
"MIRROR" = "${MIRROR}"
|
||||
}
|
||||
}
|
||||
|
||||
target "void-buildroot-glibc" {
|
||||
inherits = ["_common"]
|
||||
platforms = ["linux/amd64", "linux/386", "linux/arm64", "linux/arm/v7", "linux/arm/v6"]
|
||||
args = { "LIBC" = "glibc" }
|
||||
}
|
||||
|
||||
target "void-buildroot-musl" {
|
||||
inherits = ["_common"]
|
||||
platforms = ["linux/amd64", "linux/arm64", "linux/arm/v7", "linux/arm/v6"]
|
||||
args = { "LIBC" = "musl" }
|
||||
}
|
|
@ -1,14 +0,0 @@
|
|||
noextract=/etc/sv*
|
||||
noextract=/usr/share/man*
|
||||
noextract=/usr/lib/dracut*
|
||||
noextract=/etc/hosts
|
||||
noextract=/etc/mtab
|
||||
noextract=/etc/skel*
|
||||
noextract=/usr/lib/modprobe.d*
|
||||
noextract=/usr/lib/sysctl.d*
|
||||
noextract=/usr/lib/udev*
|
||||
noextract=/usr/share/bash-completion*
|
||||
noextract=/usr/share/fish/vendor-completions.d*
|
||||
noextract=/usr/share/zsh/site-functions*
|
||||
noextract=/usr/share/info*
|
||||
noextract=/usr/share/locale*
|
|
@ -1,29 +0,0 @@
|
|||
#!/bin/sh
|
||||
|
||||
: "${MIRROR:=https://repo-default.voidlinux.org/}"
|
||||
|
||||
suffix() {
|
||||
case "${LIBC:?}" in
|
||||
musl) echo "-musl" ;;
|
||||
esac
|
||||
}
|
||||
|
||||
repo() {
|
||||
case "${ARCH:?}" in
|
||||
aarch64*) echo "${MIRROR}/current/aarch64" ;;
|
||||
*-musl) echo "${MIRROR}/current/musl" ;;
|
||||
*) echo "${MIRROR}/current" ;;
|
||||
esac
|
||||
}
|
||||
|
||||
case "${TARGETPLATFORM:?}" in
|
||||
linux/arm/v6) ARCH="armv6l$(suffix)" ;;
|
||||
linux/arm/v7) ARCH="armv7l$(suffix)" ;;
|
||||
linux/arm64) ARCH="aarch64$(suffix)" ;;
|
||||
linux/amd64) ARCH="x86_64$(suffix)" ;;
|
||||
linux/386) ARCH="i686$(suffix)" ;;
|
||||
esac
|
||||
|
||||
REPO="$(repo)"
|
||||
|
||||
export ARCH REPO
|
|
@ -1,12 +0,0 @@
|
|||
# Cross build profile for riscv64 and Musl libc.
|
||||
|
||||
XBPS_TARGET_MACHINE="riscv64-musl"
|
||||
XBPS_TARGET_QEMU_MACHINE="riscv64"
|
||||
XBPS_CROSS_TRIPLET="riscv64-linux-musl"
|
||||
XBPS_CROSS_CFLAGS="-march=rv64imafdc"
|
||||
XBPS_CROSS_CXXFLAGS="$XBPS_CROSS_CFLAGS"
|
||||
XBPS_CROSS_FFLAGS="$XBPS_CROSS_CFLAGS"
|
||||
XBPS_CROSS_RUSTFLAGS="--sysroot=${XBPS_CROSS_BASE}/usr"
|
||||
XBPS_CROSS_RUST_TARGET="riscv64gc-unknown-linux-musl"
|
||||
XBPS_CROSS_ZIG_TARGET="riscv64-linux-musl"
|
||||
XBPS_CROSS_ZIG_CPU="baseline"
|
|
@ -1,12 +0,0 @@
|
|||
# Cross build profile for riscv64 and Musl libc.
|
||||
|
||||
XBPS_TARGET_MACHINE="riscv64"
|
||||
XBPS_TARGET_QEMU_MACHINE="riscv64"
|
||||
XBPS_CROSS_TRIPLET="riscv64-linux-gnu"
|
||||
XBPS_CROSS_CFLAGS="-march=rv64imafdc"
|
||||
XBPS_CROSS_CXXFLAGS="$XBPS_CROSS_CFLAGS"
|
||||
XBPS_CROSS_FFLAGS="$XBPS_CROSS_CFLAGS"
|
||||
XBPS_CROSS_RUSTFLAGS="--sysroot=${XBPS_CROSS_BASE}/usr"
|
||||
XBPS_CROSS_RUST_TARGET="riscv64gc-unknown-linux-gnu"
|
||||
XBPS_CROSS_ZIG_TARGET="riscv64-linux-gnu"
|
||||
XBPS_CROSS_ZIG_CPU="baseline"
|
|
@ -5,9 +5,6 @@ build_wrksrc="${pkgname#R-cran-}"
|
|||
|
||||
# default to cran
|
||||
if [ -z "$distfiles" ]; then
|
||||
distfiles=" https://cran.r-project.org/src/contrib/Archive/${pkgname#R-cran-}/${pkgname#R-cran-}_${version//r/-}.tar.gz"
|
||||
case " $XBPS_DISTFILES_MIRROR " in
|
||||
*" https://cran.r-project.org/src/contrib "*) ;;
|
||||
*) XBPS_DISTFILES_MIRROR+=" https://cran.r-project.org/src/contrib" ;;
|
||||
esac
|
||||
distfiles="https://cran.r-project.org/src/contrib/${pkgname#R-cran-}_${version//r/-}.tar.gz
|
||||
https://cran.r-project.org/src/contrib/Archive/${pkgname#R-cran-}/${pkgname#R-cran-}_${version//r/-}.tar.gz"
|
||||
fi
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
if [ "$CHROOT_READY" ]; then
|
||||
if [ "$pkgname" != cmake-bootstrap ]; then
|
||||
hostmakedepends+=" cmake-bootstrap"
|
||||
if [ "$pkgname" != cmake ]; then
|
||||
hostmakedepends+=" cmake"
|
||||
fi
|
||||
if [ "${make_cmd:-ninja}" = ninja ]; then
|
||||
hostmakedepends+=" ninja"
|
||||
|
@ -8,4 +8,3 @@ if [ "$CHROOT_READY" ]; then
|
|||
fi
|
||||
|
||||
export CTEST_OUTPUT_ON_FAILURE=TRUE
|
||||
PATH="$PATH:/usr/libexec/xbps-src/bin"
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
if [ -z "$hostmakedepends" -o "${hostmakedepends##*gcc-go-tools*}" ]; then
|
||||
# gc compiler
|
||||
if [ -z "$archs" ]; then
|
||||
archs="aarch64* armv[567]* i686* x86_64* ppc64le* riscv64*"
|
||||
archs="aarch64* armv[567]* i686* x86_64* ppc64le*"
|
||||
fi
|
||||
hostmakedepends+=" go"
|
||||
nopie=yes
|
||||
|
@ -9,7 +9,7 @@ else
|
|||
# gccgo compiler
|
||||
if [ -z "$archs" ]; then
|
||||
# we have support for these in our gcc
|
||||
archs="aarch64* armv[567]* i686* x86_64* ppc64* riscv64*"
|
||||
archs="aarch64* armv[567]* i686* x86_64* ppc64*"
|
||||
fi
|
||||
if [ "$CROSS_BUILD" ]; then
|
||||
# target compiler to use; otherwise it'll just call gccgo
|
||||
|
@ -29,7 +29,6 @@ case "$XBPS_TARGET_MACHINE" in
|
|||
ppc*) export GOARCH=ppc;;
|
||||
mipsel*) export GOARCH=mipsle;;
|
||||
mips*) export GOARCH=mips;;
|
||||
riscv64*) export GOARCH=riscv64;;
|
||||
esac
|
||||
|
||||
export GOPATH="${wrksrc}/_build-${pkgname}-xbps"
|
||||
|
@ -38,12 +37,8 @@ export CGO_CFLAGS="$CFLAGS"
|
|||
export CGO_CPPFLAGS="$CPPFLAGS"
|
||||
export CGO_CXXFLAGS="$CXXFLAGS"
|
||||
export CGO_LDFLAGS="$LDFLAGS"
|
||||
export CGO_ENABLED="${CGO_ENABLED:-1}"
|
||||
export CGO_ENABLED=1
|
||||
export GO111MODULE=auto
|
||||
export GOTOOLCHAIN="${GOTOOLCHAIN:-local}"
|
||||
export GOPROXY="https://proxy.golang.org,direct"
|
||||
export GOSUMDB="sum.golang.org"
|
||||
|
||||
case "$XBPS_TARGET_MACHINE" in
|
||||
*-musl) export GOCACHE="${XBPS_HOSTDIR}/gocache-muslc" ;;
|
||||
*) export GOCACHE="${XBPS_HOSTDIR}/gocache-glibc" ;;
|
||||
|
|
|
@ -1,2 +1 @@
|
|||
hostmakedepends+=" meson"
|
||||
build_helper+=" meson"
|
||||
|
|
2
common/environment/build-style/python-module.sh
Normal file
2
common/environment/build-style/python-module.sh
Normal file
|
@ -0,0 +1,2 @@
|
|||
lib32disabled=yes
|
||||
makedepends+=" python python3"
|
|
@ -1,2 +1,4 @@
|
|||
# rsync isn't needed for everything but it's far easier to just put it here
|
||||
hostmakedepends+=" rsync"
|
||||
# python_version isn't needed for everything either
|
||||
python_version=3
|
||||
|
|
|
@ -26,7 +26,6 @@ scripts/attachfile2/pdfatfi.pl texlive
|
|||
scripts/authorindex/authorindex texlive
|
||||
scripts/bib2gls/bib2gls.sh texlive
|
||||
scripts/bib2gls/convertgls2bib.sh texlive
|
||||
scripts/bibcop/bibcop.pl texlive
|
||||
scripts/bibexport/bibexport.sh texlive
|
||||
scripts/bundledoc/arlatex texlive
|
||||
scripts/bundledoc/bundledoc texlive
|
||||
|
@ -34,11 +33,17 @@ scripts/cachepic/cachepic.tlu texlive-pictures
|
|||
scripts/checkcites/checkcites.lua texlive
|
||||
scripts/checklistings/checklistings.sh texlive
|
||||
scripts/chklref/chklref.pl texlive
|
||||
scripts/citation-style-language/citeproc-lua.lua texlive
|
||||
scripts/cjk-gs-integrate/cjk-gs-integrate.pl texlive
|
||||
scripts/clojure-pamphlet/pamphletangler texlive
|
||||
scripts/cluttex/cluttex.lua texlive
|
||||
scripts/context/perl/mptopdf.pl texlive
|
||||
scripts/context/stubs/unix/contextjit texlive
|
||||
scripts/context/stubs/unix/context texlive
|
||||
scripts/context/stubs/unix/luatools texlive
|
||||
scripts/context/stubs/unix/mtxrunjit texlive
|
||||
scripts/context/stubs/unix/mtxrun texlive
|
||||
scripts/context/stubs/unix/texexec texlive
|
||||
scripts/context/stubs/unix/texmfstart texlive
|
||||
scripts/convbkmk/convbkmk.rb texlive-langjapanese
|
||||
scripts/crossrefware/bbl2bib.pl texlive
|
||||
scripts/crossrefware/bibdoiadd.pl texlive
|
||||
|
@ -52,7 +57,6 @@ scripts/ctan-o-mat/ctan-o-mat.pl texlive
|
|||
scripts/ctanupload/ctanupload.pl texlive
|
||||
scripts/de-macro/de-macro texlive
|
||||
scripts/diadia/diadia.lua texlive-humanities
|
||||
scripts/digestif/digestif.texlua texlive
|
||||
scripts/dosepsbin/dosepsbin.pl texlive
|
||||
scripts/dtxgen/dtxgen texlive
|
||||
scripts/dviasm/dviasm.py texlive
|
||||
|
@ -98,7 +102,6 @@ scripts/listbib/listbib texlive
|
|||
scripts/listings-ext/listings-ext.sh texlive
|
||||
scripts/ltxfileinfo/ltxfileinfo texlive
|
||||
scripts/ltximg/ltximg.pl texlive
|
||||
scripts/luafindfont/luafindfont.lua texlive
|
||||
scripts/luaotfload/luaotfload-tool.lua texlive
|
||||
scripts/lwarp/lwarpmk.lua texlive
|
||||
scripts/make4ht/make4ht texlive
|
||||
|
@ -113,9 +116,6 @@ scripts/m-tx/m-tx.lua texlive-music
|
|||
scripts/multibibliography/multibibliography.pl texlive
|
||||
scripts/musixtex/musixflx.lua texlive-music
|
||||
scripts/musixtex/musixtex.lua texlive-music
|
||||
scripts/optexcount/optexcount texlive
|
||||
scripts/pagelayout/pagelayoutapi texlive
|
||||
scripts/pagelayout/textestvis texlive
|
||||
scripts/pax/pdfannotextractor.pl texlive
|
||||
scripts/pdfbook2/pdfbook2 texlive
|
||||
scripts/pdfcrop/pdfcrop.pl texlive
|
||||
|
@ -155,7 +155,6 @@ scripts/srcredact/srcredact.pl texlive
|
|||
scripts/sty2dtx/sty2dtx.pl texlive
|
||||
scripts/svn-multi/svn-multi.pl texlive
|
||||
scripts/tex4ebook/tex4ebook texlive
|
||||
scripts/texaccents/texaccents.sno texlive
|
||||
scripts/texcount/texcount.pl texlive
|
||||
scripts/texdef/texdef.pl texlive
|
||||
scripts/texdiff/texdiff texlive
|
||||
|
@ -179,8 +178,6 @@ scripts/texlive-extra/texconfig-dialog.sh texlive
|
|||
scripts/texlive-extra/texconfig.sh texlive
|
||||
scripts/texlive-extra/texconfig-sys.sh texlive
|
||||
scripts/texlive-extra/texlinks.sh texlive
|
||||
scripts/texlive-extra/xelatex-unsafe.sh texlive
|
||||
scripts/texlive-extra/xetex-unsafe.sh texlive
|
||||
scripts/texlive/fmtutil.pl texlive
|
||||
scripts/texlive/fmtutil-sys.sh texlive
|
||||
scripts/texlive/fmtutil-user.sh texlive
|
||||
|
@ -188,15 +185,13 @@ scripts/texlive/mktexlsr texlive
|
|||
scripts/texlive/mktexmf texlive
|
||||
scripts/texlive/mktexpk texlive
|
||||
scripts/texlive/mktextfm texlive
|
||||
scripts/texlive/rungs.lua texlive
|
||||
scripts/texliveonfly/texliveonfly.py texlive
|
||||
scripts/texlive/rungs.tlu texlive
|
||||
scripts/texlive/tlmgr.pl texlive
|
||||
scripts/texlive/updmap.pl texlive
|
||||
scripts/texlive/updmap-sys.sh texlive
|
||||
scripts/texlive/updmap-user.sh texlive
|
||||
scripts/texloganalyser/texloganalyser texlive
|
||||
scripts/texlogfilter/texlogfilter texlive
|
||||
scripts/texlogsieve/texlogsieve texlive
|
||||
scripts/texosquery/texosquery-jre5.sh texlive
|
||||
scripts/texosquery/texosquery-jre8.sh texlive
|
||||
scripts/texosquery/texosquery.sh texlive
|
||||
|
|
|
@ -11,6 +11,7 @@ ac_cv_func_getgrgid_r=${ac_cv_func_getgrgid_r=yes}
|
|||
ac_cv_func_getpwuid_r=${ac_cv_func_getpwuid_r=yes}
|
||||
ac_cv_func_posix_getpwuid_r=${ac_cv_func_posix_getpwuid_r=yes}
|
||||
ac_cv_func_posix_getgrgid_r=${ac_cv_func_posix_getgrgid_r=yes}
|
||||
ac_cv_type_uid_t={ac_cv_type_uid_t=yes}
|
||||
ac_cv_func_getaddrinfo=${ac_cv_func_getaddrinfo=yes}
|
||||
ac_cv_func_strdup=yes
|
||||
ac_cv_func_strtod=yes
|
||||
|
@ -169,7 +170,3 @@ ac_cv_strftime_extensions=yes
|
|||
|
||||
# time
|
||||
ac_cv_func_wait3=yes
|
||||
|
||||
# Y2038
|
||||
gl_cv_type_time_t_y2038=${gl_cv_type_time_t_y2038=no}
|
||||
ac_cv_type_time_t_bits_macro=${ac_cv_type_time_t_bits_macro=no}
|
||||
|
|
|
@ -1,148 +0,0 @@
|
|||
|
||||
## # general
|
||||
#ac_cv_va_val_copy=${ac_cv_va_val_copy=yes}
|
||||
#ac_cv_func_lstat_dereferences_slashed_symlink=${ac_cv_func_lstat_dereferences_slashed_symlink=yes}
|
||||
## ac_cv_func_lstat_empty_string_bug=${ac_cv_func_lstat_empty_string_bug=no}
|
||||
## ac_cv_func_posix_getpwnam_r=${ac_cv_func_posix_getpwnam_r=yes}
|
||||
## ac_cv_func_setvbuf_reversed=${ac_cv_func_setvbuf_reversed=no}
|
||||
## ac_cv_func_stat_empty_string_bug=${ac_cv_func_stat_empty_string_bug=no}
|
||||
## ac_cv_func_stat_ignores_trailing_slash=${ac_cv_func_stat_ignores_trailing_slash=no}
|
||||
## ac_libnet_have_packet_socket=${ac_libnet_have_packet_socket=yes}
|
||||
## ac_cv_linux_vers=${ac_cv_linux_vers=2}
|
||||
## ac_cv_need_trio=${ac_cv_need_trio=no}
|
||||
#ac_cv_sizeof___int64=0
|
||||
#ac_cv_sizeof_char=1
|
||||
c_cv_sizeof_int=${ac_cv_sizeof_int=4}
|
||||
ac_cv_sizeof_long=${ac_cv_sizeof_long=8}
|
||||
ac_cv_sizeof_off_t=${ac_cv_sizeof_off_t=8}
|
||||
ac_cv_sizeof_long_int=${ac_cv_sizeof_long_int=8}
|
||||
#ac_cv_sizeof_long_long=8
|
||||
#ac_cv_sizeof_short=2
|
||||
#ac_cv_sizeof_size_t=8
|
||||
#ac_cv_sizeof_ssize_t=8
|
||||
#ac_cv_sizeof_void_p=8
|
||||
#ac_cv_sizeof_unsigned_int=4
|
||||
#ac_cv_sizeof_unsigned_long=8
|
||||
ac_cv_sizeof_bool=1
|
||||
## ac_cv_sizeof_long_double=${ac_cv_sizeof_long_double=16}
|
||||
## ac_cv_sizeof_long_long=${ac_cv_sizeof_long_long=8}
|
||||
#ac_cv_sizeof_unsigned_short=2
|
||||
## ac_cv_sizeof_short_int=${ac_cv_sizeof_short_int=2}
|
||||
## ac_cv_sizeof_size_t=${ac_cv_sizeof_size_t=8}
|
||||
## ac_cv_sizeof_uid_t=${ac_cv_sizeof_uid_t=4}
|
||||
## ac_cv_sizeof_gid_t=${ac_cv_sizeof_gid_t=4}
|
||||
## ac_cv_sizeof_ino_t=${ac_cv_sizeof_ino_t=8}
|
||||
## ac_cv_sizeof_dev_t=${ac_cv_sizeof_dev_t=8}
|
||||
## ac_cv_sizeof_void_p=${ac_cv_sizeof_void_p=8}
|
||||
## ac_cv_strerror_r_SUSv3=${ac_cv_strerror_r_SUSv3=no}
|
||||
## db_cv_alignp_t=${db_cv_alignp_t='unsigned long long'}
|
||||
## db_cv_align_t=${db_cv_align_t='unsigned long long'}
|
||||
## db_cv_fcntl_f_setfd=${db_cv_fcntl_f_setfd=yes}
|
||||
## db_cv_sprintf_count=${db_cv_sprintf_count=yes}
|
||||
## ac_cv_sizeof_struct_iovec=16
|
||||
|
||||
# glib
|
||||
#glib_cv_hasinline=${glib_cv_hasinline=yes}
|
||||
#glib_cv_has__inline=${glib_cv_has__inline=yes}
|
||||
#glib_cv_has__inline__=${glib_cv_has__inline__=yes}
|
||||
#glib_cv_long_long_format=${glib_cv_long_long_format=ll}
|
||||
#glib_cv_rtldglobal_broken=${glib_cv_rtldglobal_broken=no}
|
||||
glib_cv_stack_grows=${glib_cv_stack_grows=no}
|
||||
glib_cv_uscore=${glib_cv_uscore=no}
|
||||
#glib_cv_va_val_copy=${glib_cv_va_val_copy=yes}
|
||||
#ac_cv_alignof_guint32=4
|
||||
#ac_cv_alignof_guint64=8
|
||||
#ac_cv_alignof_unsigned_long=8
|
||||
#ac_cv_alignof_char=1
|
||||
#ac_cv_alignof_double=8
|
||||
|
||||
## nano_cv_func_regexec_segv_emptystr=${nano_cv_func_regexec_segv_emptystr=no}
|
||||
## samba_cv_HAVE_VA_COPY=${samba_cv_HAVE_VA_COPY=yes}
|
||||
## utils_cv_sys_open_max=${utils_cv_sys_open_max=1015}
|
||||
|
||||
# gettext
|
||||
am_cv_func_working_getline=${am_cv_func_working_getline=yes}
|
||||
|
||||
#gcc
|
||||
#ac_cv_lib_m_sin=${ac_cv_lib_m_sin=yes}
|
||||
|
||||
#orbit
|
||||
#libIDL_cv_long_long_format=ll
|
||||
|
||||
## # ORBit2
|
||||
## ac_cv_alignof_CORBA_boolean=1
|
||||
## ac_cv_alignof_CORBA_char=1
|
||||
## ac_cv_alignof_CORBA_double=8
|
||||
## ac_cv_alignof_CORBA_float=4
|
||||
## ac_cv_alignof_CORBA_long=4
|
||||
## ac_cv_alignof_CORBA_long_double=8
|
||||
## ac_cv_alignof_CORBA_long_long=8
|
||||
## ac_cv_alignof_CORBA_octet=1
|
||||
## ac_cv_alignof_CORBA_pointer=8
|
||||
## ac_cv_alignof_CORBA_short=2
|
||||
## ac_cv_alignof_CORBA_struct=1
|
||||
## ac_cv_alignof_CORBA_wchar=2
|
||||
##
|
||||
## lf_cv_sane_realloc=yes
|
||||
as_cv_unaligned_access=${as_cv_unaligned_access=no}
|
||||
##
|
||||
## #unfs3
|
||||
## nfsd_cv_broken_setfsuid=${nfsd_cv_broken_setfsuid=0}
|
||||
## nfsd_cv_func_statfs=${nfsd_cv_func_statfs=statfs2_bsize}
|
||||
## nfsd_cv_bsd_signals=${nfsd_cv_bsd_signals=yes}
|
||||
|
||||
#apr
|
||||
apr_cv_tcp_nodelay_with_cork=${apr_cv_tcp_nodelay_with_cork=yes}
|
||||
|
||||
# lftp
|
||||
lftp_cv_va_val_copy=${lftp_cv_va_val_copy=yes}
|
||||
|
||||
# slrn
|
||||
slrn_cv_va_val_copy=${slrn_cv_va_val_copy=yes}
|
||||
|
||||
# cvs
|
||||
cvs_cv_func_printf_ptr=${cvs_cv_func_printf_ptr=yes}
|
||||
|
||||
## # at-spi2-core
|
||||
#ac_cv_alignof_dbind_pointer=8
|
||||
#ac_cv_alignof_dbind_struct=1
|
||||
#ac_cv_alignof_dbus_bool_t=4
|
||||
#ac_cv_alignof_dbus_int16_t=2
|
||||
#ac_cv_alignof_dbus_int32_t=4
|
||||
#ac_cv_alignof_dbus_int64_t=8
|
||||
|
||||
## # socat
|
||||
#sc_cv_type_dev_basic='6 /* unsigned long */'
|
||||
#sc_cv_type_gidt_basic='4 /* unsigned int */'
|
||||
#sc_cv_type_longlong=yes
|
||||
#sc_cv_type_modet_basic='4 /* unsigned int */'
|
||||
#sc_cv_type_off64=yes
|
||||
#sc_cv_type_off64_basic='5 /* long */'
|
||||
#sc_cv_type_off_basic='5 /* long */'
|
||||
#sc_cv_type_pidt_basic='3 /* int */'
|
||||
#sc_cv_type_rlimit_rlimmax_basic='6 /* unsigned long */'
|
||||
#sc_cv_type_sa_family_t=yes
|
||||
#sc_cv_type_sighandler=yes
|
||||
#sc_cv_type_sizet_basic='6 /* unsigned long */'
|
||||
#sc_cv_type_socklen=yes
|
||||
#sc_cv_type_socklent_basic='4 /* unsigned int */'
|
||||
#sc_cv_type_stat64=yes
|
||||
#sc_cv_type_stat64_stblksize_basic='3 /* int */'
|
||||
#sc_cv_type_stat64_stblocks_basic='5 /* long */'
|
||||
#sc_cv_type_stat64_stdev_basic='6 /* unsigned long */'
|
||||
#sc_cv_type_stat64_stino_basic='6 /* unsigned long */'
|
||||
#sc_cv_type_stat64_stnlink_basic='4 /* unsigned int */'
|
||||
#sc_cv_type_stat64_stsize_basic='5 /* long */'
|
||||
#sc_cv_type_stat_stblksize_basic='3 /* int */'
|
||||
#sc_cv_type_stat_stblocks_basic='5 /* long */'
|
||||
#sc_cv_type_stat_stino_basic='6 /* unsigned long */'
|
||||
#sc_cv_type_stat_stnlink_basic='4 /* unsigned int */'
|
||||
#sc_cv_type_stat_stsize_basic='5 /* long */'
|
||||
#sc_cv_type_struct_timeval_tv_usec='5 /* long */'
|
||||
#sc_cv_type_timet_basic='5 /* long */'
|
||||
#sc_cv_type_uidt_basic='4 /* unsigned int */'
|
||||
#sc_cv_type_uint16=yes
|
||||
#sc_cv_type_uint32=yes
|
||||
#sc_cv_type_uint64=yes
|
||||
#sc_cv_type_uint8=yes
|
||||
#sc_cv_typeof_struct_cmsghdr_cmsg_len='6 /* unsigned long */'
|
|
@ -1,16 +1,16 @@
|
|||
local _wrksrc="$wrksrc${build_wrksrc:+/$build_wrksrc}"
|
||||
case "$build_style" in
|
||||
cmake)
|
||||
CFLAGS="${CFLAGS} -ffile-prefix-map=$_wrksrc/${cmake_builddir:-build}=."
|
||||
CXXFLAGS="${CXXFLAGS} -ffile-prefix-map=$_wrksrc/${cmake_builddir:-build}=."
|
||||
CFLAGS="${CFLAGS} -fdebug-prefix-map=$_wrksrc/${cmake_builddir:-build}=."
|
||||
CXXFLAGS="${CXXFLAGS} -fdebug-prefix-map=$_wrksrc/${cmake_builddir:-build}=."
|
||||
;;
|
||||
meson)
|
||||
CFLAGS="${CFLAGS} -ffile-prefix-map=$_wrksrc/${meson_builddir:-build}=."
|
||||
CXXFLAGS="${CXXFLAGS} -ffile-prefix-map=$_wrksrc/${meson_builddir:-build}=."
|
||||
CFLAGS="${CFLAGS} -fdebug-prefix-map=$_wrksrc/${meson_builddir:-build}=."
|
||||
CXXFLAGS="${CXXFLAGS} -fdebug-prefix-map=$_wrksrc/${meson_builddir:-build}=."
|
||||
;;
|
||||
*)
|
||||
CFLAGS="${CFLAGS} -ffile-prefix-map=$_wrksrc=."
|
||||
CXXFLAGS="${CXXFLAGS} -ffile-prefix-map=$_wrksrc=."
|
||||
CFLAGS="${CFLAGS} -fdebug-prefix-map=$_wrksrc=."
|
||||
CXXFLAGS="${CXXFLAGS} -fdebug-prefix-map=$_wrksrc=."
|
||||
esac
|
||||
|
||||
unset _wrksrc
|
||||
|
|
|
@ -123,10 +123,6 @@ case "$XBPS_TARGET_MACHINE" in
|
|||
. ${_AUTOCONFCACHEDIR}/powerpc-linux
|
||||
. ${_AUTOCONFCACHEDIR}/powerpc32-linux
|
||||
;;
|
||||
riscv*)
|
||||
. ${_AUTOCONFCACHEDIR}/endian-little
|
||||
. ${_AUTOCONFCACHEDIR}/riscv64-linux
|
||||
;;
|
||||
|
||||
*) ;;
|
||||
esac
|
||||
|
|
|
@ -24,7 +24,7 @@ if [ -z "$nopie" ]; then
|
|||
fi
|
||||
else
|
||||
CFLAGS="-fno-PIE ${CFLAGS}"
|
||||
CXXFLAGS="-fno-PIE ${CXXFLAGS}"
|
||||
CXXFLAGS="-fno-PIE ${CFLAGS}"
|
||||
FFLAGS="-fno-PIE ${FFLAGS}"
|
||||
LDFLAGS="-no-pie ${LDFLAGS}"
|
||||
fi
|
||||
|
|
|
@ -1,182 +0,0 @@
|
|||
vextract() {
|
||||
local sc=--strip-components=1
|
||||
local dst=
|
||||
while [ "$#" -ne 1 ]; do
|
||||
case "$1" in
|
||||
-C)
|
||||
if [ -z "$2" ]; then
|
||||
msg_error "$pkgver: vextract -C <directory>.\n"
|
||||
fi
|
||||
dst="$2"
|
||||
mkdir -p "$dst"
|
||||
shift 2
|
||||
;;
|
||||
--no-strip-components)
|
||||
sc=
|
||||
shift
|
||||
;;
|
||||
--strip-components=*)
|
||||
sc="$1"
|
||||
shift
|
||||
;;
|
||||
--)
|
||||
shift; break ;;
|
||||
*)
|
||||
break ;;
|
||||
esac
|
||||
done
|
||||
|
||||
local TAR_CMD="${tar_cmd}"
|
||||
local sfx
|
||||
local archive="$1"
|
||||
local ret=0
|
||||
|
||||
[ -z "$TAR_CMD" ] && TAR_CMD="$(command -v bsdtar)"
|
||||
[ -z "$TAR_CMD" ] && TAR_CMD="$(command -v tar)"
|
||||
[ -z "$TAR_CMD" ] && msg_error "xbps-src: no suitable tar cmd (bsdtar, tar)\n"
|
||||
case "$archive" in
|
||||
*.tar.lzma) sfx="txz";;
|
||||
*.tar.lz) sfx="tlz";;
|
||||
*.tlz) sfx="tlz";;
|
||||
*.tar.xz) sfx="txz";;
|
||||
*.txz) sfx="txz";;
|
||||
*.tar.bz2) sfx="tbz";;
|
||||
*.tbz) sfx="tbz";;
|
||||
*.tar.gz) sfx="tgz";;
|
||||
*.tgz) sfx="tgz";;
|
||||
*.tar.zst) sfx="tzst";;
|
||||
*.tzst) sfx="tzst";;
|
||||
*.gz) sfx="gz";;
|
||||
*.xz) sfx="xz";;
|
||||
*.bz2) sfx="bz2";;
|
||||
*.zst) sfx="zst";;
|
||||
*.tar) sfx="tar";;
|
||||
*.zip) sfx="zip";;
|
||||
*.rpm) sfx="rpm";;
|
||||
*.deb) sfx="deb";;
|
||||
*.patch) sfx="txt";;
|
||||
*.diff) sfx="txt";;
|
||||
*.txt) sfx="txt";;
|
||||
*.sh) sfx="txt";;
|
||||
*.7z) sfx="7z";;
|
||||
*.gem) sfx="gem";;
|
||||
*.crate) sfx="crate";;
|
||||
*) msg_error "$pkgver: unknown distfile suffix for $archive.\n";;
|
||||
esac
|
||||
|
||||
case ${sfx} in
|
||||
tar|txz|tbz|tlz|tgz|tzst|crate)
|
||||
$TAR_CMD ${sc:+"$sc"} ${dst:+-C "$dst"} -x \
|
||||
--no-same-permissions --no-same-owner \
|
||||
-f $archive
|
||||
;;
|
||||
gz|bz2|xz|zst)
|
||||
cp -f $archive "${dst:-.}"
|
||||
(
|
||||
if [ "$dst" ]; then cd "$dst"; fi
|
||||
case ${sfx} in
|
||||
gz)
|
||||
gunzip -f ${archive##*/}
|
||||
;;
|
||||
bz2)
|
||||
bunzip2 -f ${archive##*/}
|
||||
;;
|
||||
xz)
|
||||
unxz -f ${archive##*/}
|
||||
;;
|
||||
zst)
|
||||
unzstd ${archive##*/}
|
||||
;;
|
||||
esac
|
||||
)
|
||||
;;
|
||||
zip)
|
||||
if command -v unzip &>/dev/null; then
|
||||
unzip -o -q $archive ${dst:+-d "$dst"}
|
||||
elif command -v bsdtar &>/dev/null; then
|
||||
bsdtar ${sc:+"$sc"} ${dst:+-C "$dst"} -xf $archive
|
||||
else
|
||||
msg_error "$pkgver: cannot find unzip or bsdtar bin for extraction.\n"
|
||||
fi
|
||||
;;
|
||||
rpm)
|
||||
if ! command -v bsdtar &>/dev/null; then
|
||||
msg_error "$pkgver: cannot find bsdtar for extraction.\n"
|
||||
fi
|
||||
bsdtar ${sc:+"$sc"} ${dst:+-C "$dst"} -x \
|
||||
--no-same-permissions --no-same-owner -f $archive
|
||||
;;
|
||||
deb)
|
||||
if command -v bsdtar &>/dev/null; then
|
||||
bsdtar -x -O -f "$archive" "data.tar.*" |
|
||||
bsdtar ${sc:+"$sc"} ${dst:+-C "$dst"} -x \
|
||||
--no-same-permissions --no-same-owner -f -
|
||||
else
|
||||
msg_error "$pkgver: cannot find bsdtar for extraction.\n"
|
||||
fi
|
||||
;;
|
||||
txt)
|
||||
cp -f $archive "$dst"
|
||||
;;
|
||||
7z)
|
||||
if command -v 7z &>/dev/null; then
|
||||
7z x $archive -o"$dst"
|
||||
elif command -v bsdtar &>/dev/null; then
|
||||
bsdtar ${sc:+"$sc"} ${dst:+-C "$dst"} -xf $archive
|
||||
else
|
||||
msg_error "$pkgver: cannot find 7z or bsdtar bin for extraction.\n"
|
||||
fi
|
||||
;;
|
||||
gem)
|
||||
$TAR_CMD -xOf $archive data.tar.gz |
|
||||
$TAR_CMD ${sc:+"$sc"} ${dst:+-C "$dst"} -xz -f -
|
||||
;;
|
||||
*)
|
||||
msg_error "$pkgver: cannot guess $archive extract suffix. ($sfx)\n"
|
||||
;;
|
||||
esac
|
||||
if [ "$?" -ne 0 ]; then
|
||||
msg_error "$pkgver: extracting $archive.\n"
|
||||
fi
|
||||
}
|
||||
|
||||
vsrcextract() {
|
||||
local sc=--strip-components=1
|
||||
local dst=
|
||||
while [ "$#" -ge 1 ]; do
|
||||
case "$1" in
|
||||
-C)
|
||||
if [ -z "$2" ]; then
|
||||
msg_error "$pkgver: vsrcextract -C <directory>.\n"
|
||||
fi
|
||||
dst="$2"
|
||||
shift 2
|
||||
;;
|
||||
--no-strip-components|--strip-components=*)
|
||||
sc="$1"
|
||||
shift
|
||||
;;
|
||||
*)
|
||||
break ;;
|
||||
esac
|
||||
done
|
||||
vextract "$sc" ${dst:+-C "$dst"} \
|
||||
"${XBPS_SRCDISTDIR}/${pkgname}-${version}/$1"
|
||||
}
|
||||
|
||||
vtar() {
|
||||
bsdtar "$@"
|
||||
}
|
||||
|
||||
vsrccopy() {
|
||||
local _tgt
|
||||
if [ $# -lt 2 ]; then
|
||||
msg_error "vsrccopy <file>... <target>"
|
||||
fi
|
||||
_tgt="${@: -1}"
|
||||
mkdir -p "$_tgt"
|
||||
while [ $# -gt 1 ]; do
|
||||
cp -a "${XBPS_SRCDISTDIR}/${pkgname}-${version}/$1" "$_tgt"
|
||||
shift
|
||||
done
|
||||
}
|
|
@ -15,10 +15,10 @@ elif [ -z "${SOURCE_DATE_EPOCH}" ]; then
|
|||
fi
|
||||
# check if the template is under version control:
|
||||
if [ -n "$basepkg" -a -z "$($XBPS_GIT_CMD -C ${XBPS_SRCPKGDIR}/${basepkg} ls-files template)" ]; then
|
||||
export SOURCE_DATE_EPOCH="$(stat_mtime ${XBPS_SRCPKGDIR}/${basepkg}/template)"
|
||||
export SOURCE_DATE_EPOCH="$(stat -c %Y ${XBPS_SRCPKGDIR}/${basepkg}/template)"
|
||||
else
|
||||
export SOURCE_DATE_EPOCH=$($XBPS_GIT_CMD -C ${XBPS_DISTDIR} cat-file commit HEAD |
|
||||
sed -n '/^committer /{s/.*> \([0-9][0-9]*\) [-+][0-9].*/\1/p;q;}')
|
||||
sed -n '/^committer /{s/.*> \([0-9][0-9]*\) [-+][0-9].*/\1/p;q}')
|
||||
fi
|
||||
fi
|
||||
|
||||
|
|
|
@ -8,27 +8,22 @@ unalias -a
|
|||
|
||||
# disable wildcards helper
|
||||
_noglob_helper() {
|
||||
set +f
|
||||
IFS= "$@"
|
||||
set +f
|
||||
"$@"
|
||||
}
|
||||
|
||||
# Apply _noglob to v* commands
|
||||
for cmd in vinstall vcopy vcompletion vmove vmkdir vbin vman vdoc vconf vsconf vlicense vsv; do
|
||||
# intentionally expanded when defined
|
||||
# shellcheck disable=SC2139
|
||||
alias ${cmd}="set -f; _noglob_helper _${cmd}"
|
||||
alias ${cmd}="set -f; _noglob_helper _${cmd}"
|
||||
done
|
||||
|
||||
_vsv() {
|
||||
local service="$1"
|
||||
local facility="${2:-daemon}"
|
||||
local LN_OPTS="-s"
|
||||
local svdir="${PKGDESTDIR}/etc/sv/${service}"
|
||||
|
||||
if [ $# -lt 1 ] || [ $# -gt 2 ]; then
|
||||
# pkgver is defined in common/xbps-src/shutils/commmon.sh
|
||||
# shellcheck disable=SC2154
|
||||
msg_red "$pkgver: vsv: up to 2 arguments expected: <service> [<log facility>]\n"
|
||||
if [ $# -lt 1 ]; then
|
||||
msg_red "$pkgver: vsv: 1 argument expected: <service>\n"
|
||||
return 1
|
||||
fi
|
||||
|
||||
|
@ -38,26 +33,18 @@ _vsv() {
|
|||
|
||||
vmkdir etc/sv
|
||||
vcopy "${FILESDIR}/$service" etc/sv
|
||||
if [ ! -L "$svdir/run" ]; then
|
||||
grep -Fq 'exec 2>&1' "$svdir/run" || msg_warn "$pkgver: vsv: service '$service' does not contain 'exec 2>&1' to log stderr\n"
|
||||
chmod 755 "$svdir/run"
|
||||
if [ ! -L $svdir/run ]; then
|
||||
chmod 755 $svdir/run
|
||||
fi
|
||||
if [ -e "$svdir/finish" ] && [ ! -L "$svdir/finish" ]; then
|
||||
chmod 755 "$svdir/finish"
|
||||
if [ -e $svdir/finish ] && [ ! -L $svdir/finish ]; then
|
||||
chmod 755 $svdir/finish
|
||||
fi
|
||||
ln ${LN_OPTS} "/run/runit/supervise.${service}" "$svdir/supervise"
|
||||
if [ -d "$svdir/log" ] || [ -L "$svdir/log" ]; then
|
||||
msg_warn "$pkgver: vsv: overriding default log service\n"
|
||||
else
|
||||
mkdir "$svdir/log"
|
||||
cat <<-EOF > "$svdir/log/run"
|
||||
#!/bin/sh
|
||||
exec vlogger -t $service -p $facility
|
||||
EOF
|
||||
fi
|
||||
ln ${LN_OPTS} "/run/runit/supervise.${service}-log" "$svdir/log/supervise"
|
||||
if [ -e "$svdir/log/run" ] && [ ! -L "$svdir/log/run" ]; then
|
||||
chmod 755 "${PKGDESTDIR}/etc/sv/${service}/log/run"
|
||||
ln ${LN_OPTS} /run/runit/supervise.${service} $svdir/supervise
|
||||
if [ -d $svdir/log ]; then
|
||||
ln ${LN_OPTS} /run/runit/supervise.${service}-log $svdir/log/supervise
|
||||
if [ -e $svdir/log/run ] && [ ! -L $svdir/log/run ]; then
|
||||
chmod 755 ${PKGDESTDIR}/etc/sv/${service}/log/run
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -98,9 +85,9 @@ _vman() {
|
|||
suffix=${target##*.}
|
||||
fi
|
||||
|
||||
if [[ $target =~ (.*)\.([a-z][a-z](_[A-Z][A-Z])?(\.[^.]+)?)\.(.*) ]]
|
||||
if [[ $target =~ (.*)\.([a-z][a-z](_[A-Z][A-Z])?)\.(.*) ]]
|
||||
then
|
||||
name=${BASH_REMATCH[1]}.${BASH_REMATCH[5]}
|
||||
name=${BASH_REMATCH[1]}.${BASH_REMATCH[4]}
|
||||
mandir=${BASH_REMATCH[2]}/man${suffix:0:1}
|
||||
else
|
||||
name=$target
|
||||
|
@ -124,8 +111,6 @@ _vdoc() {
|
|||
return 1
|
||||
fi
|
||||
|
||||
# pkgname is defined in the package
|
||||
# shellcheck disable=SC2154
|
||||
vinstall "$file" 644 "usr/share/doc/${pkgname}" "$targetfile"
|
||||
}
|
||||
|
||||
|
@ -181,9 +166,9 @@ _vinstall() {
|
|||
fi
|
||||
|
||||
if [ -z "$targetfile" ]; then
|
||||
install -Dm"${mode}" "${file}" "${PKGDESTDIR}/${targetdir}/${file##*/}"
|
||||
install -Dm${mode} "${file}" "${PKGDESTDIR}/${targetdir}/${file##*/}"
|
||||
else
|
||||
install -Dm"${mode}" "${file}" "${PKGDESTDIR}/${targetdir}/${targetfile##*/}"
|
||||
install -Dm${mode} "${file}" "${PKGDESTDIR}/${targetdir}/${targetfile##*/}"
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -199,9 +184,7 @@ _vcopy() {
|
|||
return 1
|
||||
fi
|
||||
|
||||
# intentionally unquoted for globbing
|
||||
# shellcheck disable=SC2086
|
||||
cp -a $files "${PKGDESTDIR}/${targetdir}"
|
||||
cp -a $files ${PKGDESTDIR}/${targetdir}
|
||||
}
|
||||
|
||||
_vmove() {
|
||||
|
@ -227,17 +210,13 @@ _vmove() {
|
|||
done
|
||||
|
||||
if [ -z "${_targetdir}" ]; then
|
||||
[ ! -d "${PKGDESTDIR}" ] && install -d "${PKGDESTDIR}"
|
||||
# intentionally unquoted for globbing
|
||||
# shellcheck disable=SC2086
|
||||
mv "${DESTDIR}"/$files "${PKGDESTDIR}"
|
||||
[ ! -d ${PKGDESTDIR} ] && install -d ${PKGDESTDIR}
|
||||
mv ${DESTDIR}/$files ${PKGDESTDIR}
|
||||
else
|
||||
if [ ! -d "${PKGDESTDIR}/${_targetdir}" ]; then
|
||||
install -d "${PKGDESTDIR}/${_targetdir}"
|
||||
if [ ! -d ${PKGDESTDIR}/${_targetdir} ]; then
|
||||
install -d ${PKGDESTDIR}/${_targetdir}
|
||||
fi
|
||||
# intentionally unquoted for globbing
|
||||
# shellcheck disable=SC2086
|
||||
mv "${DESTDIR}"/$files "${PKGDESTDIR}/${_targetdir}"
|
||||
mv ${DESTDIR}/$files ${PKGDESTDIR}/${_targetdir}
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -255,9 +234,9 @@ _vmkdir() {
|
|||
fi
|
||||
|
||||
if [ -z "$mode" ]; then
|
||||
install -d "${PKGDESTDIR}/${dir}"
|
||||
install -d ${PKGDESTDIR}/${dir}
|
||||
else
|
||||
install -dm"${mode}" "${PKGDESTDIR}/${dir}"
|
||||
install -dm${mode} ${PKGDESTDIR}/${dir}
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
|
@ -1,14 +1,14 @@
|
|||
#
|
||||
# Common variables that can be used by xbps-src.
|
||||
#
|
||||
# SITE used for distfiles mirrors. For use in $distfiles.
|
||||
# SITE used for ditfiles mirrors. For use in $distfiles.
|
||||
set -a
|
||||
|
||||
SOURCEFORGE_SITE="https://downloads.sourceforge.net/sourceforge"
|
||||
NONGNU_SITE="https://download.savannah.nongnu.org/releases"
|
||||
UBUNTU_SITE="http://archive.ubuntu.com/ubuntu/pool"
|
||||
XORG_SITE="https://www.x.org/releases/individual"
|
||||
DEBIAN_SITE="https://ftp.debian.org/debian/pool"
|
||||
DEBIAN_SITE="http://ftp.debian.org/debian/pool"
|
||||
GNOME_SITE="https://download.gnome.org/sources"
|
||||
KERNEL_SITE="https://www.kernel.org/pub/linux"
|
||||
CPAN_SITE="https://www.cpan.org/modules/by-module"
|
||||
|
|
|
@ -36,11 +36,3 @@ vopt_bool() {
|
|||
fi
|
||||
vopt_if "$1" "-D${prop}=true" "-D${prop}=false"
|
||||
}
|
||||
|
||||
vopt_feature() {
|
||||
local opt="$1" prop="${2:-$1}"
|
||||
if [ "$#" -gt "2" ]; then
|
||||
msg_error "vopt_feature $opt: $(($# - 2)) excess parameter(s)\n"
|
||||
fi
|
||||
vopt_if "$1" "-D${prop}=enabled" "-D${prop}=disabled"
|
||||
}
|
||||
|
|
|
@ -7,7 +7,7 @@ py2_lib="usr/lib/python${py2_ver}"
|
|||
py2_sitelib="${py2_lib}/site-packages"
|
||||
py2_inc="usr/include/python${py2_ver}"
|
||||
|
||||
py3_ver="3.12"
|
||||
py3_ver="3.11"
|
||||
py3_abiver=""
|
||||
py3_lib="usr/lib/python${py3_ver}"
|
||||
py3_sitelib="${py3_lib}/site-packages"
|
||||
|
|
|
@ -36,6 +36,6 @@ replace_interpreter() {
|
|||
sed -i -e "1s|^#![[:space:]]*${orsb}|#!${trpath}|" $file
|
||||
msg_normal "Transformed $lang script: ${file##$wrksrc}.\n"
|
||||
else
|
||||
msg_warn "Ignoring nonexistent $lang script: ${file##$wrksrc}.\n"
|
||||
msg_warn "Ignoring unexistent $lang script: ${file##$wrksrc}.\n"
|
||||
fi
|
||||
}
|
||||
|
|
|
@ -1,45 +1,6 @@
|
|||
# This shell snippet unsets all variables/functions that can be used in
|
||||
# the package template (excluding subpackages).
|
||||
|
||||
# Exported variables
|
||||
for var in $(awk 'BEGIN{for (i in ENVIRON) {print i}}' </dev/null); do
|
||||
# Those variables in chroot.sh will be kept
|
||||
case "$var" in
|
||||
BASH_FUNC_*'%%')
|
||||
# bash exported functions
|
||||
var="${var%??}"
|
||||
var="${var#BASH_FUNC_}"
|
||||
unset -f "$var"
|
||||
;;
|
||||
XBPS_* | IN_CHROOT | CHROOT_READY | SOURCE_DATE_EPOCH | NOCOLORS)
|
||||
# xbps-src specific
|
||||
;;
|
||||
SOURCEFORGE_SITE | NONGNU_SITE | XORG_SITE | DEBIAN_SITE | GNOME_SITE)
|
||||
;;
|
||||
KERNEL_SITE | CPAN_SITE | PYPI_SITE | MOZILLA_SITE | GNU_SITE)
|
||||
;;
|
||||
FREEDESKTOP_SITE | KDE_SITE | VIDEOLAN_SITE | UBUNTU_SITE)
|
||||
;;
|
||||
_ | PWD | SHLVL | USER | PATH | SHELL | HOME | LC_COLLATE | LANG | TERM | PS1)
|
||||
# known variables for shell
|
||||
;;
|
||||
DISTCC_HOSTS | DISTCC_DIR)
|
||||
;;
|
||||
CCACHE_DIR | CCACHE_COMPRESS)
|
||||
;;
|
||||
HTTP_PROXY | HTTPS_PROXY | SOCKS_PROXY | NO_PROXY | HTTP_PROXY_AUTH)
|
||||
;;
|
||||
FTP_PROXY | FTP_RETRIES)
|
||||
;;
|
||||
http_proxy | https_proxy | ftp_proxy | all_proxy | no_proxy)
|
||||
;;
|
||||
*)
|
||||
unset -v "$var"
|
||||
;;
|
||||
esac
|
||||
done
|
||||
unset -v var
|
||||
|
||||
## VARIABLES
|
||||
unset -v pkgname version revision short_desc homepage license maintainer
|
||||
unset -v archs distfiles checksum build_style build_helper nocross broken
|
||||
|
@ -59,7 +20,6 @@ unset -v nopie build_options build_options_default bootstrap repository reverts
|
|||
unset -v CFLAGS CXXFLAGS FFLAGS CPPFLAGS LDFLAGS LD_LIBRARY_PATH
|
||||
unset -v CC CXX CPP GCC LD AR AS RANLIB NM OBJDUMP OBJCOPY STRIP READELF PKG_CONFIG
|
||||
unset -v CMAKE_GENERATOR
|
||||
unset -v scons_use_destdir
|
||||
# build-helper python3
|
||||
unset -v PYPREFIX LDSHARED PYTHON_CONFIG PYTHONPATH _PYTHON_SYSCONFIGDATA_NAME
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
hook() {
|
||||
local srcdir="$XBPS_SRCDISTDIR/$pkgname-$version"
|
||||
local f j curfile found extractdir innerdir innerfile num_dirs
|
||||
local f j curfile found extractdir innerdir num_dirs
|
||||
local TAR_CMD
|
||||
|
||||
if [ -z "$distfiles" -a -z "$checksum" ]; then
|
||||
|
@ -45,17 +45,121 @@ hook() {
|
|||
unset found
|
||||
continue
|
||||
fi
|
||||
vsrcextract --no-strip-components -C "$extractdir" "$curfile"
|
||||
|
||||
case $curfile in
|
||||
*.tar.lzma) cursufx="txz";;
|
||||
*.tar.lz) cursufx="tlz";;
|
||||
*.tlz) cursufx="tlz";;
|
||||
*.tar.xz) cursufx="txz";;
|
||||
*.txz) cursufx="txz";;
|
||||
*.tar.bz2) cursufx="tbz";;
|
||||
*.tbz) cursufx="tbz";;
|
||||
*.tar.gz) cursufx="tgz";;
|
||||
*.tgz) cursufx="tgz";;
|
||||
*.gz) cursufx="gz";;
|
||||
*.xz) cursufx="xz";;
|
||||
*.bz2) cursufx="bz2";;
|
||||
*.tar) cursufx="tar";;
|
||||
*.zip) cursufx="zip";;
|
||||
*.rpm) cursufx="rpm";;
|
||||
*.patch) cursufx="txt";;
|
||||
*.diff) cursufx="txt";;
|
||||
*.txt) cursufx="txt";;
|
||||
*.sh) cursufx="txt";;
|
||||
*.7z) cursufx="7z";;
|
||||
*.gem) cursufx="gem";;
|
||||
*.crate) cursufx="crate";;
|
||||
*) msg_error "$pkgver: unknown distfile suffix for $curfile.\n";;
|
||||
esac
|
||||
|
||||
case ${cursufx} in
|
||||
tar|txz|tbz|tlz|tgz|crate)
|
||||
$TAR_CMD -x --no-same-permissions --no-same-owner -f $srcdir/$curfile -C "$extractdir"
|
||||
if [ $? -ne 0 ]; then
|
||||
msg_error "$pkgver: extracting $curfile into $XBPS_BUILDDIR.\n"
|
||||
fi
|
||||
;;
|
||||
gz|bz2|xz)
|
||||
cp -f $srcdir/$curfile "$extractdir"
|
||||
cd "$extractdir"
|
||||
case ${cursufx} in
|
||||
gz)
|
||||
gunzip -f $curfile
|
||||
;;
|
||||
bz2)
|
||||
bunzip2 -f $curfile
|
||||
;;
|
||||
*)
|
||||
unxz -f $curfile
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
zip)
|
||||
if command -v unzip &>/dev/null; then
|
||||
unzip -o -q $srcdir/$curfile -d "$extractdir"
|
||||
if [ $? -ne 0 ]; then
|
||||
msg_error "$pkgver: extracting $curfile into $XBPS_BUILDDIR.\n"
|
||||
fi
|
||||
elif command -v bsdtar &>/dev/null; then
|
||||
bsdtar -xf $srcdir/$curfile -C "$extractdir"
|
||||
if [ $? -ne 0 ]; then
|
||||
msg_error "$pkgver: extracting $curfile into $XBPS_BUILDDIR.\n"
|
||||
fi
|
||||
else
|
||||
msg_error "$pkgver: cannot find unzip or bsdtar bin for extraction.\n"
|
||||
fi
|
||||
;;
|
||||
rpm)
|
||||
if command -v rpmextract &>/dev/null; then
|
||||
cd "$extractdir"
|
||||
rpmextract $srcdir/$curfile
|
||||
if [ $? -ne 0 ]; then
|
||||
msg_error "$pkgver: extracting $curfile into $XBPS_BUILDDIR.\n"
|
||||
fi
|
||||
else
|
||||
msg_error "$pkgver: cannot find rpmextract for extraction.\n"
|
||||
fi
|
||||
;;
|
||||
txt)
|
||||
cp -f $srcdir/$curfile "$extractdir"
|
||||
;;
|
||||
7z)
|
||||
if command -v 7z &>/dev/null; then
|
||||
7z x $srcdir/$curfile -o"$extractdir"
|
||||
if [ $? -ne 0 ]; then
|
||||
msg_error "$pkgver: extracting $curfile into $XBPS_BUILDDIR.\n"
|
||||
fi
|
||||
elif command -v bsdtar &>/dev/null; then
|
||||
bsdtar -xf $srcdir/$curfile -C "$extractdir"
|
||||
if [ $? -ne 0 ]; then
|
||||
msg_error "$pkgver: extracting $curfile into $XBPS_BUILDDIR.\n"
|
||||
fi
|
||||
else
|
||||
msg_error "$pkgver: cannot find 7z or bsdtar bin for extraction.\n"
|
||||
fi
|
||||
;;
|
||||
gem)
|
||||
innerdir="$extractdir/${wrksrc##*/}"
|
||||
mkdir -p "$innerdir"
|
||||
$TAR_CMD -xOf $srcdir/$curfile data.tar.gz |
|
||||
$TAR_CMD -xz -C "$innerdir" -f -
|
||||
if [ $? -ne 0 ]; then
|
||||
msg_error "$pkgver: extracting $curfile into $XBPS_BUILDDIR.\n"
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
msg_error "$pkgver: cannot guess $curfile extract suffix. ($cursufx)\n"
|
||||
;;
|
||||
esac
|
||||
done
|
||||
|
||||
cd "$extractdir"
|
||||
# find "$extractdir" -mindepth 1 -maxdepth 1 -printf '1\n' | wc -l
|
||||
# However, it requires GNU's find
|
||||
num_dirs=0
|
||||
for f in * .*; do
|
||||
for f in "$extractdir"/* "$extractdir"/.*; do
|
||||
if [ -e "$f" ] || [ -L "$f" ]; then
|
||||
case "$f" in
|
||||
. | ..) ;;
|
||||
*/. | */..) ;;
|
||||
*)
|
||||
innerdir="$f"
|
||||
num_dirs=$(( num_dirs + 1 ))
|
||||
|
@ -63,35 +167,16 @@ hook() {
|
|||
esac
|
||||
fi
|
||||
done
|
||||
# Special case for num_dirs = 2, and it contains metadata
|
||||
if [ "$num_dirs" != 2 ] || [ "$create_wrksrc" ]; then
|
||||
:
|
||||
elif grep -q 'xmlns="http://pear[.]php[.]net/dtd/package' package.xml 2>/dev/null
|
||||
then
|
||||
# PHP modules' metadata
|
||||
rm -f package.xml
|
||||
for f in */; do innerdir="$f"; done
|
||||
num_dirs=1
|
||||
else
|
||||
for f in *; do
|
||||
# AppleDouble encoded Macintosh file
|
||||
if [ -e "$f" ] && [ -e "._$f" ]; then
|
||||
rm -f "._$f"
|
||||
num_dirs=1
|
||||
innerdir="$f"
|
||||
break
|
||||
fi
|
||||
done
|
||||
fi
|
||||
rm -rf "$wrksrc"
|
||||
innerdir="$extractdir/$innerdir"
|
||||
cd "$XBPS_BUILDDIR"
|
||||
if [ "$num_dirs" = 1 ] && [ -d "$innerdir" ] && [ -z "$create_wrksrc" ]; then
|
||||
# rename the subdirectory (top-level of distfiles) to $wrksrc
|
||||
mv "$innerdir" "$wrksrc" &&
|
||||
rmdir "$extractdir"
|
||||
else
|
||||
elif [ "$num_dirs" -gt 1 ] || [ -n "$create_wrksrc" ]; then
|
||||
# rename the tmpdir to wrksrc
|
||||
mv "$extractdir" "$wrksrc"
|
||||
else
|
||||
mkdir -p "$wrksrc"
|
||||
fi ||
|
||||
msg_error "$pkgver: failed to move sources to $wrksrc\n"
|
||||
}
|
||||
|
|
|
@ -54,7 +54,14 @@ contents_cksum() {
|
|||
fi
|
||||
;;
|
||||
rpm)
|
||||
msg_error "$pkgver: contents checksum not support for rpm.\n"
|
||||
if command -v rpmextract &>/dev/null; then
|
||||
cksum=$($XBPS_DIGEST_CMD <(rpm2cpio "$curfile" | $TAR_CMD -x -f -))
|
||||
if [ $? -ne 0 ]; then
|
||||
msg_error "$pkgver: extracting $curfile to pipe.\n"
|
||||
fi
|
||||
else
|
||||
msg_error "$pkgver: cannot find rpmextract for extraction.\n"
|
||||
fi
|
||||
;;
|
||||
txt)
|
||||
cksum=$($XBPS_DIGEST_CMD "$curfile")
|
||||
|
@ -253,7 +260,7 @@ hook() {
|
|||
if [[ $cksum = $filesum ]]; then
|
||||
dfgood=$((dfgood + 1))
|
||||
else
|
||||
inode=$(stat_inode "$distfile")
|
||||
inode=$(stat "$distfile" --printf "%i")
|
||||
msg_warn "$pkgver: wrong checksum found for ${curfile} - purging\n"
|
||||
find ${XBPS_SRCDISTDIR} -inum ${inode} -delete -print
|
||||
fi
|
||||
|
|
|
@ -15,7 +15,8 @@ hook() {
|
|||
rm -f ${PKGDESTDIR}/usr/share/info/dir
|
||||
fi
|
||||
|
||||
find ${PKGDESTDIR}/usr/share/info -type f -follow | while read -r f; do
|
||||
find ${PKGDESTDIR}/usr/share/info -type f -follow | while read f
|
||||
do
|
||||
j=$(echo "$f"|sed -e "$fpattern")
|
||||
[ "$j" = "" ] && continue
|
||||
[ "$j" = "/usr/share/info/dir" ] && continue
|
||||
|
|
|
@ -9,7 +9,8 @@ hook() {
|
|||
fi
|
||||
|
||||
# rewrite symlinks
|
||||
find $mandir -type l -regex '.*\.\(gz\|bz2\)' | while read -r f; do
|
||||
find $mandir -type l -regex '.*\.\(gz\|bz2\)' | while read f
|
||||
do
|
||||
lnkat=$(readlink "$f")
|
||||
ln -s ${lnkat%.*} ${f%.*}
|
||||
rm $f
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
hook() {
|
||||
if [ -d "${PKGDESTDIR}" ]; then
|
||||
find "${PKGDESTDIR}" -mindepth 1 -type d -empty -print -delete|sort -r|while read -r f; do
|
||||
find "${PKGDESTDIR}" -mindepth 1 -type d -empty -print -delete|sort -r|while read f; do
|
||||
_dir="${f##${PKGDESTDIR}}"
|
||||
msg_warn "$pkgver: removed empty dir: ${_dir}\n"
|
||||
done
|
||||
|
|
|
@ -119,16 +119,10 @@ _EOF
|
|||
#
|
||||
# Handle binfmts trigger
|
||||
#
|
||||
if [ -n "${binfmts}" ] || [ -d "${PKGDESTDIR}/usr/share/binfmts" ]; then
|
||||
_add_trigger binfmts
|
||||
fi
|
||||
if [ -n "${binfmts}" ]; then
|
||||
_add_trigger binfmts
|
||||
echo "export binfmts=\"${binfmts}\"" >> $tmpf
|
||||
fi
|
||||
if [ -d "${PKGDESTDIR}/usr/share/binfmts" ]; then
|
||||
_import_binfmts="$(find "${PKGDESTDIR}/usr/share/binfmts" -type f -printf '%f\n')"
|
||||
echo "export import_binfmts=\"${_import_binfmts}\"" >> $tmpf
|
||||
fi
|
||||
#
|
||||
# Handle GNU Info files.
|
||||
#
|
||||
|
@ -278,7 +272,7 @@ _EOF
|
|||
fi
|
||||
fi
|
||||
|
||||
if [ -n "$python_version" ] && [ "$python_version" != ignore ]; then
|
||||
if [ -n "$python_version" ]; then
|
||||
pycompile_version=${python_version}
|
||||
fi
|
||||
|
||||
|
|
|
@ -65,7 +65,7 @@ hook() {
|
|||
|
||||
STRIPCMD=/usr/bin/$STRIP
|
||||
|
||||
find ${PKGDESTDIR} -type f | while read -r f; do
|
||||
find ${PKGDESTDIR} -type f | while read f; do
|
||||
if [[ $f =~ ^${PKGDESTDIR}/usr/lib/debug/ ]]; then
|
||||
continue
|
||||
fi
|
||||
|
|
|
@ -16,8 +16,7 @@ hook() {
|
|||
# s,/usr/armv7l-linux-musleabihf/usr,/usr,g
|
||||
# trailing /usr to avoid clashing with
|
||||
# other $XBPS_CROSS_BASE and $XBPS_CROSS_TRIPLET.
|
||||
sed -i --follow-symlinks \
|
||||
-e "s,$XBPS_CROSS_BASE/usr,/usr,g" "$f"
|
||||
sed -i -e "s,$XBPS_CROSS_BASE/usr,/usr,g" "$f"
|
||||
fi
|
||||
done
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@ registerpkg() {
|
|||
local repo="$1" pkg="$2" arch="$3"
|
||||
|
||||
if [ ! -f ${repo}/${pkg} ]; then
|
||||
msg_error "Nonexistent binary package ${repo}/${pkg}!\n"
|
||||
msg_error "Unexistent binary package ${repo}/${pkg}!\n"
|
||||
fi
|
||||
|
||||
printf "%s:%s:%s\n" "${arch}" "${repo}" "${pkg}" >> "${XBPS_STATEDIR}/.${sourcepkg}_register_pkg"
|
||||
|
|
|
@ -207,8 +207,6 @@ hook() {
|
|||
generic_wrapper sdl-config
|
||||
generic_wrapper sdl2-config
|
||||
generic_wrapper gpgme-config
|
||||
generic_wrapper gphoto2-config
|
||||
generic_wrapper gphoto2-port-config
|
||||
generic_wrapper imlib2-config
|
||||
generic_wrapper libmikmod-config
|
||||
generic_wrapper pcre-config
|
||||
|
@ -238,6 +236,7 @@ hook() {
|
|||
generic_wrapper3 libetpan-config
|
||||
generic_wrapper3 giblib-config
|
||||
python_wrapper python-config 2.7
|
||||
python_wrapper python3-config 3.12
|
||||
python_wrapper python3-config 3.11
|
||||
apr_apu_wrapper apr-1-config
|
||||
apr_apu_wrapper apu-1-config
|
||||
}
|
||||
|
|
|
@ -12,10 +12,6 @@ hook() {
|
|||
pyver="$python_version"
|
||||
fi
|
||||
|
||||
if [ "$python_version" = ignore ]; then
|
||||
return
|
||||
fi
|
||||
|
||||
if [ -n "$pyver" ]; then
|
||||
default_shebang="#!/usr/bin/python${pyver%.*}"
|
||||
fi
|
||||
|
|
|
@ -40,14 +40,13 @@ store_pkgdestdir_rundeps() {
|
|||
-z "$($XBPS_UHELPER_CMD getpkgname ${_curdep} 2>/dev/null)" ]; then
|
||||
_curdep="${_curdep}>=0"
|
||||
fi
|
||||
printf "%s " "${_curdep}"
|
||||
done > "${PKGDESTDIR}/rdeps"
|
||||
printf -- "${_curdep}\n"
|
||||
done | sort | xargs > ${PKGDESTDIR}/rdeps
|
||||
fi
|
||||
}
|
||||
|
||||
hook() {
|
||||
local depsftmp f lf j mapshlibs sorequires _curdep elfmagic broken_shlibs verify_deps
|
||||
local _shlib_dir="${XBPS_STATEDIR}/shlib-provides"
|
||||
local depsftmp f lf j mapshlibs sorequires _curdep elfmagic
|
||||
|
||||
# Disable trap on ERR, xbps-uhelper cmd might return error... but not something
|
||||
# to be worried about because if there are broken shlibs this hook returns
|
||||
|
@ -64,13 +63,9 @@ hook() {
|
|||
depsftmp=$(mktemp) || exit 1
|
||||
find ${PKGDESTDIR} -type f -perm -u+w > $depsftmp 2>/dev/null
|
||||
|
||||
for f in ${shlib_requires}; do
|
||||
verify_deps+=" ${f}"
|
||||
done
|
||||
|
||||
exec 3<&0 # save stdin
|
||||
exec < $depsftmp
|
||||
while read -r f; do
|
||||
while read f; do
|
||||
lf=${f#${PKGDESTDIR}}
|
||||
if [ "${skiprdeps/${lf}/}" != "${skiprdeps}" ]; then
|
||||
msg_normal "Skipping dependency scan for ${lf}\n"
|
||||
|
@ -96,58 +91,79 @@ hook() {
|
|||
# above, the mapping is done thru the common/shlibs file.
|
||||
#
|
||||
for f in ${verify_deps}; do
|
||||
unset _rdep _pkgname _rdepver
|
||||
|
||||
local _findargs="-name"
|
||||
# if SONAME is a path, find should use -wholename
|
||||
if [[ "$f" = */* ]]; then
|
||||
_findargs="-wholename"
|
||||
fi
|
||||
if [ "$(find "${PKGDESTDIR}" $_findargs "$f")" ]; then
|
||||
unset _f j rdep _rdep rdepcnt soname _pkgname _rdepver found
|
||||
_f=$(echo "$f"|sed -E 's|\+|\\+|g')
|
||||
rdep="$(grep -E "^${_f}[[:blank:]]+.*$" $mapshlibs|cut -d ' ' -f2)"
|
||||
rdepcnt="$(grep -E "^${_f}[[:blank:]]+.*$" $mapshlibs|cut -d ' ' -f2|wc -l)"
|
||||
if [ -z "$rdep" ]; then
|
||||
# Ignore libs by current pkg
|
||||
echo " SONAME: $f <-> $pkgname (ignored)"
|
||||
soname=$(find ${PKGDESTDIR} -name "$f")
|
||||
if [ -z "$soname" ]; then
|
||||
msg_red_nochroot " SONAME: $f <-> UNKNOWN PKG PLEASE FIX!\n"
|
||||
broken=1
|
||||
else
|
||||
echo " SONAME: $f <-> $pkgname (ignored)"
|
||||
fi
|
||||
continue
|
||||
# If this library is provided by a subpkg of sourcepkg, use that subpkg
|
||||
elif _pkgname="$(cd "$_shlib_dir" && grep -F -l -x "$f" *.soname 2>/dev/null)"; then
|
||||
# If that library has SONAME, add it to shlibs-requires, too.
|
||||
_pkgname=${_pkgname%.soname}
|
||||
_sdep="${_pkgname}-${version}_${revision}"
|
||||
sorequires+="${f} "
|
||||
elif _pkgname="$(cd "$_shlib_dir" && grep -F -l -x "$f" *.nosoname 2>/dev/null)"; then
|
||||
_pkgname=${_pkgname%.nosoname}
|
||||
_sdep="${_pkgname}-${version}_${revision}"
|
||||
elif [ "$rdepcnt" -gt 1 ]; then
|
||||
unset j found
|
||||
# Check if shlib is provided by multiple pkgs.
|
||||
for j in ${rdep}; do
|
||||
_pkgname=$($XBPS_UHELPER_CMD getpkgname "$j")
|
||||
# if there's a SONAME matching pkgname, use it.
|
||||
for x in ${pkgname} ${subpackages}; do
|
||||
[[ $_pkgname == $x ]] && found=1 && break
|
||||
done
|
||||
[[ $found ]] && _rdep=$j && break
|
||||
done
|
||||
if [ -z "${_rdep}" ]; then
|
||||
# otherwise pick up the first one.
|
||||
for j in ${rdep}; do
|
||||
[ -z "${_rdep}" ] && _rdep=$j
|
||||
done
|
||||
fi
|
||||
else
|
||||
_rdep="$(awk -v sl="$f" '$1 == sl { print $2; exit; }' "$mapshlibs")"
|
||||
|
||||
if [ -z "$_rdep" ]; then
|
||||
msg_red_nochroot " SONAME: $f <-> UNKNOWN PKG PLEASE FIX!\n"
|
||||
broken_shlibs=1
|
||||
continue
|
||||
fi
|
||||
_pkgname=$($XBPS_UHELPER_CMD getpkgname "${_rdep}" 2>/dev/null)
|
||||
_rdepver=$($XBPS_UHELPER_CMD getpkgversion "${_rdep}" 2>/dev/null)
|
||||
if [ -z "${_pkgname}" -o -z "${_rdepver}" ]; then
|
||||
msg_red_nochroot " SONAME: $f <-> UNKNOWN PKG PLEASE FIX!\n"
|
||||
broken_shlibs=1
|
||||
continue
|
||||
fi
|
||||
_sdep="${_pkgname}>=${_rdepver}"
|
||||
|
||||
# By this point, SONAME can't be found in current pkg
|
||||
sorequires+="${f} "
|
||||
_rdep=$rdep
|
||||
fi
|
||||
_pkgname=$($XBPS_UHELPER_CMD getpkgname "${_rdep}" 2>/dev/null)
|
||||
_rdepver=$($XBPS_UHELPER_CMD getpkgversion "${_rdep}" 2>/dev/null)
|
||||
if [ -z "${_pkgname}" -o -z "${_rdepver}" ]; then
|
||||
msg_red_nochroot " SONAME: $f <-> UNKNOWN PKG PLEASE FIX!\n"
|
||||
broken=1
|
||||
continue
|
||||
fi
|
||||
# Check if pkg is a subpkg of sourcepkg; if true, ignore version
|
||||
# in common/shlibs.
|
||||
_sdep="${_pkgname}>=${_rdepver}"
|
||||
for _subpkg in ${subpackages}; do
|
||||
if [ "${_subpkg}" = "${_pkgname}" ]; then
|
||||
_sdep="${_pkgname}-${version}_${revision}"
|
||||
break
|
||||
fi
|
||||
done
|
||||
|
||||
if [ "${_pkgname}" != "${pkgname}" ]; then
|
||||
echo " SONAME: $f <-> ${_sdep}"
|
||||
sorequires+="${f} "
|
||||
else
|
||||
# Ignore libs by current pkg
|
||||
echo " SONAME: $f <-> ${_rdep} (ignored)"
|
||||
continue
|
||||
fi
|
||||
echo " SONAME: $f <-> ${_sdep}"
|
||||
add_rundep "${_sdep}"
|
||||
done
|
||||
#
|
||||
# If pkg uses any unknown SONAME error out.
|
||||
#
|
||||
if [ -n "$broken_shlibs" -a -z "$allow_unknown_shlibs" ]; then
|
||||
if [ -n "$broken" -a -z "$allow_unknown_shlibs" ]; then
|
||||
msg_error "$pkgver: cannot guess required shlibs, aborting!\n"
|
||||
fi
|
||||
|
||||
store_pkgdestdir_rundeps
|
||||
|
||||
for f in ${shlib_requires}; do
|
||||
sorequires+="${f} "
|
||||
done
|
||||
if [ -n "${sorequires}" ]; then
|
||||
echo "${sorequires}" | xargs -n1 | sort | xargs > ${PKGDESTDIR}/shlib-requires
|
||||
fi
|
||||
|
|
|
@ -1,87 +0,0 @@
|
|||
hook() {
|
||||
local destdir32=${XBPS_DESTDIR}/${pkgname}-32bit-${version}
|
||||
|
||||
# By default always enabled unless "lib32disabled" is set.
|
||||
if [ -n "$lib32disabled" ]; then
|
||||
return
|
||||
fi
|
||||
|
||||
# This hook will only work when building for x86.
|
||||
if [ "$XBPS_TARGET_MACHINE" != "i686" ]; then
|
||||
return
|
||||
fi
|
||||
|
||||
if [ ! -d ${destdir32} ]; then
|
||||
return
|
||||
fi
|
||||
|
||||
# If the rdeps file exist (runtime deps), copy and then modify it for
|
||||
# 32bit dependencies.
|
||||
trap - ERR
|
||||
|
||||
: > ${destdir32}/rdeps
|
||||
|
||||
if [ -s "$PKGDESTDIR/rdeps" ]; then
|
||||
if [ -n "$lib32depends" ]; then
|
||||
_deps="${lib32depends}"
|
||||
else
|
||||
_deps="$(<${PKGDESTDIR}/rdeps)"
|
||||
fi
|
||||
for f in ${_deps}; do
|
||||
unset found pkgn pkgv _shprovides
|
||||
|
||||
pkgn="$($XBPS_UHELPER_CMD getpkgdepname $f)"
|
||||
if [ -z "${pkgn}" ]; then
|
||||
pkgn="$($XBPS_UHELPER_CMD getpkgname $f)"
|
||||
if [ -z "${pkgn}" ]; then
|
||||
msg_error "$pkgver: invalid dependency $f\n"
|
||||
fi
|
||||
pkgv="-$($XBPS_UHELPER_CMD getpkgversion ${f})"
|
||||
else
|
||||
pkgv="$($XBPS_UHELPER_CMD getpkgdepversion ${f})"
|
||||
fi
|
||||
# If dependency is a development pkg switch it to 32bit.
|
||||
if [[ $pkgn == *-devel ]]; then
|
||||
echo " RDEP: $f -> ${pkgn}-32bit${pkgv} (development)"
|
||||
printf "${pkgn}-32bit${pkgv} " >> ${destdir32}/rdeps
|
||||
continue
|
||||
fi
|
||||
# If dependency does not have "shlib-provides" do not
|
||||
# change it to 32bit.
|
||||
for x in ${subpackages}; do
|
||||
if [ "$x" = "$pkgn" ]; then
|
||||
found=1
|
||||
break
|
||||
fi
|
||||
done
|
||||
if [ -z "$found" ]; then
|
||||
# Dependency is not a subpkg, check shlib-provides
|
||||
# via binpkgs.
|
||||
_shprovides="$($XBPS_QUERY_CMD -R --property=shlib-provides "$pkgn")"
|
||||
if [ -n "${_shprovides}" ]; then
|
||||
echo " RDEP: $f -> ${pkgn}-32bit${pkgv} (shlib-provides)"
|
||||
printf "${pkgn}-32bit${pkgv} " >> ${destdir32}/rdeps
|
||||
else
|
||||
echo " RDEP: $f -> ${pkgn}${pkgv} (no shlib-provides)"
|
||||
printf "${pkgn}${pkgv} " >> ${destdir32}/rdeps
|
||||
fi
|
||||
else
|
||||
if [ -s ${XBPS_DESTDIR}/${pkgn}-${version}/shlib-provides ]; then
|
||||
# Dependency is a subpkg; check if it provides any shlib
|
||||
# and convert to 32bit if true.
|
||||
echo " RDEP: $f -> ${pkgn}-32bit${pkgv} (subpkg, shlib-provides)"
|
||||
printf "${pkgn}-32bit${pkgv} " >> ${destdir32}/rdeps
|
||||
else
|
||||
echo " RDEP: $f -> ${pkgn}${pkgv} (subpkg, no shlib-provides)"
|
||||
printf "${pkgn}${pkgv} " >> ${destdir32}/rdeps
|
||||
fi
|
||||
fi
|
||||
done
|
||||
fi
|
||||
# If it's a development pkg add a dependency to the 64bit pkg.
|
||||
if [[ $pkgn == *-devel ]]; then
|
||||
echo " RDEP: ${pkgver}"
|
||||
printf "${pkgver} " >> ${destdir32}/rdeps
|
||||
fi
|
||||
printf "\n" >> ${destdir32}/rdeps
|
||||
}
|
|
@ -61,7 +61,7 @@ hook() {
|
|||
elif [ "$lib32mode" = "full" ]; then
|
||||
# Full 32bit mode; copy everything to new destdir.
|
||||
mkdir -p ${destdir32}
|
||||
cp -a ${PKGDESTDIR}/. ${destdir32}/
|
||||
cp -a ${PKGDESTDIR}/* ${destdir32}/
|
||||
# remove symlink
|
||||
if [ -h ${destdir32}/usr/lib32 ]; then
|
||||
rm ${destdir32}/usr/lib32
|
||||
|
@ -74,11 +74,74 @@ hook() {
|
|||
if [[ ${pkgname} == *-devel ]]; then
|
||||
mkdir -p ${destdir32}
|
||||
fi
|
||||
|
||||
if [ ! -d ${destdir32} ]; then
|
||||
return
|
||||
fi
|
||||
|
||||
# If the rdeps file exist (runtime deps), copy and then modify it for
|
||||
# 32bit dependencies.
|
||||
trap - ERR
|
||||
|
||||
: > ${destdir32}/rdeps
|
||||
|
||||
if [ -s "$PKGDESTDIR/rdeps" ]; then
|
||||
if [ -n "$lib32depends" ]; then
|
||||
_deps="${lib32depends}"
|
||||
else
|
||||
_deps="$(<${PKGDESTDIR}/rdeps)"
|
||||
fi
|
||||
for f in ${_deps}; do
|
||||
unset found pkgn pkgv _shprovides
|
||||
|
||||
pkgn="$($XBPS_UHELPER_CMD getpkgdepname $f)"
|
||||
if [ -z "${pkgn}" ]; then
|
||||
pkgn="$($XBPS_UHELPER_CMD getpkgname $f)"
|
||||
if [ -z "${pkgn}" ]; then
|
||||
msg_error "$pkgver: invalid dependency $f\n"
|
||||
fi
|
||||
pkgv="-$($XBPS_UHELPER_CMD getpkgversion ${f})"
|
||||
else
|
||||
pkgv="$($XBPS_UHELPER_CMD getpkgdepversion ${f})"
|
||||
fi
|
||||
# If dependency is a development pkg switch it to 32bit.
|
||||
if [[ $pkgn == *-devel ]]; then
|
||||
echo " RDEP: $f -> ${pkgn}-32bit${pkgv} (development)"
|
||||
printf "${pkgn}-32bit${pkgv} " >> ${destdir32}/rdeps
|
||||
continue
|
||||
fi
|
||||
# If dependency does not have "shlib-provides" do not
|
||||
# change it to 32bit.
|
||||
for x in ${subpackages}; do
|
||||
if [ "$x" = "$pkgn" ]; then
|
||||
found=1
|
||||
break
|
||||
fi
|
||||
done
|
||||
if [ -z "$found" ]; then
|
||||
# Dependency is not a subpkg, check shlib-provides
|
||||
# via binpkgs.
|
||||
_shprovides="$($XBPS_QUERY_CMD -R --property=shlib-provides "$pkgn")"
|
||||
if [ -n "${_shprovides}" ]; then
|
||||
echo " RDEP: $f -> ${pkgn}-32bit${pkgv} (shlib-provides)"
|
||||
printf "${pkgn}-32bit${pkgv} " >> ${destdir32}/rdeps
|
||||
else
|
||||
echo " RDEP: $f -> ${pkgn}${pkgv} (no shlib-provides)"
|
||||
printf "${pkgn}${pkgv} " >> ${destdir32}/rdeps
|
||||
fi
|
||||
else
|
||||
if [ -s ${XBPS_DESTDIR}/${pkgn}-${version}/shlib-provides ]; then
|
||||
# Dependency is a subpkg; check if it provides any shlib
|
||||
# and convert to 32bit if true.
|
||||
echo " RDEP: $f -> ${pkgn}-32bit${pkgv} (subpkg, shlib-provides)"
|
||||
printf "${pkgn}-32bit${pkgv} " >> ${destdir32}/rdeps
|
||||
else
|
||||
echo " RDEP: $f -> ${pkgn}${pkgv} (subpkg, no shlib-provides)"
|
||||
printf "${pkgn}${pkgv} " >> ${destdir32}/rdeps
|
||||
fi
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
# Also install additional files set via "lib32files".
|
||||
for f in ${lib32files}; do
|
||||
echo "$pkgver: installing additional files: $f ..."
|
||||
|
@ -86,7 +149,6 @@ hook() {
|
|||
mkdir -p ${_targetdir/\/usr\/lib/\/usr\/lib32}
|
||||
cp -a ${PKGDESTDIR}/${f} ${_targetdir/\/usr\/lib/\/usr\/lib32}
|
||||
done
|
||||
|
||||
# Additional symlinks to the native libdir.
|
||||
for f in ${lib32symlinks}; do
|
||||
echo "$pkgver: symlinking $f to the native libdir..."
|
||||
|
@ -97,4 +159,10 @@ hook() {
|
|||
fi
|
||||
ln -sfr ${destdir32}/usr/lib32/$f ${destdir32}/usr/lib/$f
|
||||
done
|
||||
# If it's a development pkg add a dependency to the 64bit pkg.
|
||||
if [[ $pkgn == *-devel ]]; then
|
||||
echo " RDEP: ${pkgver}"
|
||||
printf "${pkgver} " >> ${destdir32}/rdeps
|
||||
fi
|
||||
printf "\n" >> ${destdir32}/rdeps
|
||||
}
|
|
@ -6,30 +6,19 @@ collect_sonames() {
|
|||
local _pattern="^[[:alnum:]]+(.*)+\.so(\.[0-9]+)*$"
|
||||
local _versioned_pattern="^[[:alnum:]]+(.*)+\.so(\.[0-9]+)+$"
|
||||
local _tmpfile=$(mktemp) || exit 1
|
||||
local _mainpkg="$2"
|
||||
local _shlib_dir="${XBPS_STATEDIR}/shlib-provides"
|
||||
local _no_soname=$(mktemp) || exit 1
|
||||
|
||||
mkdir -p "${_shlib_dir}" || exit 1
|
||||
if [ ! -d ${_destdir} ]; then
|
||||
rm -f ${_tmpfile}
|
||||
rm -f ${_no_soname}
|
||||
return 0
|
||||
fi
|
||||
|
||||
|
||||
# real pkg
|
||||
find ${_destdir} -type f -name "*.so*" | while read f; do
|
||||
_fname="${f##*/}"
|
||||
case "$(file -bi "$f")" in
|
||||
application/x-sharedlib*|application/x-pie-executable*)
|
||||
# shared library
|
||||
_soname=$(${OBJDUMP} -p "$f"|awk '/SONAME/{print $2}')
|
||||
if [ -n "$noshlibprovides" ]; then
|
||||
# register all shared lib for rt-deps between sub-pkg
|
||||
echo "${_fname}" >>${_no_soname}
|
||||
continue
|
||||
fi
|
||||
_soname=$(${OBJDUMP} -p "$f"|grep SONAME|awk '{print $2}')
|
||||
# Register all versioned sonames, and
|
||||
# unversioned sonames only when in libdir.
|
||||
if [[ ${_soname} =~ ${_versioned_pattern} ]] ||
|
||||
|
@ -38,9 +27,6 @@ collect_sonames() {
|
|||
-e ${_destdir}/usr/lib32/${_fname} ) ]]; then
|
||||
echo "${_soname}" >> ${_tmpfile}
|
||||
echo " SONAME ${_soname} from ${f##${_destdir}}"
|
||||
else
|
||||
# register all shared lib for rt-deps between sub-pkg
|
||||
echo "${_fname}" >>${_no_soname}
|
||||
fi
|
||||
;;
|
||||
esac
|
||||
|
@ -52,37 +38,19 @@ collect_sonames() {
|
|||
if [ -s "${_tmpfile}" ]; then
|
||||
tr '\n' ' ' < "${_tmpfile}" > ${_destdir}/shlib-provides
|
||||
echo >> ${_destdir}/shlib-provides
|
||||
if [ "$_mainpkg" ]; then
|
||||
cp "${_tmpfile}" "${_shlib_dir}/${pkgname}.soname"
|
||||
fi
|
||||
fi
|
||||
if [ "$_mainpkg" ] && [ -s "${_no_soname}" ]; then
|
||||
mv "${_no_soname}" "${_shlib_dir}/${pkgname}.nosoname"
|
||||
else
|
||||
rm -f ${_no_soname}
|
||||
fi
|
||||
rm -f ${_tmpfile}
|
||||
}
|
||||
|
||||
hook() {
|
||||
local _destdir32=${XBPS_DESTDIR}/${pkgname}-32bit-${version}
|
||||
local _mainpkg=yes
|
||||
local _pkg
|
||||
|
||||
case "$pkgname" in
|
||||
*-32bit)
|
||||
_pkgname=${pkgname%-32bit}
|
||||
for _pkg in $sourcepkg $subpackages; do
|
||||
if [ "$_pkg" = "$_pkgname" ]; then
|
||||
_mainpkg=
|
||||
break
|
||||
fi
|
||||
done
|
||||
;;
|
||||
esac
|
||||
if [ -n "$noshlibprovides" ]; then
|
||||
return 0
|
||||
fi
|
||||
|
||||
# native pkg
|
||||
collect_sonames ${PKGDESTDIR} $_mainpkg
|
||||
collect_sonames ${PKGDESTDIR}
|
||||
# 32bit pkg
|
||||
collect_sonames ${_destdir32}
|
||||
}
|
|
@ -29,15 +29,6 @@ hook() {
|
|||
fi
|
||||
done
|
||||
|
||||
if [ -d ${PKGDESTDIR}/usr/lib/libexec ]; then
|
||||
# Add exception for kconfig,
|
||||
# other packages hard-coded path to its files
|
||||
if [ "${pkgname}" != kconfig ]; then
|
||||
msg_red "${pkgver}: /usr/lib/libexec directory is not allowed!\n"
|
||||
error=1
|
||||
fi
|
||||
fi
|
||||
|
||||
for f in "$PKGDESTDIR"/*; do
|
||||
f="${f##*/}"
|
||||
case "$f" in
|
||||
|
@ -79,22 +70,8 @@ hook() {
|
|||
|
||||
# Check for l10n files in usr/lib/locale
|
||||
if [ -d ${PKGDESTDIR}/usr/lib/locale ]; then
|
||||
local locale_allow=0 ldir
|
||||
local lroot="${PKGDESTDIR}/usr/lib/locale"
|
||||
|
||||
if [ "${pkgname}" = "glibc" ]; then
|
||||
# glibc gets an exception for its included C.utf8 locale
|
||||
locale_allow=1
|
||||
for ldir in "${lroot}"/*; do
|
||||
[ "${ldir}" = "${lroot}/C.utf8" ] && continue
|
||||
locale_allow=0
|
||||
done
|
||||
fi
|
||||
|
||||
if [ "${locale_allow}" -ne 1 ]; then
|
||||
msg_red "${pkgver}: /usr/lib/locale is forbidden, use /usr/share/locale!\n"
|
||||
error=1
|
||||
fi
|
||||
msg_red "${pkgver}: /usr/lib/locale is forbidden, use /usr/share/locale!\n"
|
||||
error=1
|
||||
fi
|
||||
|
||||
# Check for bash completions in etc/bash_completion.d
|
||||
|
@ -151,11 +128,6 @@ hook() {
|
|||
error=1
|
||||
fi
|
||||
|
||||
if [ -e ${PKGDESTDIR}/usr/share/glib-2.0/schemas/gschemas.compiled ]; then
|
||||
msg_red "${pkgver}: /usr/share/glib-2.0/schemas/gschemas.compiled is forbidden. Delete it.\n"
|
||||
error=1
|
||||
fi
|
||||
|
||||
# Forbid files would be generated by mimedb trigger
|
||||
for f in XMLnamespaces aliases generic-icons globs globs2 icons \
|
||||
magic mime.cache subclasses treemagic types version ; do
|
||||
|
@ -185,7 +157,7 @@ hook() {
|
|||
_pattern="^${_shlib}\.so\.[0-9]+(.*)[[:blank:]]+${_pkgname}-[^-]+_[0-9]+"
|
||||
fi
|
||||
grep -E "${_pattern}" $mapshlibs | { \
|
||||
while read -r conflictFile conflictPkg ignore; do
|
||||
while read conflictFile conflictPkg ignore; do
|
||||
found=1
|
||||
conflictRev=${conflictFile#*.so.}
|
||||
if [ -n "$ignore" -a "$ignore" != "$XBPS_TARGET_MACHINE" ]; then
|
||||
|
|
|
@ -1,9 +0,0 @@
|
|||
#!/bin/bash
|
||||
# checks for licenses that are no longer custom in packages
|
||||
|
||||
mapfile -t licenses < common/travis/license.lst
|
||||
|
||||
for lic in "${licenses[@]}"; do
|
||||
grep -rl "custom:$lic"'[,"]' --include=template srcpkgs \
|
||||
| cut -d/ -f2 | xargs -rn1 printf "%s: $lic is no longer custom\n"
|
||||
done
|
|
@ -32,20 +32,9 @@ do
|
|||
awk -vC="$cmt" '
|
||||
# skip header
|
||||
/^$/ && !msg { msg = 1; next }
|
||||
/^author .*noreply/ && !msg {
|
||||
print "::error title=Commit Lint::" C ": authored by noreply email";
|
||||
ret=1;
|
||||
}
|
||||
/^author .*(localhost|localdomain|[(]none[)])/ && !msg {
|
||||
print "::error title=Commit Lint::" C ": authored by localhost email";
|
||||
ret=1;
|
||||
}
|
||||
!msg { next }
|
||||
# 3: long-line-is-banned-except-footnote-like-this-for-url
|
||||
(NF > 2) && (length > 80) {
|
||||
print "::error title=Commit Lint::" C ": long line: " $0
|
||||
ret = 1
|
||||
}
|
||||
(NF > 2) && (length > 80) { print "::error title=Commit Lint::" C ": long line: " $0; exit 1 }
|
||||
!subject {
|
||||
if (length > 50) { print "::warning title=Commit Lint::" C ": subject is a bit long" }
|
||||
if (!($0 ~ ":" || $0 ~ "^Take over maintainership " || $0 ~ "^Orphan ")) { print "::error title=Commit Lint::" C ": subject does not follow CONTRIBUTING.md guildelines"; exit 1 }
|
||||
|
@ -56,11 +45,7 @@ do
|
|||
subject = 1; next
|
||||
}
|
||||
/^$/ { body = 1; next }
|
||||
!body {
|
||||
print "::error title=Commit Lint::" C ": second line must be blank"
|
||||
ret = 1
|
||||
}
|
||||
END { exit ret }
|
||||
!body { print "::error title=Commit Lint::" C ": second line must be blank"; exit 1 }
|
||||
' || status=1
|
||||
done
|
||||
exit $status
|
||||
|
|
|
@ -25,7 +25,7 @@ else
|
|||
fi
|
||||
|
||||
declare -A newly_built conflicts_cache providers_cache pairs owners
|
||||
repositories=("--repository=${binpkgs}/bootstrap" "--repository=${binpkgs}" "--repository=${binpkgs}/nonfree")
|
||||
repositories=("--repository=${binpkgs}" "--repository=${binpkgs}/nonfree")
|
||||
rv=0
|
||||
|
||||
template_exists() {
|
||||
|
@ -109,7 +109,7 @@ list_interesting_files() {
|
|||
if partial_check; then
|
||||
list_newly_built_files
|
||||
else
|
||||
xlocate / | sed s'/ -> .*//' | grep -F -f <(xlocate / | sed 's/[^[:space:]]*[[:space:]]*//' | sed s'/ -> .*//' | sort | uniq -d)
|
||||
xlocate / | sed s'/ -> .*//' | grep -F -f <(xlocate / | cut -f 2- | sed s'/ -> .*//' | sort | uniq -d)
|
||||
fi
|
||||
}
|
||||
|
||||
|
|
|
@ -84,10 +84,10 @@ def find_cycles(depmap, xbpsdir):
|
|||
try: deps = pkgs.pop(p)
|
||||
except KeyError: break
|
||||
|
||||
# Any of the dependencies here contributes to a cycle
|
||||
# Any of the dependencies here contributes to a cycle
|
||||
p = min(deps)
|
||||
if len(deps) > 1:
|
||||
print('Multipath: {} -> {}, choosing first'.format(p, deps))
|
||||
print('Mulitpath: {} -> {}, choosing first'.format(p, deps))
|
||||
|
||||
if cycles:
|
||||
print('Cycle: ' + ' -> '.join(cycles) + '\n')
|
||||
|
@ -97,14 +97,10 @@ if __name__ == '__main__':
|
|||
parser = ArgumentParser(description='Cycle detector for xbps-src')
|
||||
parser.add_argument('-j', '--jobs', default=None,
|
||||
type=int, help='Number of parallel jobs')
|
||||
parser.add_argument('-c', '--cachedir', default=None,
|
||||
help='Directory used to cache build dependencies (must exist)')
|
||||
parser.add_argument('-c', '--cachedir',
|
||||
default=None, help='''Directory to use as cache for xbps-src show-build-deps. Directory must exist already.''')
|
||||
parser.add_argument('-d', '--directory',
|
||||
default=None, help='Path to void-packages repo')
|
||||
parser.add_argument('-Q', dest='check_pkgs', action='store_const',
|
||||
const='yes', help='Use build dependencies for check -Q')
|
||||
parser.add_argument('-K', dest='check_pkgs', action='store_const',
|
||||
const='full', help='Use build dependencies for check -K')
|
||||
|
||||
args = parser.parse_args()
|
||||
|
||||
|
@ -112,15 +108,13 @@ if __name__ == '__main__':
|
|||
try: args.directory = os.environ['XBPS_DISTDIR']
|
||||
except KeyError: args.directory = '.'
|
||||
|
||||
if args.check_pkgs:
|
||||
os.environ['XBPS_CHECK_PKGS'] = args.check_pkgs
|
||||
cachedir = args.cachedir
|
||||
|
||||
pool = multiprocessing.Pool(processes = args.jobs)
|
||||
|
||||
pattern = os.path.join(args.directory, 'srcpkgs', '*')
|
||||
pkgs = {os.path.realpath(p) for p in glob.iglob(pattern)}
|
||||
|
||||
depargs = ((os.path.basename(g), args.directory, args.cachedir) for g in pkgs)
|
||||
depmap = dict(pool.starmap(enum_depends, depargs))
|
||||
depmap = dict(pool.starmap(enum_depends,
|
||||
((os.path.basename(g), args.directory, cachedir)
|
||||
for g in glob.iglob(pattern))))
|
||||
|
||||
find_cycles(depmap, args.directory)
|
||||
|
|
2424
common/shlibs
2424
common/shlibs
File diff suppressed because it is too large
Load diff
|
@ -10,7 +10,7 @@ if [ "$3" = 1 ]; then
|
|||
test="-Q"
|
||||
fi
|
||||
|
||||
PKGS=$(/hostrepo/xbps-src $test sort-dependencies $(cat /tmp/templates))
|
||||
PKGS=$(/hostrepo/xbps-src sort-dependencies $(cat /tmp/templates))
|
||||
|
||||
for pkg in ${PKGS}; do
|
||||
/hostrepo/xbps-src -j$(nproc) -s -H "$HOME"/hostdir $arch $test pkg "$pkg"
|
||||
|
|
|
@ -10,10 +10,9 @@ case "$tip" in
|
|||
*) tip="${tip%% *}" ;;
|
||||
esac
|
||||
|
||||
base="$(git merge-base origin/HEAD "$tip")"
|
||||
|
||||
[ $(git rev-list --count "$tip" "^$base") -lt 200 ] || {
|
||||
echo "::error title=Branch out of date::Your branch is too out of date. Please rebase on upstream and force-push."
|
||||
base="$(git merge-base FETCH_HEAD "$tip")" || {
|
||||
echo "Your branches is based on too old copy."
|
||||
echo "Please rebase to newest copy."
|
||||
exit 1
|
||||
}
|
||||
|
||||
|
@ -24,6 +23,5 @@ git diff-tree -r --no-renames --name-only --diff-filter=AM \
|
|||
"$base" "$tip" \
|
||||
-- 'srcpkgs/*/template' |
|
||||
cut -d/ -f 2 |
|
||||
xargs ./xbps-src sort-dependencies |
|
||||
tee /tmp/templates |
|
||||
sed "s/^/ /" >&2
|
||||
|
|
|
@ -6,33 +6,20 @@ export XBPS_TARGET_ARCH="$2" XBPS_DISTDIR=/hostrepo
|
|||
|
||||
if [ "$1" != "$XBPS_TARGET_ARCH" ]; then
|
||||
triplet="$(/hostrepo/xbps-src -a "$XBPS_TARGET_ARCH" show-var XBPS_CROSS_TRIPLET)"
|
||||
CONFDIR="-C /usr/$triplet/etc/xbps.d"
|
||||
else
|
||||
CONFDIR="-C /etc/xbps.d"
|
||||
ROOTDIR="-r /usr/$triplet"
|
||||
fi
|
||||
|
||||
mkdir /check-install
|
||||
|
||||
mkdir -p /check-install/var/db/xbps/keys
|
||||
cp /var/db/xbps/keys/* /check-install/var/db/xbps/keys/
|
||||
|
||||
ADDREPO="--repository=$HOME/hostdir/binpkgs/bootstrap
|
||||
--repository=$HOME/hostdir/binpkgs
|
||||
--repository=$HOME/hostdir/binpkgs/nonfree"
|
||||
ROOTDIR="-r /check-install"
|
||||
|
||||
xbps-install $ROOTDIR $ADDREPO $CONFDIR -S
|
||||
ADDREPO="--repository=$HOME/hostdir/binpkgs --repository=$HOME/hostdir/binpkgs/nonfree"
|
||||
|
||||
while read -r pkg; do
|
||||
for subpkg in $(xsubpkg $pkg); do
|
||||
/bin/echo -e "\x1b[32mTrying to install dependants of $subpkg:\x1b[0m"
|
||||
for dep in $(xbps-query $ADDREPO -RX "$subpkg"); do
|
||||
xbps-install \
|
||||
$ROOTDIR $ADDREPO $CONFDIR \
|
||||
-ny \
|
||||
$ROOTDIR $ADDREPO \
|
||||
-Sny \
|
||||
"$subpkg" "$(xbps-uhelper getpkgname "$dep")"
|
||||
ret="$?"
|
||||
if [ "$ret" -eq 8 ] || [ "$ret" -eq 11 ]; then
|
||||
if [ $? -eq 8 ]; then
|
||||
/bin/echo -e "\x1b[31mFailed to install '$subpkg' and '$dep'\x1b[0m"
|
||||
exit 1
|
||||
fi
|
||||
|
|
9
common/travis/fetch_upstream.sh
Executable file
9
common/travis/fetch_upstream.sh
Executable file
|
@ -0,0 +1,9 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# changed_templates.sh
|
||||
|
||||
# required by git 2.35.2+
|
||||
git config --global --add safe.directory "$PWD"
|
||||
|
||||
/bin/echo -e '\x1b[32mFetching upstream...\x1b[0m'
|
||||
git fetch --depth 200 https://github.com/void-linux/void-packages.git master
|
|
@ -22,13 +22,9 @@ APSL-1.0
|
|||
APSL-1.1
|
||||
APSL-1.2
|
||||
APSL-2.0
|
||||
ASWF-Digital-Assets-1.0
|
||||
ASWF-Digital-Assets-1.1
|
||||
Abstyles
|
||||
AdaCore-doc
|
||||
Adobe-2006
|
||||
Adobe-Glyph
|
||||
Adobe-Utopia
|
||||
Afmparse
|
||||
Aladdin
|
||||
Apache-1.0
|
||||
|
@ -40,19 +36,14 @@ Artistic-1.0-Perl
|
|||
Artistic-1.0-cl8
|
||||
Artistic-1.0
|
||||
Artistic-2.0
|
||||
Asterisk-exception
|
||||
Autoconf-exception-2.0
|
||||
Autoconf-exception-3.0
|
||||
Autoconf-exception-generic-3.0
|
||||
Autoconf-exception-generic
|
||||
Autoconf-exception-macro
|
||||
BSD-1-Clause
|
||||
BSD-2-Clause-Patent
|
||||
BSD-2-Clause-Views
|
||||
BSD-2-Clause
|
||||
BSD-3-Clause-Attribution
|
||||
BSD-3-Clause-Clear
|
||||
BSD-3-Clause-HP
|
||||
BSD-3-Clause-LBNL
|
||||
BSD-3-Clause-Modification
|
||||
BSD-3-Clause-No-Military-License
|
||||
|
@ -60,20 +51,12 @@ BSD-3-Clause-No-Nuclear-License-2014
|
|||
BSD-3-Clause-No-Nuclear-License
|
||||
BSD-3-Clause-No-Nuclear-Warranty
|
||||
BSD-3-Clause-Open-MPI
|
||||
BSD-3-Clause-Sun
|
||||
BSD-3-Clause-flex
|
||||
BSD-3-Clause
|
||||
BSD-4-Clause-Shortened
|
||||
BSD-4-Clause-UC
|
||||
BSD-4-Clause
|
||||
BSD-4.3RENO
|
||||
BSD-4.3TAHOE
|
||||
BSD-Advertising-Acknowledgement
|
||||
BSD-Attribution-HPND-disclaimer
|
||||
BSD-Inferno-Nettverk
|
||||
BSD-Protection
|
||||
BSD-Source-Code
|
||||
BSD-Systemics
|
||||
BSL-1.0
|
||||
BUSL-1.1
|
||||
Baekmuk
|
||||
|
@ -83,13 +66,10 @@ Beerware
|
|||
Bison-exception-2.2
|
||||
BitTorrent-1.0
|
||||
BitTorrent-1.1
|
||||
Bitstream-Charter
|
||||
Bitstream-Vera
|
||||
BlueOak-1.0.0
|
||||
Boehm-GC
|
||||
Bootloader-exception
|
||||
Borceux
|
||||
Brian-Gladman-3-Clause
|
||||
C-UDA-1.0
|
||||
CAL-1.0-Combined-Work-Exception
|
||||
CAL-1.0
|
||||
|
@ -119,7 +99,6 @@ CC-BY-NC-ND-3.0-IGO
|
|||
CC-BY-NC-ND-3.0
|
||||
CC-BY-NC-ND-4.0
|
||||
CC-BY-NC-SA-1.0
|
||||
CC-BY-NC-SA-2.0-DE
|
||||
CC-BY-NC-SA-2.0-FR
|
||||
CC-BY-NC-SA-2.0-UK
|
||||
CC-BY-NC-SA-2.0
|
||||
|
@ -141,7 +120,6 @@ CC-BY-SA-2.1-JP
|
|||
CC-BY-SA-2.5
|
||||
CC-BY-SA-3.0-AT
|
||||
CC-BY-SA-3.0-DE
|
||||
CC-BY-SA-3.0-IGO
|
||||
CC-BY-SA-3.0
|
||||
CC-BY-SA-4.0
|
||||
CC-PDDC
|
||||
|
@ -163,9 +141,7 @@ CERN-OHL-1.2
|
|||
CERN-OHL-P-2.0
|
||||
CERN-OHL-S-2.0
|
||||
CERN-OHL-W-2.0
|
||||
CFITSIO
|
||||
CLISP-exception-2.0
|
||||
CMU-Mach
|
||||
CNRI-Jython
|
||||
CNRI-Python-GPL-Compatible
|
||||
CNRI-Python
|
||||
|
@ -177,17 +153,13 @@ CUA-OPL-1.0
|
|||
Caldera
|
||||
ClArtistic
|
||||
Classpath-exception-2.0
|
||||
Clips
|
||||
Community-Spec-1.0
|
||||
Condor-1.1
|
||||
Cornell-Lossless-JPEG
|
||||
Cronyx
|
||||
Crossword
|
||||
CrystalStacker
|
||||
Cube
|
||||
D-FSL-1.0
|
||||
DL-DE-BY-2.0
|
||||
DL-DE-ZERO-2.0
|
||||
DOC
|
||||
DRL-1.0
|
||||
DSDP
|
||||
|
@ -208,23 +180,18 @@ Elastic-2.0
|
|||
Entessa
|
||||
ErlPL-1.1
|
||||
Eurosym
|
||||
FBM
|
||||
FDK-AAC
|
||||
FLTK-exception
|
||||
FSFAP
|
||||
FSFUL
|
||||
FSFULLR
|
||||
FSFULLRWD
|
||||
FTL
|
||||
Fair
|
||||
Fawkes-Runtime-exception
|
||||
Ferguson-Twofish
|
||||
Font-exception-2.0
|
||||
Frameworx-1.0
|
||||
FreeBSD-DOC
|
||||
FreeImage
|
||||
Furuseth
|
||||
GCC-exception-2.0-note
|
||||
GCC-exception-2.0
|
||||
GCC-exception-3.1
|
||||
GD
|
||||
|
@ -248,13 +215,10 @@ GFDL-1.3-only
|
|||
GFDL-1.3-or-later
|
||||
GL2PS
|
||||
GLWTPL
|
||||
GNAT-exception
|
||||
GNU-compiler-exception
|
||||
GPL-1.0-only
|
||||
GPL-1.0-or-later
|
||||
GPL-2.0-only
|
||||
GPL-2.0-or-later
|
||||
GPL-3.0-interface-exception
|
||||
GPL-3.0-linking-exception
|
||||
GPL-3.0-linking-source-exception
|
||||
GPL-3.0-only
|
||||
|
@ -265,19 +229,6 @@ GStreamer-exception-2008
|
|||
Giftware
|
||||
Glide
|
||||
Glulxe
|
||||
Graphics-Gems
|
||||
HP-1986
|
||||
HP-1989
|
||||
HPND-DEC
|
||||
HPND-Markus-Kuhn
|
||||
HPND-Pbmplus
|
||||
HPND-UC
|
||||
HPND-doc-sell
|
||||
HPND-doc
|
||||
HPND-export-US-modify
|
||||
HPND-export-US
|
||||
HPND-sell-regexpr
|
||||
HPND-sell-variant-MIT-disclaimer
|
||||
HPND-sell-variant
|
||||
HPND
|
||||
HTMLTIDY
|
||||
|
@ -285,8 +236,6 @@ HaskellReport
|
|||
Hippocratic-2.1
|
||||
IBM-pibs
|
||||
ICU
|
||||
IEC-Code-Components-EULA
|
||||
IJG-short
|
||||
IJG
|
||||
IPA
|
||||
IPL-1.0
|
||||
|
@ -294,19 +243,14 @@ ISC
|
|||
ImageMagick
|
||||
Imlib2
|
||||
Info-ZIP
|
||||
Inner-Net-2.0
|
||||
Intel-ACPI
|
||||
Intel
|
||||
Interbase-1.0
|
||||
JPL-image
|
||||
JPNIC
|
||||
JSON
|
||||
Jam
|
||||
JasPer-2.0
|
||||
Kastrup
|
||||
Kazlib
|
||||
KiCad-libraries-exception
|
||||
Knuth-CTAN
|
||||
LAL-1.2
|
||||
LAL-1.3
|
||||
LGPL-2.0-only
|
||||
|
@ -317,9 +261,7 @@ LGPL-3.0-linking-exception
|
|||
LGPL-3.0-only
|
||||
LGPL-3.0-or-later
|
||||
LGPLLR
|
||||
LLGPL
|
||||
LLVM-exception
|
||||
LOOP
|
||||
LPL-1.0
|
||||
LPL-1.02
|
||||
LPPL-1.0
|
||||
|
@ -330,7 +272,6 @@ LPPL-1.3c
|
|||
LZMA-SDK-9.11-to-9.20
|
||||
LZMA-SDK-9.22
|
||||
LZMA-exception
|
||||
Latex2e-translated-notice
|
||||
Latex2e
|
||||
Leptonica
|
||||
LiLiQ-P-1.1
|
||||
|
@ -339,26 +280,17 @@ LiLiQ-Rplus-1.1
|
|||
Libpng
|
||||
Libtool-exception
|
||||
Linux-OpenIB
|
||||
Linux-man-pages-1-para
|
||||
Linux-man-pages-copyleft-2-para
|
||||
Linux-man-pages-copyleft-var
|
||||
Linux-man-pages-copyleft
|
||||
Linux-syscall-note
|
||||
Lucida-Bitmap-Fonts
|
||||
MIT-0
|
||||
MIT-CMU
|
||||
MIT-Festival
|
||||
MIT-Modern-Variant
|
||||
MIT-Wu
|
||||
MIT-advertising
|
||||
MIT-enna
|
||||
MIT-feh
|
||||
MIT-open-group
|
||||
MIT-testregex
|
||||
MIT
|
||||
MITNFA
|
||||
MMIXware
|
||||
MPEG-SSG
|
||||
MPL-1.0
|
||||
MPL-1.1
|
||||
MPL-2.0-no-copyleft-exception
|
||||
|
@ -368,8 +300,6 @@ MS-PL
|
|||
MS-RL
|
||||
MTLL
|
||||
MakeIndex
|
||||
Martin-Birgmeier
|
||||
McPhee-slideshow
|
||||
Minpack
|
||||
MirOS
|
||||
Motosoto
|
||||
|
@ -386,7 +316,6 @@ NGPL
|
|||
NICTA-1.0
|
||||
NIST-PD-fallback
|
||||
NIST-PD
|
||||
NIST-Software
|
||||
NLOD-1.0
|
||||
NLOD-2.0
|
||||
NLPL
|
||||
|
@ -411,7 +340,6 @@ OCLC-2.0
|
|||
OCaml-LGPL-linking-exception
|
||||
ODC-By-1.0
|
||||
ODbL-1.0
|
||||
OFFIS
|
||||
OFL-1.0-RFN
|
||||
OFL-1.0-no-RFN
|
||||
OFL-1.0
|
||||
|
@ -441,10 +369,8 @@ OLDAP-2.5
|
|||
OLDAP-2.6
|
||||
OLDAP-2.7
|
||||
OLDAP-2.8
|
||||
OLFL-1.3
|
||||
OML
|
||||
OPL-1.0
|
||||
OPL-UK-3.0
|
||||
OPUBL-1.0
|
||||
OSET-PL-2.1
|
||||
OSL-1.0
|
||||
|
@ -453,9 +379,7 @@ OSL-2.0
|
|||
OSL-2.1
|
||||
OSL-3.0
|
||||
OpenJDK-assembly-exception-1.0
|
||||
OpenPBS-2.3
|
||||
OpenSSL
|
||||
PADL
|
||||
PDDL-1.0
|
||||
PHP-3.0
|
||||
PHP-3.01
|
||||
|
@ -469,8 +393,6 @@ PolyForm-Small-Business-1.0.0
|
|||
PostgreSQL
|
||||
Python-2.0.1
|
||||
Python-2.0
|
||||
QPL-1.0-INRIA-2004-exception
|
||||
QPL-1.0-INRIA-2004
|
||||
QPL-1.0
|
||||
Qhull
|
||||
Qt-GPL-exception-1.0
|
||||
|
@ -484,21 +406,17 @@ RSA-MD
|
|||
RSCPL
|
||||
Rdisc
|
||||
Ruby
|
||||
SANE-exception
|
||||
SAX-PD
|
||||
SCEA
|
||||
SGI-B-1.0
|
||||
SGI-B-1.1
|
||||
SGI-B-2.0
|
||||
SGI-OpenGL
|
||||
SGP4
|
||||
SHL-0.5
|
||||
SHL-0.51
|
||||
SHL-2.0
|
||||
SHL-2.1
|
||||
SISSL-1.2
|
||||
SISSL
|
||||
SL
|
||||
SMLNJ
|
||||
SMPPL
|
||||
SNIA
|
||||
|
@ -506,7 +424,6 @@ SPL-1.0
|
|||
SSH-OpenSSH
|
||||
SSH-short
|
||||
SSPL-1.0
|
||||
SWI-exception
|
||||
SWL
|
||||
Saxpath
|
||||
SchemeReport
|
||||
|
@ -514,38 +431,25 @@ Sendmail-8.23
|
|||
Sendmail
|
||||
SimPL-2.0
|
||||
Sleepycat
|
||||
Soundex
|
||||
Spencer-86
|
||||
Spencer-94
|
||||
Spencer-99
|
||||
SugarCRM-1.1.3
|
||||
SunPro
|
||||
Swift-exception
|
||||
Symlinks
|
||||
TAPR-OHL-1.0
|
||||
TCL
|
||||
TCP-wrappers
|
||||
TMate
|
||||
TORQUE-1.1
|
||||
TOSL
|
||||
TPDL
|
||||
TPL-1.0
|
||||
TTWL
|
||||
TTYP0
|
||||
TU-Berlin-1.0
|
||||
TU-Berlin-2.0
|
||||
TermReadKey
|
||||
Texinfo-exception
|
||||
UBDL-exception
|
||||
UCAR
|
||||
UCL-1.0
|
||||
UPL-1.0
|
||||
URT-RLE
|
||||
Unicode-DFS-2015
|
||||
Unicode-DFS-2016
|
||||
Unicode-TOU
|
||||
Universal-FOSS-exception-1.0
|
||||
UnixCrypt
|
||||
Unlicense
|
||||
VOSTROM
|
||||
VSL-1.0
|
||||
|
@ -555,16 +459,13 @@ W3C-20150513
|
|||
W3C
|
||||
WTFPL
|
||||
Watcom-1.0
|
||||
Widget-Workshop
|
||||
Wsuipa
|
||||
WxWindows-exception-3.1
|
||||
X11-distribute-modifications-variant
|
||||
X11
|
||||
XFree86-1.1
|
||||
XSkat
|
||||
Xdebug-1.03
|
||||
Xerox
|
||||
Xfig
|
||||
Xnet
|
||||
YPL-1.0
|
||||
YPL-1.1
|
||||
|
@ -572,18 +473,14 @@ ZPL-1.1
|
|||
ZPL-2.0
|
||||
ZPL-2.1
|
||||
Zed
|
||||
Zeeff
|
||||
Zend-2.0
|
||||
Zimbra-1.3
|
||||
Zimbra-1.4
|
||||
Zlib
|
||||
blessing
|
||||
bzip2-1.0.6
|
||||
check-cvs
|
||||
checkmk
|
||||
copyleft-next-0.3.0
|
||||
copyleft-next-0.3.1
|
||||
cryptsetup-OpenSSL-exception
|
||||
curl
|
||||
deprecated_AGPL-1.0
|
||||
deprecated_AGPL-3.0
|
||||
|
@ -617,45 +514,27 @@ deprecated_bzip2-1.0.5
|
|||
deprecated_eCos-2.0
|
||||
deprecated_wxWindows
|
||||
diffmark
|
||||
dtoa
|
||||
dvipdfm
|
||||
eCos-exception-2.0
|
||||
eGenix
|
||||
etalab-2.0
|
||||
freertos-exception-2.0
|
||||
fwlw
|
||||
gSOAP-1.3b
|
||||
gnu-javamail-exception
|
||||
gnuplot
|
||||
i2p-gpl-java-exception
|
||||
iMatix
|
||||
libpng-2.0
|
||||
libpri-OpenH323-exception
|
||||
libselinux-1.0
|
||||
libtiff
|
||||
libutil-David-Nugent
|
||||
lsof
|
||||
magaz
|
||||
metamail
|
||||
mif-exception
|
||||
mpi-permissive
|
||||
mpich2
|
||||
mplus
|
||||
openvpn-openssl-exception
|
||||
pnmstitch
|
||||
psfrag
|
||||
psutils
|
||||
python-ldap
|
||||
snprintf
|
||||
ssh-keyscan
|
||||
stunnel-exception
|
||||
swrule
|
||||
u-boot-exception-2.0
|
||||
ulem
|
||||
vsftpd-openssl-exception
|
||||
w3m
|
||||
x11vnc-openssl-exception
|
||||
xinetd
|
||||
xlock
|
||||
xpp
|
||||
zlib-acknowledgement
|
||||
|
|
|
@ -2,6 +2,8 @@
|
|||
#
|
||||
# prepare.sh
|
||||
|
||||
[ "$XLINT" ] && exit 0
|
||||
|
||||
/bin/echo -e '\x1b[32mUpdating etc/conf...\x1b[0m'
|
||||
echo XBPS_BUILD_ENVIRONMENT=void-packages-ci >> etc/conf
|
||||
echo XBPS_ALLOW_RESTRICTED=yes >> etc/conf
|
||||
|
|
|
@ -7,8 +7,7 @@ export XBPS_TARGET_ARCH="$2" XBPS_DISTDIR=/hostrepo
|
|||
while read -r pkg; do
|
||||
for subpkg in $(xsubpkg $pkg); do
|
||||
/bin/echo -e "\x1b[32mFiles of $subpkg:\x1b[0m"
|
||||
xbps-query --repository=$HOME/hostdir/binpkgs/bootstrap \
|
||||
--repository=$HOME/hostdir/binpkgs \
|
||||
xbps-query --repository=$HOME/hostdir/binpkgs \
|
||||
--repository=$HOME/hostdir/binpkgs/nonfree \
|
||||
-i -f "$subpkg" ||
|
||||
/bin/echo -e "\x1b[33m $subpkg wasn't found\x1b[0m"
|
||||
|
|
|
@ -1,20 +0,0 @@
|
|||
#!/bin/sh
|
||||
# runs update-check on all changed templates, then errors only if there was an
|
||||
# issue with the update-check. does not error if further updates are available,
|
||||
# as there may be a good reason not to update to those versions
|
||||
|
||||
set -e
|
||||
|
||||
export XBPS_UPDATE_CHECK_VERBOSE=yes
|
||||
err=0
|
||||
|
||||
while read -r pkg; do
|
||||
/bin/echo -e "\x1b[34mVerifying update-check of $pkg:\x1b[0m"
|
||||
./xbps-src update-check "$pkg" 2>&1 > /tmp/update-check.log || err=1
|
||||
cat /tmp/update-check.log
|
||||
if grep -q 'NO VERSION' /tmp/update-check.log; then
|
||||
echo "::warning file=srcpkgs/$pkg/template,line=1,title=update-check failed::verify and fix update-check for $pkg"
|
||||
fi
|
||||
done < /tmp/templates
|
||||
|
||||
exit $err
|
|
@ -2,6 +2,8 @@
|
|||
#
|
||||
# xlint.sh
|
||||
|
||||
[ "$XLINT" ] || exit 0
|
||||
|
||||
EXITCODE=0
|
||||
read base tip < /tmp/revisions
|
||||
|
||||
|
|
|
@ -2,15 +2,14 @@
|
|||
#
|
||||
# xpkgdiff.sh
|
||||
|
||||
export XBPS_TARGET_ARCH="$2" XBPS_DISTDIR=/hostrepo XBPS_HOSTDIR="$HOME/hostdir"
|
||||
export XBPS_DISTDIR=/hostrepo XBPS_HOSTDIR="$HOME/hostdir"
|
||||
export DIFF='diff --unified=0 --report-identical-files --suppress-common-lines
|
||||
--color=always --label REPO --label BUILT'
|
||||
ARGS="-a $2 -R https://repo-ci.voidlinux.org/current"
|
||||
|
||||
while read -r pkg; do
|
||||
for subpkg in $(xsubpkg $pkg); do
|
||||
if xbps-query --repository=$HOME/hostdir/binpkgs/bootstrap \
|
||||
--repository=$HOME/hostdir/binpkgs \
|
||||
if xbps-query --repository=$HOME/hostdir/binpkgs \
|
||||
--repository=$HOME/hostdir/binpkgs/nonfree \
|
||||
-i "$subpkg" >&/dev/null; then
|
||||
/bin/echo -e "\x1b[34mFile Diff of $subpkg:\x1b[0m"
|
||||
|
|
|
@ -8,11 +8,11 @@ ARGS=("$@")
|
|||
i=0
|
||||
while [ $i -lt ${#ARGS[@]} ]; do
|
||||
arg="${ARGS[$i]}"
|
||||
if [ -n "$incpath" ]; then
|
||||
if [ "$incpath" ]; then
|
||||
if [ "$arg" = "/usr/include" ]; then
|
||||
echo "[cc-wrapper] ignoring ${incpath} $arg"
|
||||
echo "[cc-wrapper] ignoring -I $arg"
|
||||
else
|
||||
MYARGS+=("${incpath}${arg}")
|
||||
MYARGS+=("-I${arg}")
|
||||
fi
|
||||
unset incpath
|
||||
elif [ "$libpath" ]; then
|
||||
|
@ -23,13 +23,13 @@ while [ $i -lt ${#ARGS[@]} ]; do
|
|||
MYARGS+=("-L${arg}")
|
||||
fi
|
||||
unset libpath
|
||||
elif [ "$arg" = "-I" -o "$arg" = "-isystem" ]; then
|
||||
incpath="$arg"
|
||||
elif [ "$arg" = "-I" ]; then
|
||||
incpath=1
|
||||
elif [ "$arg" = "-L" ]; then
|
||||
libpath=1
|
||||
elif [ "$arg" = "-I/usr/include" -o "$arg" = "-isystem/usr/include" \
|
||||
elif [ "$arg" = "-I/usr/include" -o "$arg" = "-L/usr/lib" \
|
||||
-o "$arg" = "-L/usr/lib32" -o "$arg" = "-L/usr/lib64" \
|
||||
-o "$arg" = "-L/usr/lib" -o "$arg" = "-L/lib" ]; then
|
||||
-o "$arg" = "-L/lib" ]; then
|
||||
echo "[cc-wrapper] ignoring $arg"
|
||||
else
|
||||
MYARGS+=("${arg}")
|
||||
|
|
|
@ -124,17 +124,6 @@ check_installed_pkg() {
|
|||
return 1
|
||||
}
|
||||
|
||||
#
|
||||
# Return 0 if we will skip the check step
|
||||
#
|
||||
skip_check_step() {
|
||||
[ -z "$XBPS_CHECK_PKGS" ] ||
|
||||
[ "$XBPS_CROSS_BUILD" ] ||
|
||||
[ "$make_check" = ci-skip -a "$XBPS_BUILD_ENVIRONMENT" = void-packages-ci ] ||
|
||||
[ "$make_check" = extended -a "$XBPS_CHECK_PKGS" != full ] ||
|
||||
[ "$make_check" = no ]
|
||||
}
|
||||
|
||||
#
|
||||
# Build all dependencies required to build and run.
|
||||
#
|
||||
|
@ -148,13 +137,8 @@ install_pkg_deps() {
|
|||
local -a host_missing_deps missing_deps missing_rdeps
|
||||
|
||||
[ -z "$pkgname" ] && return 2
|
||||
skip_check_step && unset checkdepends
|
||||
|
||||
if [[ $build_style ]] || [[ $build_helper ]]; then
|
||||
style=" with"
|
||||
fi
|
||||
|
||||
[[ $build_style ]] && style+=" [$build_style]"
|
||||
[ -z "$XBPS_CHECK_PKGS" ] && unset checkdepends
|
||||
[[ $build_style ]] && style=" [$build_style]"
|
||||
|
||||
for s in $build_helper; do
|
||||
style+=" [$s]"
|
||||
|
@ -219,7 +203,7 @@ install_pkg_deps() {
|
|||
#
|
||||
# Host check dependencies.
|
||||
#
|
||||
if [[ ${checkdepends} ]]; then
|
||||
if [[ ${checkdepends} ]] && [[ $XBPS_CHECK_PKGS ]] && [ -z "$XBPS_CROSS_BUILD" ]; then
|
||||
templates=""
|
||||
# check validity
|
||||
for f in ${checkdepends}; do
|
||||
|
@ -421,12 +405,22 @@ install_pkg_deps() {
|
|||
done
|
||||
|
||||
if [[ ${host_binpkg_deps} ]]; then
|
||||
msg_normal "$pkgver: installing host dependencies: ${host_binpkg_deps[*]} ...\n"
|
||||
if [ -z "$XBPS_QUIET" ]; then
|
||||
# normal messages in bold
|
||||
[[ $NOCOLORS ]] || printf "\033[1m"
|
||||
echo "=> $pkgver: installing host dependencies: ${host_binpkg_deps[@]} ..."
|
||||
[[ $NOCOLORS ]] || printf "\033[m"
|
||||
fi
|
||||
install_pkg_from_repos "" host "${host_binpkg_deps[@]}"
|
||||
fi
|
||||
|
||||
if [[ ${binpkg_deps} ]]; then
|
||||
msg_normal "$pkgver: installing target dependencies: ${binpkg_deps[*]} ...\n"
|
||||
if [ -z "$XBPS_QUIET" ]; then
|
||||
# normal messages in bold
|
||||
[[ $NOCOLORS ]] || printf "\033[1m"
|
||||
echo "=> $pkgver: installing target dependencies: ${binpkg_deps[@]} ..."
|
||||
[[ $NOCOLORS ]] || printf "\033[m"
|
||||
fi
|
||||
install_pkg_from_repos "$cross" target "${binpkg_deps[@]}"
|
||||
fi
|
||||
|
||||
|
|
|
@ -73,7 +73,7 @@ bulk_build() {
|
|||
return $?
|
||||
;;
|
||||
local)
|
||||
bulk_sortdeps $(xbps-checkvers -f '%n' -i -R "${XBPS_REPOSITORY}/bootstrap" -R "${XBPS_REPOSITORY}" -R "${XBPS_REPOSITORY}/nonfree" -D "$XBPS_DISTDIR")
|
||||
bulk_sortdeps $(xbps-checkvers -f '%n' -i -R "${XBPS_REPOSITORY}" -R "${XBPS_REPOSITORY}/nonfree" -D "$XBPS_DISTDIR")
|
||||
return $?
|
||||
;;
|
||||
esac
|
||||
|
@ -122,6 +122,6 @@ bulk_update() {
|
|||
if [ -n "$pkgs" -a "$bulk_update_cmd" == installed ]; then
|
||||
echo
|
||||
msg_normal "xbps-src: updating your system, confirm to proceed...\n"
|
||||
${XBPS_SUCMD} "xbps-install --repository=$XBPS_REPOSITORY/bootstrap --repository=$XBPS_REPOSITORY --repository=$XBPS_REPOSITORY/nonfree -u ${pkgs//[$'\n']/ }" || return 1
|
||||
${XBPS_SUCMD} "xbps-install --repository=$XBPS_REPOSITORY --repository=$XBPS_REPOSITORY/nonfree -u ${pkgs//[$'\n']/ }" || return 1
|
||||
fi
|
||||
}
|
||||
|
|
|
@ -8,22 +8,22 @@ install_base_chroot() {
|
|||
XBPS_TARGET_PKG="$1"
|
||||
fi
|
||||
# binary bootstrap
|
||||
msg_normal "xbps-src: installing base-chroot...\n"
|
||||
msg_normal "xbps-src: installing base-chroot-cereus...\n"
|
||||
# XBPS_TARGET_PKG == arch
|
||||
if [ "$XBPS_TARGET_PKG" ]; then
|
||||
_bootstrap_arch="env XBPS_TARGET_ARCH=$XBPS_TARGET_PKG"
|
||||
fi
|
||||
(export XBPS_MACHINE=$XBPS_TARGET_PKG XBPS_ARCH=$XBPS_TARGET_PKG; chroot_sync_repodata)
|
||||
${_bootstrap_arch} $XBPS_INSTALL_CMD ${XBPS_INSTALL_ARGS} -y base-chroot
|
||||
${_bootstrap_arch} $XBPS_INSTALL_CMD ${XBPS_INSTALL_ARGS} -y base-chroot-cereus
|
||||
if [ $? -ne 0 ]; then
|
||||
msg_error "xbps-src: failed to install base-chroot!\n"
|
||||
msg_error "xbps-src: failed to install base-chroot-cereus!\n"
|
||||
fi
|
||||
# Reconfigure base-files to create dirs/symlinks.
|
||||
if xbps-query -r $XBPS_MASTERDIR base-files &>/dev/null; then
|
||||
XBPS_ARCH=$XBPS_TARGET_PKG xbps-reconfigure -r $XBPS_MASTERDIR -f base-files &>/dev/null
|
||||
fi
|
||||
|
||||
msg_normal "xbps-src: installed base-chroot successfully!\n"
|
||||
msg_normal "xbps-src: installed base-chroot-cereus successfully!\n"
|
||||
chroot_prepare $XBPS_TARGET_PKG || msg_error "xbps-src: failed to initialize chroot!\n"
|
||||
chroot_check
|
||||
chroot_handler clean
|
||||
|
@ -34,7 +34,7 @@ reconfigure_base_chroot() {
|
|||
local pkgs="glibc-locales ca-certificates"
|
||||
[ -z "$IN_CHROOT" -o -e $statefile ] && return 0
|
||||
# Reconfigure ca-certificates.
|
||||
msg_normal "xbps-src: reconfiguring base-chroot...\n"
|
||||
msg_normal "xbps-src: reconfiguring base-chroot-cereus...\n"
|
||||
for f in ${pkgs}; do
|
||||
if xbps-query -r $XBPS_MASTERDIR $f &>/dev/null; then
|
||||
xbps-reconfigure -r $XBPS_MASTERDIR -f $f
|
||||
|
@ -51,7 +51,7 @@ update_base_chroot() {
|
|||
if $(${XBPS_INSTALL_CMD} ${XBPS_INSTALL_ARGS} -nu|grep -q xbps); then
|
||||
${XBPS_INSTALL_CMD} ${XBPS_INSTALL_ARGS} -yu xbps || msg_error "xbps-src: failed to update xbps!\n"
|
||||
fi
|
||||
${XBPS_INSTALL_CMD} ${XBPS_INSTALL_ARGS} -yu || msg_error "xbps-src: failed to update base-chroot!\n"
|
||||
${XBPS_INSTALL_CMD} ${XBPS_INSTALL_ARGS} -yu || msg_error "xbps-src: failed to update base-chroot-cereus!\n"
|
||||
msg_normal "xbps-src: cleaning up $XBPS_MASTERDIR masterdir...\n"
|
||||
[ -z "$XBPS_KEEP_ALL" -a -z "$XBPS_SKIP_DEPS" ] && remove_pkg_autodeps
|
||||
[ -z "$XBPS_KEEP_ALL" -a -z "$keep_all_force" ] && rm -rf $XBPS_MASTERDIR/builddir $XBPS_MASTERDIR/destdir
|
||||
|
@ -89,7 +89,7 @@ PATH=/void-packages:/usr/bin
|
|||
exec env -i -- SHELL=/bin/sh PATH="\$PATH" DISTCC_HOSTS="\$XBPS_DISTCC_HOSTS" DISTCC_DIR="/host/distcc" \
|
||||
${XBPS_ARCH+XBPS_ARCH=$XBPS_ARCH} ${XBPS_CHECK_PKGS+XBPS_CHECK_PKGS=$XBPS_CHECK_PKGS} \
|
||||
CCACHE_DIR="/host/ccache" IN_CHROOT=1 LC_COLLATE=C LANG=en_US.UTF-8 TERM=linux HOME="/tmp" \
|
||||
PS1="[\u@$XBPS_MASTERDIR \W]$ " /bin/bash +h "\$@"
|
||||
PS1="[\u@$XBPS_MASTERDIR \W]$ " /bin/bash +h
|
||||
_EOF
|
||||
|
||||
chmod 755 $XBPS_MASTERDIR/bin/xbps-shell
|
||||
|
@ -165,11 +165,6 @@ chroot_handler() {
|
|||
else
|
||||
env -i -- PATH="/usr/bin:$PATH" SHELL=/bin/sh \
|
||||
HOME=/tmp IN_CHROOT=1 LC_COLLATE=C LANG=en_US.UTF-8 \
|
||||
${http_proxy:+http_proxy="${http_proxy}"} \
|
||||
${https_proxy:+https_proxy="${https_proxy}"} \
|
||||
${ftp_proxy:+ftp_proxy="${ftp_proxy}"} \
|
||||
${all_proxy:+all_proxy="${all_proxy}"} \
|
||||
${no_proxy:+no_proxy="${no_proxy}"} \
|
||||
${HTTP_PROXY:+HTTP_PROXY="${HTTP_PROXY}"} \
|
||||
${HTTPS_PROXY:+HTTPS_PROXY="${HTTPS_PROXY}"} \
|
||||
${FTP_PROXY:+FTP_PROXY="${FTP_PROXY}"} \
|
||||
|
@ -214,18 +209,16 @@ chroot_sync_repodata() {
|
|||
# Update xbps alternative repository if set.
|
||||
mkdir -p $confdir
|
||||
if [ -n "$XBPS_ALT_REPOSITORY" ]; then
|
||||
cat <<- ! > $confdir/00-repository-alt-local.conf
|
||||
repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}/bootstrap
|
||||
repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}
|
||||
repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}/nonfree
|
||||
repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}/debug
|
||||
!
|
||||
( \
|
||||
echo "repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}"; \
|
||||
echo "repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}/nonfree"; \
|
||||
echo "repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}/debug"; \
|
||||
) > $confdir/00-repository-alt-local.conf
|
||||
if [ "$XBPS_MACHINE" = "x86_64" ]; then
|
||||
cat <<- ! >> $confdir/00-repository-alt-local.conf
|
||||
repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}/multilib/bootstrap
|
||||
repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}/multilib
|
||||
repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}/multilib/nonfree
|
||||
!
|
||||
( \
|
||||
echo "repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}/multilib"; \
|
||||
echo "repository=$hostdir/binpkgs/${XBPS_ALT_REPOSITORY}/multilib/nonfree"; \
|
||||
) >> $confdir/00-repository-alt-local.conf
|
||||
fi
|
||||
else
|
||||
rm -f $confdir/00-repository-alt-local.conf
|
||||
|
@ -309,9 +302,6 @@ chroot_sync_repodata() {
|
|||
# Copy xbps repository keys to the masterdir.
|
||||
mkdir -p $XBPS_MASTERDIR/var/db/xbps/keys
|
||||
cp -f $XBPS_COMMONDIR/repo-keys/*.plist $XBPS_MASTERDIR/var/db/xbps/keys
|
||||
if [ -n "$(shopt -s nullglob; echo "$XBPS_DISTDIR"/etc/repo-keys/*.plist)" ]; then
|
||||
cp -f "$XBPS_DISTDIR"/etc/repo-keys/*.plist "$XBPS_MASTERDIR"/var/db/xbps/keys
|
||||
fi
|
||||
|
||||
# Make sure to sync index for remote repositories.
|
||||
if [ -z "$XBPS_SKIP_REMOTEREPOS" ]; then
|
||||
|
|
|
@ -1,41 +1,5 @@
|
|||
# vim: set ts=4 sw=4 et:
|
||||
|
||||
# A portable abstraction for stat(1)
|
||||
#
|
||||
# The stat(1) command has different syntaxes between GNU flavor
|
||||
# and BSD flavor; implementations generally follow one or the other
|
||||
#
|
||||
if ! stat -c "%s" / > /dev/null 2>&1; then
|
||||
# BSD stat
|
||||
|
||||
stat_size() {
|
||||
stat -f %z "$1"
|
||||
}
|
||||
|
||||
stat_inode() {
|
||||
stat -f %i "$1"
|
||||
}
|
||||
|
||||
stat_mtime() {
|
||||
stat -f %m "$1"
|
||||
}
|
||||
else
|
||||
# GNU stat
|
||||
|
||||
stat_size() {
|
||||
stat -c %s "$1"
|
||||
}
|
||||
|
||||
stat_inode() {
|
||||
stat -c %i "$1"
|
||||
}
|
||||
|
||||
stat_mtime() {
|
||||
stat -c %Y "$1"
|
||||
}
|
||||
fi
|
||||
|
||||
|
||||
run_func() {
|
||||
local func="$1" desc="$2" funcname="$3" restoretrap= logpipe= logfile= teepid=
|
||||
|
||||
|
@ -176,24 +140,13 @@ msg_warn_nochroot() {
|
|||
|
||||
msg_normal() {
|
||||
if [ -z "$XBPS_QUIET" ]; then
|
||||
# normal messages in bright bold white
|
||||
if [ "$XBPS_BUILD_ENVIRONMENT" = "void-packages-ci" ]; then
|
||||
# Github CI considers '1m' to be just a font bold
|
||||
[ -n "$NOCOLORS" ] || printf "\033[97m\033[1m"
|
||||
else
|
||||
[ -n "$NOCOLORS" ] || printf "\033[1m"
|
||||
fi
|
||||
# normal messages in bold
|
||||
[ -n "$NOCOLORS" ] || printf "\033[1m"
|
||||
printf "=> $@"
|
||||
[ -n "$NOCOLORS" ] || printf "\033[m"
|
||||
fi
|
||||
}
|
||||
|
||||
msg_verbose() {
|
||||
if [ -n "$XBPS_VERBOSE" ]; then
|
||||
printf >&2 "$@"
|
||||
fi
|
||||
}
|
||||
|
||||
report_broken() {
|
||||
if [ "$show_problems" = "ignore-problems" ]; then
|
||||
return
|
||||
|
@ -212,12 +165,7 @@ report_broken() {
|
|||
}
|
||||
|
||||
msg_normal_append() {
|
||||
if [ "$XBPS_BUILD_ENVIRONMENT" = "void-packages-ci" ]; then
|
||||
# Github CI considers '1m' to be just a font bold
|
||||
[ -n "$NOCOLORS" ] || printf "\033[97m\033[1m"
|
||||
else
|
||||
[ -n "$NOCOLORS" ] || printf "\033[1m"
|
||||
fi
|
||||
[ -n "$NOCOLORS" ] || printf "\033[1m"
|
||||
printf "$@"
|
||||
[ -n "$NOCOLORS" ] || printf "\033[m"
|
||||
}
|
||||
|
@ -341,7 +289,6 @@ get_endian() {
|
|||
ppc*le) echo "le";;
|
||||
ppc*) echo "be";;
|
||||
x86_64) echo "le";;
|
||||
riscv64) echo "le";;
|
||||
esac
|
||||
}
|
||||
|
||||
|
@ -369,7 +316,6 @@ get_wordsize() {
|
|||
ppc64*) echo "64";;
|
||||
ppc*) echo "32";;
|
||||
x86_64) echo "64";;
|
||||
riscv64) echo "64";;
|
||||
esac
|
||||
}
|
||||
|
||||
|
@ -469,7 +415,7 @@ setup_pkg() {
|
|||
done
|
||||
|
||||
if [ ! -f ${XBPS_SRCPKGDIR}/${basepkg}/template ]; then
|
||||
msg_error "xbps-src: nonexistent file: ${XBPS_SRCPKGDIR}/${basepkg}/template\n"
|
||||
msg_error "xbps-src: unexistent file: ${XBPS_SRCPKGDIR}/${basepkg}/template\n"
|
||||
fi
|
||||
if [ -n "$cross" ]; then
|
||||
export CROSS_BUILD="$cross"
|
||||
|
@ -531,17 +477,12 @@ setup_pkg() {
|
|||
fi
|
||||
fi
|
||||
|
||||
for x in ${hostmakedepends} ${makedepends} ${checkdepends}; do
|
||||
if [[ $x = *[\<\>]* || $x =~ -[^-_]*[0-9][^-_]*_[0-9_]+$ ]]; then
|
||||
msg_error "$pkgver: specifying version in build dependency '$x' is invalid, template version is used always\n"
|
||||
fi
|
||||
done
|
||||
|
||||
FILESDIR=$XBPS_SRCPKGDIR/$sourcepkg/files
|
||||
PATCHESDIR=$XBPS_SRCPKGDIR/$sourcepkg/patches
|
||||
DESTDIR=$XBPS_DESTDIR/$XBPS_CROSS_TRIPLET/${sourcepkg}-${version}
|
||||
PKGDESTDIR=$XBPS_DESTDIR/$XBPS_CROSS_TRIPLET/${pkg}-${version}
|
||||
|
||||
: ${XBPS_MAKEJOBS:=1}
|
||||
export XBPS_ORIG_MAKEJOBS=${XBPS_ORIG_MAKEJOBS:=$XBPS_MAKEJOBS}
|
||||
if [ -n "$disable_parallel_build" ]; then
|
||||
XBPS_MAKEJOBS=1
|
||||
|
|
|
@ -16,7 +16,7 @@ remove_pkg_cross_deps() {
|
|||
$XBPS_REMOVE_XCMD -Ryo > $tmplogf 2>&1
|
||||
rval=$?
|
||||
while [ $rval -eq 0 ]; do
|
||||
local curs=$(stat_size $tmplogf)
|
||||
local curs=$(stat -c %s $tmplogf)
|
||||
if [ $curs -eq $prevs ]; then
|
||||
break
|
||||
fi
|
||||
|
|
|
@ -65,11 +65,11 @@ remove_pkg_autodeps() {
|
|||
|
||||
remove_pkg_cross_deps
|
||||
$XBPS_RECONFIGURE_CMD -a >> $tmplogf 2>&1
|
||||
prevs=$(stat_size $tmplogf)
|
||||
prevs=$(stat -c %s $tmplogf)
|
||||
echo yes | $XBPS_REMOVE_CMD -Ryod 2>> $errlogf 1>> $tmplogf
|
||||
rval=$?
|
||||
while [ $rval -eq 0 ]; do
|
||||
local curs=$(stat_size $tmplogf)
|
||||
local curs=$(stat -c %s $tmplogf)
|
||||
if [ $curs -eq $prevs ]; then
|
||||
break
|
||||
fi
|
||||
|
@ -105,7 +105,7 @@ remove_pkg_statedir() {
|
|||
remove_pkg() {
|
||||
local cross="$1" _destdir f
|
||||
|
||||
[ -z $pkgname ] && msg_error "nonexistent package, aborting.\n"
|
||||
[ -z $pkgname ] && msg_error "unexistent package, aborting.\n"
|
||||
|
||||
if [ -n "$cross" ]; then
|
||||
_destdir="$XBPS_DESTDIR/$XBPS_CROSS_TRIPLET"
|
||||
|
|
|
@ -57,7 +57,7 @@ purge_distfiles() {
|
|||
cur=0
|
||||
percent=-1
|
||||
for distfile in ${distfiles[@]}; do
|
||||
inode=$(stat_inode "$distfile")
|
||||
inode=$(stat "$distfile" --printf "%i")
|
||||
if [ -z "${inodes[$inode]}" ]; then
|
||||
inodes[$inode]="$distfile"
|
||||
else
|
||||
|
@ -77,7 +77,7 @@ purge_distfiles() {
|
|||
hash_distfile=${file##*/}
|
||||
hash=${hash_distfile:0:$HASHLEN}
|
||||
[ -n "${my_hashes[$hash]}" ] && continue
|
||||
inode=$(stat_inode "$file")
|
||||
inode=$(stat "$file" --printf "%i")
|
||||
echo "Obsolete $hash (inode: $inode)"
|
||||
( IFS="|"; for f in ${inodes[$inode]}; do rm -vf "$f"; rmdir "${f%/*}" 2>/dev/null; done )
|
||||
done
|
||||
|
|
|
@ -1,27 +1,49 @@
|
|||
# vim: set ts=4 sw=4 et:
|
||||
|
||||
show_pkg() {
|
||||
show_pkg_var "pkgname" "$pkgname"
|
||||
show_pkg_var "version" "$version"
|
||||
show_pkg_var "revision" "$revision"
|
||||
show_pkg_var "distfiles" "$distfiles" 1
|
||||
show_pkg_var "checksum" "$checksum" 1
|
||||
show_pkg_var "archs" "$archs" 1
|
||||
show_pkg_var "maintainer" "${maintainer}"
|
||||
show_pkg_var "Upstream URL" "$homepage"
|
||||
show_pkg_var "License(s)" "${license//,/ }" 1
|
||||
show_pkg_var "Changelog" "$changelog"
|
||||
show_pkg_var "build_style" "$build_style"
|
||||
show_pkg_var "build_helper" "$build_helper" 1
|
||||
show_pkg_var "configure_args" "$configure_args" 1
|
||||
show_pkg_var "short_desc" "$short_desc"
|
||||
show_pkg_var "subpackages" "$subpackages" 1
|
||||
local i=
|
||||
|
||||
echo "pkgname: $pkgname"
|
||||
echo "version: $version"
|
||||
echo "revision: $revision"
|
||||
for i in ${distfiles}; do
|
||||
[ -n "$i" ] && echo "distfiles: $i"
|
||||
done
|
||||
for i in ${checksum}; do
|
||||
[ -n "$i" ] && echo "checksum: $i"
|
||||
done
|
||||
for i in ${archs}; do
|
||||
[ -n "$i" ] && echo "archs: $i"
|
||||
done
|
||||
echo "maintainer: $maintainer"
|
||||
[ -n "$homepage" ] && echo "Upstream URL: $homepage"
|
||||
[ -n "$license" ] && echo "License(s): $license"
|
||||
[ -n "$changelog" ] && echo "Changelog: $changelog"
|
||||
[ -n "$build_style" ] && echo "build_style: $build_style"
|
||||
for i in $build_helper; do
|
||||
[ -n "$i" ] && echo "build_helper: $i"
|
||||
done
|
||||
for i in ${configure_args}; do
|
||||
[ -n "$i" ] && echo "configure_args: $i"
|
||||
done
|
||||
echo "short_desc: $short_desc"
|
||||
for i in ${subpackages}; do
|
||||
[ -n "$i" ] && echo "subpackages: $i"
|
||||
done
|
||||
set -f
|
||||
show_pkg_var "conf_files" "$conf_files" 1
|
||||
for i in ${conf_files}; do
|
||||
[ -n "$i" ] && echo "conf_files: $i"
|
||||
done
|
||||
set +f
|
||||
show_pkg_var "replaces" "$replaces" 1
|
||||
show_pkg_var "provides" "$provides" 1
|
||||
show_pkg_var "conflicts" "$conflicts" 1
|
||||
for i in ${replaces}; do
|
||||
[ -n "$i" ] && echo "replaces: $i"
|
||||
done
|
||||
for i in ${provides}; do
|
||||
[ -n "$i" ] && echo "provides: $i"
|
||||
done
|
||||
for i in ${conflicts}; do
|
||||
[ -n "$i" ] && echo "conflicts: $i"
|
||||
done
|
||||
local OIFS="$IFS"
|
||||
IFS=','
|
||||
for var in $1; do
|
||||
|
@ -29,9 +51,11 @@ show_pkg() {
|
|||
if [ ${var} != ${var/'*'} ]
|
||||
then
|
||||
var="${var/'*'}"
|
||||
show_pkg_var "$var" "${!var//$'\n'/' '}"
|
||||
[ -n "${!var}" ] && echo "$var: ${!var//$'\n'/' '}"
|
||||
else
|
||||
show_pkg_var "$var" "${!var}" 1
|
||||
for val in ${!var}; do
|
||||
[ -n "$val" ] && echo "$var: $val"
|
||||
done
|
||||
fi
|
||||
done
|
||||
IFS="$OIFS"
|
||||
|
@ -39,28 +63,6 @@ show_pkg() {
|
|||
return 0
|
||||
}
|
||||
|
||||
show_pkg_var() {
|
||||
local _sep i=
|
||||
local _label="$1"
|
||||
local _value="$2"
|
||||
local _always_split="$3"
|
||||
if [ -n "$_value" ] && [ -n "$_label" ]; then
|
||||
# on short labels, use more padding so everything lines up
|
||||
if [ "${#_label}" -lt 7 ]; then
|
||||
_sep=" "
|
||||
else
|
||||
_sep=" "
|
||||
fi
|
||||
if [ -n "$_always_split" ] || [[ "$_value" =~ $'\n' ]]; then
|
||||
for i in ${_value}; do
|
||||
[ -n "$i" ] && echo "${_label}:${_sep}${i}"
|
||||
done
|
||||
else
|
||||
echo "${_label}:${_sep}${_value}"
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
show_pkg_deps() {
|
||||
[ -f "${PKGDESTDIR}/rdeps" ] && cat ${PKGDESTDIR}/rdeps
|
||||
}
|
||||
|
@ -75,7 +77,7 @@ show_avail() {
|
|||
|
||||
show_eval_dep() {
|
||||
local f x _pkgname _srcpkg found
|
||||
local _dep="${1%-32bit}"
|
||||
local _dep="$1"
|
||||
local _host="$2"
|
||||
if [ -z "$CROSS_BUILD" ] || [ -z "$_host" ]; then
|
||||
# ignore dependency on itself
|
||||
|
@ -92,7 +94,8 @@ show_eval_dep() {
|
|||
[[ $_dep == $x ]] && found=1 && break
|
||||
done
|
||||
[[ $found ]] && return
|
||||
_srcpkg=$(readlink -f ${XBPS_SRCPKGDIR}/${_dep})
|
||||
_pkgname=${_dep/-32bit}
|
||||
_srcpkg=$(readlink -f ${XBPS_SRCPKGDIR}/${_pkgname})
|
||||
_srcpkg=${_srcpkg##*/}
|
||||
echo $_srcpkg
|
||||
}
|
||||
|
@ -116,9 +119,7 @@ show_pkg_build_depends() {
|
|||
}
|
||||
|
||||
show_pkg_build_deps() {
|
||||
local build_depends="${makedepends} $(setup_pkg_depends '' 1 1)"
|
||||
skip_check_step || build_depends+=" ${checkdepends}"
|
||||
show_pkg_build_depends "${build_depends}" "${hostmakedepends}"
|
||||
show_pkg_build_depends "${makedepends} $(setup_pkg_depends '' 1 1)" "${hostmakedepends}"
|
||||
}
|
||||
|
||||
show_pkg_hostmakedepends() {
|
||||
|
@ -129,21 +130,16 @@ show_pkg_makedepends() {
|
|||
show_pkg_build_depends "${makedepends}" ""
|
||||
}
|
||||
|
||||
show_pkg_checkdepends() {
|
||||
show_pkg_build_depends "${checkdepends}" ""
|
||||
}
|
||||
|
||||
show_pkg_build_options() {
|
||||
local f
|
||||
local f opt desc
|
||||
|
||||
[ -z "$PKG_BUILD_OPTIONS" ] && return 0
|
||||
|
||||
source $XBPS_COMMONDIR/options.description
|
||||
msg_normal "$pkgver: the following build options are set:\n"
|
||||
for f in ${PKG_BUILD_OPTIONS}; do
|
||||
local opt="${f#\~}"
|
||||
local descref="desc_option_${opt}"
|
||||
local desc="${!descref-Enable support for $opt}"
|
||||
opt="${f#\~}"
|
||||
eval desc="\${desc_option_${opt}}"
|
||||
if [[ ${f:0:1} == '~' ]]; then
|
||||
echo " $opt: $desc (OFF)"
|
||||
else
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
# vim: set ts=4 sw=4 et ft=bash :
|
||||
# vim: set ts=4 sw=4 et:
|
||||
|
||||
update_check() {
|
||||
local i p url pkgurlname rx found_version consider
|
||||
|
@ -8,26 +8,11 @@ update_check() {
|
|||
local urlpfx urlsfx
|
||||
local -A fetchedurls
|
||||
|
||||
local curlargs=(
|
||||
-A "xbps-src-update-check/$XBPS_SRC_VERSION"
|
||||
--max-time 10 --compressed -Lsk
|
||||
)
|
||||
|
||||
pkgname=${pkgname#kf6-}
|
||||
|
||||
# XBPS_UPDATE_CHECK_VERBOSE is the old way to show verbose messages
|
||||
[ "$XBPS_UPDATE_CHECK_VERBOSE" ] && XBPS_VERBOSE="$XBPS_UPDATE_CHECK_VERBOSE"
|
||||
|
||||
if [ -r $update_override ]; then
|
||||
. $update_override
|
||||
msg_verbose "using $XBPS_TARGET_PKG/update overrides\n"
|
||||
if [ -n "$disabled" ]; then
|
||||
msg_verbose "update-check DISABLED for $original_pkgname: $disabled\n"
|
||||
return 0
|
||||
if [ "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
|
||||
echo "using $XBPS_TARGET_PKG/update overrides" 1>&2
|
||||
fi
|
||||
elif [ -z "$distfiles" ]; then
|
||||
msg_verbose "NO DISTFILES found for $original_pkgname\n"
|
||||
return 0
|
||||
fi
|
||||
|
||||
if ! type curl >/dev/null 2>&1; then
|
||||
|
@ -69,7 +54,7 @@ update_check() {
|
|||
*code.google.com*|*googlecode*|\
|
||||
*launchpad.net*|\
|
||||
*cpan.*|\
|
||||
*pythonhosted.org*|*pypi.org/project/*|\
|
||||
*pythonhosted.org*|\
|
||||
*github.com*|\
|
||||
*//gitlab.*|\
|
||||
*bitbucket.org*|\
|
||||
|
@ -81,7 +66,6 @@ update_check() {
|
|||
*crates.io*|\
|
||||
*codeberg.org*|\
|
||||
*hg.sr.ht*|\
|
||||
*software.sil.org*|\
|
||||
*git.sr.ht*)
|
||||
continue
|
||||
;;
|
||||
|
@ -100,9 +84,11 @@ update_check() {
|
|||
esac
|
||||
if [ "$rx" ]; then
|
||||
# substitute url if needed
|
||||
msg_verbose "(folder) fetching $urlpfx and scanning with $rx\n"
|
||||
if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
|
||||
echo "(folder) fetching $urlpfx and scanning with $rx" 1>&2
|
||||
fi
|
||||
skipdirs=
|
||||
curl "${curlargs[@]}" "$urlpfx" |
|
||||
curl -A "xbps-src-update-check/$XBPS_SRC_VERSION" --max-time 10 -Lsk "$urlpfx" |
|
||||
grep -Po -i "$rx" |
|
||||
# sort -V places 1.1/ before 1/, but 1A/ before 1.1A/
|
||||
sed -e 's:$:A:' -e 's:/A$:A/:' | sort -Vru | sed -e 's:A/$:/A:' -e 's:A$::' |
|
||||
|
@ -125,37 +111,36 @@ update_check() {
|
|||
pkgurlname="$(printf %s "$url" | cut -d/ -f5)"
|
||||
url="https://sourceforge.net/projects/$pkgurlname/rss?limit=200";;
|
||||
*code.google.com*|*googlecode*)
|
||||
url="https://code.google.com/p/$pkgname/downloads/list";;
|
||||
url="http://code.google.com/p/$pkgname/downloads/list";;
|
||||
*launchpad.net*)
|
||||
pkgurlname="$(printf %s "$url" | cut -d/ -f4)"
|
||||
url="https://launchpad.net/$pkgurlname/+download";;
|
||||
*cpan.*)
|
||||
pkgname=${pkgname#perl-};;
|
||||
*pythonhosted.org*|*pypi.org/project/*)
|
||||
*pythonhosted.org*)
|
||||
pkgname=${pkgname#python-}
|
||||
pkgname=${pkgname#python3-}
|
||||
rx="(?<=${pkgname//-/[-_]}-)[0-9.]+(post[0-9]*)?(?=(([.]tar|-cp|-py)))"
|
||||
url="https://pypi.org/simple/$pkgname";;
|
||||
*github.com*)
|
||||
pkgurlname="$(printf %s "$url" | cut -d/ -f4,5)"
|
||||
url="https://github.com/$pkgurlname/tags"
|
||||
rx='/archive/refs/tags/(v?|\Q'"$pkgname"'\E[-_])?\K[\d.]+(?=\.tar\.gz")';;
|
||||
rx='/archive/refs/tags/(v?|\Q'"$pkgname"'\E-)?\K[\d.]+(?=\.tar\.gz")';;
|
||||
*//gitlab.*|*code.videolan.org*)
|
||||
case "$url" in
|
||||
*/-/*) pkgurlname="$(printf %s "$url" | sed -e 's%/-/.*%%g; s%/$%%')";;
|
||||
*) pkgurlname="$(printf %s "$url" | cut -d / -f 1-5)";;
|
||||
esac
|
||||
url="$pkgurlname/-/tags"
|
||||
rx='/archive/[^/]+/\Q'"$pkgname"'\E-v?\K[\d.]+(?=\.tar\.gz)';;
|
||||
url="$pkgurlname/tags"
|
||||
rx='/archive/[^/]+/\Q'"$pkgname"'\E-v?\K[\d.]+(?=\.tar\.gz")';;
|
||||
*bitbucket.org*)
|
||||
pkgurlname="$(printf %s "$url" | cut -d/ -f4,5)"
|
||||
url="https://bitbucket.org/$pkgurlname/downloads"
|
||||
rx='/(get|downloads)/(v?|\Q'"$pkgname"'\E-)?\K[\d.]+(?=\.tar)';;
|
||||
*ftp.gnome.org*|*download.gnome.org*)
|
||||
rx='(?<=LATEST-IS-)([0-24-9]|3\.[0-9]*[02468]|[4-9][0-9]+)\.[0-9.]*[0-9](?=\")'
|
||||
: ${pattern="\Q$pkgname\E-\K(0|[13]\.[0-9]*[02468]|[4-9][0-9]+)\.[0-9.]*[0-9](?=.tar)"}
|
||||
url="https://download.gnome.org/sources/$pkgname/cache.json";;
|
||||
*archive.xfce.org*)
|
||||
rx='\Q'"$pkgname"'\E-\K((([4-9]|([1-9][0-9]+))\.[0-9]*[02468]\.[0-9.]*[0-9])|([0-3]\.[0-9.]*))(?=.tar)'
|
||||
: ${pattern="\Q$pkgname\E-\K((([4-9]|([1-9][0-9]+))\.[0-9]*[02468]\.[0-9.]*[0-9])|([0-3]\.[0-9.]*))(?=.tar)"}
|
||||
url="https://archive.xfce.org/feeds/project/$pkgname" ;;
|
||||
*kernel.org/pub/linux/kernel/*)
|
||||
rx=linux-'\K'${version%.*}'[\d.]+(?=\.tar\.xz)';;
|
||||
|
@ -177,22 +162,10 @@ update_check() {
|
|||
rx='/archive/(v?|\Q'"$pkgname"'\E-)?\K[\d.]+(?=\.tar\.gz")';;
|
||||
*git.sr.ht*)
|
||||
pkgurlname="$(printf %s "$url" | cut -d/ -f4,5)"
|
||||
url="https://git.sr.ht/$pkgurlname/refs/rss.xml"
|
||||
rx='<guid>\Q'"${url%/*}"'\E/(v-?|\Q'"$pkgname"'\E-)?\K[\d.]+(?=</guid>)' ;;
|
||||
url="https://git.sr.ht/$pkgurlname/refs"
|
||||
rx='/archive/(v?|\Q'"$pkgname"'\E-)?\K[\d.]+(?=\.tar\.gz")';;
|
||||
*pkgs.fedoraproject.org*)
|
||||
url="https://pkgs.fedoraproject.org/repo/pkgs/$pkgname" ;;
|
||||
*software.sil.org/downloads/*)
|
||||
pkgurlname=$(printf '%s\n' "$url" | cut -d/ -f6)
|
||||
url="https://software.sil.org/$pkgurlname/download/"
|
||||
pkgname="${pkgname#font-}"
|
||||
pkgname="${pkgname#sil-}"
|
||||
_pkgname="${pkgname//-/}"
|
||||
rx="($_pkgname|${_pkgname}SIL)[_-]\K[0-9.]+(?=\.tar|\.zip)" ;;
|
||||
*software.sil.org/*)
|
||||
pkgname="${pkgname#font-}"
|
||||
pkgname="${pkgname#sil-}"
|
||||
_pkgname="${pkgname//-/}"
|
||||
rx="($_pkgname|${_pkgname}SIL)[_-]\K[0-9.]+(?=\.tar|\.zip)" ;;
|
||||
esac
|
||||
fi
|
||||
|
||||
|
@ -200,12 +173,16 @@ update_check() {
|
|||
rx=${rx:-'(?<!-)\b\Q'"$pkgname"'\E[-_]?((src|source)[-_])?v?\K([^-/_\s]*?\d[^-/_\s]*?)(?=(?:[-_.](?:src|source|orig))?\.(?:[jt]ar|shar|t[bglx]z|tbz2|zip))\b'}
|
||||
|
||||
if [ "${fetchedurls[$url]}" ]; then
|
||||
msg_verbose "already fetched $url\n"
|
||||
if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
|
||||
echo "already fetched $url" 1>&2
|
||||
fi
|
||||
continue
|
||||
fi
|
||||
|
||||
msg_verbose "fetching $url and scanning with $rx\n"
|
||||
curl "${curlargs[@]}" -H 'Accept: text/html,application/xhtml+xml,application/xml,text/plain,application/rss+xml' "$url" |
|
||||
if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
|
||||
echo "fetching $url and scanning with $rx" 1>&2
|
||||
fi
|
||||
curl -H 'Accept: text/html,application/xhtml+xml,application/xml,text/plain,application/rss+xml' -A "xbps-src-update-check/$XBPS_SRC_VERSION" --max-time 10 -Lsk "$url" |
|
||||
grep -Po -i "$rx"
|
||||
fetchedurls[$url]=yes
|
||||
done |
|
||||
|
@ -215,7 +192,9 @@ update_check() {
|
|||
grep . || echo "NO VERSION found for $original_pkgname" 1>&2
|
||||
} |
|
||||
while IFS= read -r found_version; do
|
||||
msg_verbose "found version $found_version\n"
|
||||
if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
|
||||
echo "found version $found_version"
|
||||
fi
|
||||
consider=true
|
||||
p="$ignore "
|
||||
while [ -n "$p" ]; do
|
||||
|
@ -224,7 +203,9 @@ update_check() {
|
|||
case "$found_version" in
|
||||
$i)
|
||||
consider=false
|
||||
msg_verbose "ignored $found_version due to $i\n"
|
||||
if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
|
||||
echo "ignored $found_version due to $i"
|
||||
fi
|
||||
esac
|
||||
done
|
||||
if $consider; then
|
||||
|
|
|
@ -64,8 +64,7 @@ XBPS_SUCMD="sudo /bin/sh -c"
|
|||
|
||||
# [OPTIONAL]
|
||||
# Number of parallel jobs to execute when building packages that
|
||||
# use make(1) or alike commands. Defaults to the result of nproc(1).
|
||||
# If nproc(1) is not available, defaults to 1.
|
||||
# use make(1) or alike commands.
|
||||
#
|
||||
#XBPS_MAKEJOBS=4
|
||||
|
||||
|
@ -159,9 +158,3 @@ XBPS_SUCMD="sudo /bin/sh -c"
|
|||
# When unset, newly build package overwrites the older one.
|
||||
#
|
||||
#XBPS_PRESERVE_PKGS=yes
|
||||
|
||||
# [OPTIONAL]
|
||||
# Show more detailed output in ./xbps-src update-check. Useful for debugging.
|
||||
# This can also be set or exported as a regular environment variable.
|
||||
#
|
||||
#XBPS_UPDATE_CHECK_VERBOSE=yes
|
||||
|
|
|
@ -24,13 +24,10 @@ emacs emacs
|
|||
java-environment openjdk8
|
||||
java-runtime openjdk8-jre
|
||||
libudev eudev-libudev
|
||||
lightdm-greeter base-chroot-cyclic-solver
|
||||
nodejs-runtime nodejs
|
||||
ntp-daemon chrony
|
||||
phonon-qt6-backend phonon-backend-vlc
|
||||
phonon-backend phonon-backend-gstreamer
|
||||
phonon-qt5-backend phonon-qt5-backend-gstreamer
|
||||
php-runtime php8.3
|
||||
pipewire-session-manager base-chroot-cyclic-solver
|
||||
rkt-stage1 rkt-stage1-coreos
|
||||
smtp-server opensmtpd
|
||||
tex texlive
|
||||
|
@ -39,5 +36,3 @@ xserver-abi-video xorg-server
|
|||
libGL libglvnd
|
||||
libEGL libglvnd
|
||||
libGLES libglvnd
|
||||
hunspell-en_GB hunspell-en_GB-all
|
||||
libadwaita libadwaita-without-adwaita
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
# DON'T EDIT THIS FILE
|
||||
# x86_64/glibc local repositories
|
||||
repository=/host/binpkgs/multilib/bootstrap
|
||||
repository=/host/binpkgs/multilib
|
||||
repository=/host/binpkgs/multilib/nonfree
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
# DON'T EDIT THIS FILE
|
||||
# Local repositories
|
||||
repository=/host/binpkgs/bootstrap
|
||||
repository=/host/binpkgs
|
||||
repository=/host/binpkgs/nonfree
|
||||
repository=/host/binpkgs/debug
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
# aarch64 voidlinux remote repositories
|
||||
repository=https://repo-default.voidlinux.org/current/aarch64/bootstrap
|
||||
repository=https://repo-default.voidlinux.org/current/aarch64
|
||||
repository=https://repo-default.voidlinux.org/current/aarch64/nonfree
|
||||
repository=https://repo-default.voidlinux.org/current/aarch64/debug
|
||||
repository=https://mirrors.servercentral.com/voidlinux/current/aarch64
|
||||
repository=https://mirrors.servercentral.com/voidlinux/current/aarch64/nonfree
|
||||
repository=https://mirrors.servercentral.com/voidlinux/current/aarch64/debug
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
# aarch64 voidlinux remote repositories
|
||||
repository=https://repo-default.voidlinux.org/current/aarch64/bootstrap
|
||||
repository=https://repo-default.voidlinux.org/current/aarch64
|
||||
repository=https://repo-default.voidlinux.org/current/aarch64/nonfree
|
||||
repository=https://repo-default.voidlinux.org/current/aarch64/debug
|
||||
repository=https://mirrors.servercentral.com/voidlinux/current/aarch64
|
||||
repository=https://mirrors.servercentral.com/voidlinux/current/aarch64/nonfree
|
||||
repository=https://mirrors.servercentral.com/voidlinux/current/aarch64/debug
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# voidlinux remote repositories (musl)
|
||||
repository=https://repo-default.voidlinux.org/current/musl/bootstrap
|
||||
repository=https://repo-default.voidlinux.org/current/musl
|
||||
repository=https://repo-default.voidlinux.org/current/musl/bootstrap
|
||||
repository=https://repo-default.voidlinux.org/current/musl/nonfree
|
||||
repository=https://repo-default.voidlinux.org/current/musl/debug
|
||||
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
# voidlinux remote repositories (x86_64/glibc)
|
||||
repository=https://repo-default.voidlinux.org/current/multilib/bootstrap
|
||||
repository=https://repo-default.voidlinux.org/current/multilib
|
||||
repository=https://repo-default.voidlinux.org/current/multilib/nonfree
|
||||
repository=https://mirrors.servercentral.com/voidlinux/current/multilib
|
||||
repository=https://mirrors.servercentral.com/voidlinux/current/multilib/nonfree
|
||||
|
|
|
@ -1,8 +1,8 @@
|
|||
# voidlinux remote repositories (glibc)
|
||||
repository=https://repo-default.voidlinux.org/current/bootstrap
|
||||
repository=https://repo-default.voidlinux.org/current
|
||||
repository=https://repo-default.voidlinux.org/current/nonfree
|
||||
repository=https://repo-default.voidlinux.org/current/debug
|
||||
repository=https://repo-default.voidlinux.org/current/bootstrap
|
||||
|
||||
# Cereus Linux remote repositories (glibc)
|
||||
repository=https://sourceforge.net/projects/cereus-linux/files/repos/cereus-core/x86_64
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Reference in a new issue