# vim: filetype=yaml sw=2
version: '[% c("abbrev") %]'
git_url:  https://github.com/erikdubbelboer/gspt
git_hash: ce36a512837778923c9202c819eb6a3435f9d21d
filename: '[% project %]-[% c("version") %]-[% c("var/osname") %]-[% c("var/build_id") %].tar.gz'
container:
  use_container: 1

build: '[% c("projects/go/var/build_go_lib") %]'

var:
  go_lib: github.com/erikdubbelboer/gspt
  build_go_lib_pre: |
    [% pc(c('var/compiler'), 'var/setup', { compiler_tarfile => c('input_files_by_name/' _ c('var/compiler')) }) %]

    tar -C /var/tmp/dist -xf $rootdir/[% c('input_files_by_name/binutils') %]
    export PATH="/var/tmp/dist/binutils/bin:$PATH"

    export CGO_ENABLED=1

input_files:
  - project: container-image
  - name: go
    project: go
  - name: '[% c("var/compiler") %]'
    project: '[% c("var/compiler") %]'
  - name: binutils
    project: binutils
