forked from M-Labs/artiq-extrapkg
Compare commits
3 Commits
a73be047fe
...
f61fb65c84
Author | SHA1 | Date |
---|---|---|
Egor Savkin | f61fb65c84 | |
Egor Savkin | 88bcb7874a | |
Egor Savkin | eac0d077de |
10
flake.nix
10
flake.nix
|
@ -518,9 +518,11 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
src = ./.;
|
src = ./.;
|
||||||
buildInputs = [ pkgs.gnutar pkgs.zstd pkgs.pacman pkgs.fakeroot ];
|
buildInputs = [ pkgs.gnutar pkgs.zstd pkgs.pacman pkgs.fakeroot pkgs.p11-kit pkgs.cacert pkgs.openssl ];
|
||||||
phases = [ "installPhase" ];
|
phases = [ "installPhase" ];
|
||||||
|
|
||||||
|
cacerts = builtins.head (builtins.filter (entry: (builtins.match "^mingw-w64-clang-x86_64-ca-certificates$" entry.name) != null) artiq-deps-pkgs);
|
||||||
|
|
||||||
installPhase = ''
|
installPhase = ''
|
||||||
mkdir $out
|
mkdir $out
|
||||||
mkdir -p tmp/cache
|
mkdir -p tmp/cache
|
||||||
|
@ -532,6 +534,10 @@
|
||||||
fakeroot pacman -U --asdeps --noconfirm --cachedir tmp/cache --config tmp/pacman.conf --root $out ${pkgs.lib.concatStringsSep " " (map (p: "${p}") artiq-deps-pkgs)}
|
fakeroot pacman -U --asdeps --noconfirm --cachedir tmp/cache --config tmp/pacman.conf --root $out ${pkgs.lib.concatStringsSep " " (map (p: "${p}") artiq-deps-pkgs)}
|
||||||
fakeroot pacman -U --noconfirm --cachedir tmp/cache --config tmp/pacman.conf --root $out ${msys2-artiq}/*.pkg.tar.zst ${msys2-artiq-comtools}/*.pkg.tar.zst ${msys2-pythonparser}/*.pkg.tar.zst ${msys2-sipyco}/*.pkg.tar.zst
|
fakeroot pacman -U --noconfirm --cachedir tmp/cache --config tmp/pacman.conf --root $out ${msys2-artiq}/*.pkg.tar.zst ${msys2-artiq-comtools}/*.pkg.tar.zst ${msys2-pythonparser}/*.pkg.tar.zst ${msys2-sipyco}/*.pkg.tar.zst
|
||||||
cp ${zadig-binary} $out/zadig.exe
|
cp ${zadig-binary} $out/zadig.exe
|
||||||
|
mkdir -p $out/clang64/etc/ssl/certs
|
||||||
|
cp -f $out/usr/ssl/certs/ca-bundle.crt $out/clang64/etc/ssl/certs/ca-bundle.crt
|
||||||
|
cp -f $out/usr/ssl/cert.pem $out/clang64/etc/ssl/cert.pem
|
||||||
|
cp -f $out/usr/ssl/certs/ca-bundle.trust.crt $out/clang64/etc/ssl/certs/ca-bundle.trust.crt
|
||||||
rm -rf $out/mingw64* $out/clang32* $out/clangarm64* $out/mingw32* $out/ucrt64* \
|
rm -rf $out/mingw64* $out/clang32* $out/clangarm64* $out/mingw32* $out/ucrt64* \
|
||||||
$out/var/lib/pacman/sync/mingw64* $out/var/lib/pacman/sync/clang32* $out/var/lib/pacman/sync/clangarm64* \
|
$out/var/lib/pacman/sync/mingw64* $out/var/lib/pacman/sync/clang32* $out/var/lib/pacman/sync/clangarm64* \
|
||||||
$out/var/lib/pacman/sync/mingw32* $out/var/lib/pacman/sync/ucrt64* \
|
$out/var/lib/pacman/sync/mingw32* $out/var/lib/pacman/sync/ucrt64* \
|
||||||
|
@ -549,7 +555,7 @@
|
||||||
sed -i "s|@DATE@|$(date +'%Y-%m-%d')|g" qt-ifw/config/config.xml qt-ifw/packages/com.msys2.root/meta/package.xml ;
|
sed -i "s|@DATE@|$(date +'%Y-%m-%d')|g" qt-ifw/config/config.xml qt-ifw/packages/com.msys2.root/meta/package.xml ;
|
||||||
sed -i "s|@VERSION@|${artiqpkgs.packages.x86_64-linux.artiq.version}|g" qt-ifw/config/config.xml qt-ifw/packages/com.msys2.root/meta/package.xml ;
|
sed -i "s|@VERSION@|${artiqpkgs.packages.x86_64-linux.artiq.version}|g" qt-ifw/config/config.xml qt-ifw/packages/com.msys2.root/meta/package.xml ;
|
||||||
|
|
||||||
7z a -mx9 -md128m "qt-ifw/packages/com.msys2.root/data/msys64.7z" "$msys2_artiq_root/"*
|
7z a -mx3 -md16m "qt-ifw/packages/com.msys2.root/data/msys64.7z" "$msys2_artiq_root/"*
|
||||||
${pkgs.wineWowPackages.stable}/bin/wine64 $msys2_qt_ifw/clang64/bin/binarycreator.exe \
|
${pkgs.wineWowPackages.stable}/bin/wine64 $msys2_qt_ifw/clang64/bin/binarycreator.exe \
|
||||||
-t "$msys2_qt_ifw/clang64/bin/installerbase.exe" \
|
-t "$msys2_qt_ifw/clang64/bin/installerbase.exe" \
|
||||||
-p "qt-ifw/packages" \
|
-p "qt-ifw/packages" \
|
||||||
|
|
|
@ -15,7 +15,7 @@ build() {
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
cd source
|
cd source
|
||||||
wine-msys2-build python -m installer --destdir="${pkgdir}" dist/*.whl
|
wine-msys2-build python -m installer --destdir="${pkgdir}" --prefix="clang64/" dist/*.whl
|
||||||
# patch broken shebangs (Z:/nix/store/...)
|
# patch broken shebangs (Z:/nix/store/...)
|
||||||
for entrypoint in ${pkgdir}/bin/*-script.py; do
|
for entrypoint in ${pkgdir}/bin/*-script.py; do
|
||||||
[ -f "$entrypoint" ] || continue
|
[ -f "$entrypoint" ] || continue
|
||||||
|
|
Loading…
Reference in New Issue