build 693 B

12345678910111213141516171819
  1. #!/bin/bash
  2. [% c("var/set_default_env") -%]
  3. [% pc(c('var/compiler'), 'var/setup', { compiler_tarfile => c('input_files_by_name/' _ c('var/compiler')) }) %]
  4. distdir=/var/tmp/dist/[% project %]
  5. mkdir -p $distdir
  6. mkdir -p /var/tmp/build
  7. tar -C /var/tmp/build -xf [% project %]-[% c('version') %].tar.gz
  8. cd /var/tmp/build/[% project %]-[% c('version') %]
  9. export CPPFLAGS=-DZSTD_MULTITHREAD
  10. export CC=[% c("var/configure_host") %]-clang
  11. make -C lib -j[% c("buildconf/num_procs") %] PREFIX=$distdir install
  12. # Only need static libraries
  13. rm $distdir/lib/libzstd.so*
  14. cd /var/tmp/dist
  15. [% c('tar', {
  16. tar_src => [ project ],
  17. tar_args => '-czf ' _ dest_dir _ '/' _ c('filename'),
  18. }) %]