mirror of
https://github.com/ivabus/pantry
synced 2024-11-10 02:25:18 +03:00
+go+unzip+tar (#74)
This commit is contained in:
parent
6cef318164
commit
c7e3d90b60
5
.github/workflows/ci.yml
vendored
5
.github/workflows/ci.yml
vendored
|
@ -69,10 +69,6 @@ jobs:
|
|||
exit 1
|
||||
esac
|
||||
|
||||
- name: HACKS
|
||||
uses: denoland/setup-deno@v1
|
||||
if: ${{ matrix.os == 'macos-11' }}
|
||||
|
||||
- uses: teaxyz/setup@v0
|
||||
env:
|
||||
TEA_SECRET: ${{ secrets.TEA_SECRET }}
|
||||
|
@ -88,6 +84,7 @@ jobs:
|
|||
id: build
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ github.token }}
|
||||
FORCE_UNSAFE_CONFIGURE: 1 # some configure scripts refuse to run as root
|
||||
|
||||
- name: Test
|
||||
run: |
|
||||
|
|
19
projects/gnu.org/tar/package.yml
Normal file
19
projects/gnu.org/tar/package.yml
Normal file
|
@ -0,0 +1,19 @@
|
|||
distributable:
|
||||
url: https://ftp.gnu.org/gnu/tar/tar-{{ version.raw }}.tar.gz
|
||||
strip-components: 1
|
||||
|
||||
versions:
|
||||
- 1.34
|
||||
#TODO scrape https://ftp.gnu.org/gnu/tar/
|
||||
|
||||
build:
|
||||
dependencies:
|
||||
tea.xyz/gx/cc: 'c99'
|
||||
tea.xyz/gx/make: '*'
|
||||
script: |
|
||||
./configure --prefix={{ prefix }} --disable-debug
|
||||
make --jobs {{ hw.concurrency }} install
|
||||
|
||||
test:
|
||||
script:
|
||||
tar czvf test.tar.gz {{ prefix }}
|
68
projects/go.dev/package.yml
Normal file
68
projects/go.dev/package.yml
Normal file
|
@ -0,0 +1,68 @@
|
|||
distributable:
|
||||
url: https://go.dev/dl/go{{ version.raw }}.src.tar.gz
|
||||
strip-components: 1
|
||||
|
||||
versions:
|
||||
github: golang/go/tags
|
||||
strip: /^go/
|
||||
|
||||
relocatable: true
|
||||
|
||||
provides:
|
||||
- bin/go
|
||||
|
||||
interprets:
|
||||
- .go
|
||||
|
||||
build:
|
||||
dependencies:
|
||||
gnu.org/m4: 1
|
||||
tea.xyz/gx/make: '*'
|
||||
tea.xyz/gx/cc: c99
|
||||
curl.se: '*'
|
||||
script: |-
|
||||
export GOROOT_BOOTSTRAP="$(cd ../.. && echo $PWD)/bootstrap"
|
||||
if test -d $GOROOT_BOOTSTRAP
|
||||
then
|
||||
true
|
||||
else
|
||||
# TODO something better than this...
|
||||
case "X{{ hw.target }}" in
|
||||
"Xaarch64-apple-darwin") GOARCH="darwin-arm64";;
|
||||
"Xx86_64-apple-darwin") GOARCH="darwin-amd64";;
|
||||
"Xx86_64-unknown-linux-gnu") GOARCH="linux-amd64";;
|
||||
"Xxaarch64-unknown-linux-gnu") GOARCH="linux-arm64";;
|
||||
*)
|
||||
echo "Unknown arch. Please update the pantry."
|
||||
exit 1
|
||||
esac
|
||||
|
||||
curl -L https://storage.googleapis.com/golang/go1.16.${GOARCH}.tar.gz | tar xzf - -C ../..
|
||||
mv ../../go ../../bootstrap
|
||||
fi
|
||||
|
||||
export GOROOT_BOOTSTRAP="$(cd ../.. && echo $PWD)/bootstrap"
|
||||
export GOROOT_FINAL="{{ prefix }}"
|
||||
cd src
|
||||
./make.bash
|
||||
|
||||
# cleanup
|
||||
cd ../..
|
||||
mv src foo
|
||||
mv foo/* .
|
||||
rmdir foo
|
||||
rm src/*.{bash,bat,rc}
|
||||
rm src/Make.dist
|
||||
find . -mindepth 1 -maxdepth 1 -type f -delete -not -name build.sh
|
||||
|
||||
test:
|
||||
script: |
|
||||
mv $FIXTURE $FIXTURE.go
|
||||
OUTPUT=$(go run $FIXTURE.go)
|
||||
test "Hello World" = "$OUTPUT"
|
||||
fixture: |
|
||||
package main
|
||||
import "fmt"
|
||||
func main() {
|
||||
fmt.Println("Hello World")
|
||||
}
|
37
projects/info-zip.org/unzip/package.yml
Normal file
37
projects/info-zip.org/unzip/package.yml
Normal file
|
@ -0,0 +1,37 @@
|
|||
distributable:
|
||||
url:
|
||||
https://downloads.sourceforge.net/project/infozip/UnZip
|
||||
{{ version.major }}.x
|
||||
(latest)/UnZip
|
||||
{{ version.raw }}/unzip{{ version.major }}{{version.minor }}.tar.gz
|
||||
strip-components: 1
|
||||
|
||||
versions:
|
||||
- '6.0'
|
||||
|
||||
#TODO
|
||||
# see brew formula, they apply a SHIT TONNE of patches
|
||||
# because this is unmaintained I guess
|
||||
# https://github.com/Homebrew/homebrew-core/blob/HEAD/Formula/unzip.rb
|
||||
|
||||
build:
|
||||
dependencies:
|
||||
tea.xyz/gx/cc: c99
|
||||
tea.xyz/gx/make: '*'
|
||||
script: |
|
||||
case {{ hw.platform }} in
|
||||
darwin) TARGET=macosx;;
|
||||
linux) TARGET=macosx;; #SURPRISE!
|
||||
esac
|
||||
make --file unix/Makefile --jobs {{ hw.concurrency }} $TARGET
|
||||
make prefix={{prefix}} install
|
||||
|
||||
test:
|
||||
script: unzip -h
|
||||
|
||||
provides:
|
||||
- bin/funzip
|
||||
- bin/unzip
|
||||
- bin/unzipsfx
|
||||
- bin/zipgrep
|
||||
- bin/zipinfo
|
Loading…
Reference in a new issue