build 923 B

123456789101112131415161718192021222324252627
  1. #!/bin/bash
  2. [% c("var/set_default_env") -%]
  3. distdir=/var/tmp/dist/[% project %]
  4. mkdir -p /var/tmp/dist
  5. tar -C /var/tmp/dist -xf [% c('input_files_by_name/cmake') %]
  6. tar -C /var/tmp/dist -xf [% c('input_files_by_name/ninja') %]
  7. [% IF c("container/global_disable") -%]
  8. tar -C /var/tmp/dist -xf [% c('input_files_by_name/openssl-1.0.2') %]
  9. [% END -%]
  10. export PATH="/var/tmp/dist/ninja:/var/tmp/dist/cmake/bin:$PATH"
  11. mkdir /var/tmp/build
  12. tar -C /var/tmp/build -xf [% project %]-[% c('version') %].tar.gz
  13. cd /var/tmp/build/[% project %]-[% c('version') %]
  14. patch -p1 < "$rootdir/libdmg.patch"
  15. cmake . -GNinja -DCMAKE_BUILD_TYPE=Release [% c("var/cmake_opts") %]
  16. ninja -j[% c("num_procs") %] -v
  17. mkdir $distdir
  18. # We take only dmg and hfsplus like Mozilla does
  19. cp dmg/dmg hfs/hfsplus $distdir/
  20. cd /var/tmp/dist
  21. [% c('tar', {
  22. tar_src => [ project ],
  23. tar_args => '-czf ' _ dest_dir _ '/' _ c('filename'),
  24. }) %]