mirror of
https://github.com/darlinghq/darling.git
synced 2024-11-30 07:40:41 +00:00
f1153d9b1a
First of all, the RPM packaging code hadn't been updated in quite a while (it was still using the LKM), so this updates it to build with darlingserver instead of the LKM. Second, this update also adds a dependency generator that is used at build time to automatically pick up the ELF dependencies in installed Mach-Os. I prefer Debian's approach to this (simply having the option to dynamically generate the requirements into a file at build time). This seems like a convoluted approach (having to install a `fileattribute` globally on the build machine), but at least it works. Finally, this update also splits the package into multiple component packages like the Debian packages. Note that `darling-cli-devenv` needs to install files with the same names as those installed by `darling-gui`, so it has to be built as a completely separate package. To avoid having to rebuild a large portion of the project (about 8000 files), we simply generate a binary "source" tarball when building the main Darling packages and then use this as the source for `darling-cli-devenv`.
14 lines
568 B
Bash
Executable File
14 lines
568 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
set -euxv
|
|
|
|
CWD="$(cd "$(dirname "${BASH_SOURCE[0]}")"; pwd)"
|
|
if [ -e "${CWD}/SOURCES/darling.tar.gz" ]; then
|
|
rm "${CWD}/SOURCES/darling.tar.gz"
|
|
fi
|
|
if [ -e "${CWD}/SOURCES/darling-macho-deps.tar.gz" ]; then
|
|
rm "${CWD}/SOURCES/darling-macho-deps.tar.gz"
|
|
fi
|
|
tar --transform "s|^\./|darling/|" -cf "${CWD}/SOURCES/darling.tar.gz" -C "${CWD}/.." --exclude=.git --exclude SOURCES --exclude SRPMS --exclude RPMS --exclude BUILD .
|
|
tar --transform "s|^\./|darling-macho-deps/|" -cf "${CWD}/SOURCES/darling-macho-deps.tar.gz" -C "${CWD}/../tools/rpm" .
|