Add untar.c

This commit is contained in:
Andrius Štikonas 2021-04-15 01:00:51 +01:00
parent 0d64413670
commit f030a3a74e
10 changed files with 56 additions and 29 deletions

View file

@ -50,20 +50,26 @@ cd ${pkg}
kaem --file ${pkg}.kaem
cd ..
# untar
pkg="untar"
cd ${pkg}
kaem --file ${pkg}.kaem
cd ..
# tcc 0.9.27
pkg="tcc-0.9.27"
cd ${pkg}
kaem --file ${pkg}.kaem
cd ..
# tar
pkg="tar-1.12"
# gzip
pkg="gzip-1.2.4"
cd ${pkg}
kaem --file ${pkg}.kaem
cd ..
# gzip
pkg="gzip-1.2.4"
# tar
pkg="tar-1.12"
cd ${pkg}
kaem --file ${pkg}.kaem
cd ..

View file

@ -11,7 +11,7 @@ set -ex
cd build
# Extract
tar xf ../src/${pkg}.tar
untar ../src/${pkg}.tar
cd ${pkg}
# Compile

View file

@ -15,6 +15,7 @@ e94a2468c045582cfd13df51acd0932afdc834fa60139f7bfb7a2d65afa39a65 /after/bin/mes
3cf426251744300a099a40f3609ccbd32ec3b9f3334601defa5736e7fd6c6f1d /after/bin/patch
d453932b7d83fc3e183afeca65c1afb2a620b985c378ee072710e0cc593d9811 /after/bin/sed
bc9ddf9854bd954c71bb1cf5b0af77fd65b8fa7f290b42c75020fb8893deb53c /after/bin/sha256sum
74e0a13cb6e92d70c43f71ec704afbc44b7a38c703fe40700f7af7c640a22158 /after/bin/untar
957229511dc5ac62a949dbd76e965e3a476ce214b8e6fc7f120bf17d195b924b /after/bin/tar
690c2a941c444ba761076f6b8ef1ba2b634ebe2e63ea44c8f3789f6e3df6d2a9 /after/bin/tcc
cacc2cda3ce6c2cc0cb761b8aa2115a003e166c94d1039974fc0221263897c52 /after/bin/tcc-0.9.26

View file

@ -8,9 +8,15 @@
set -ex
cp files/getdate_stub.c src/lib/getdate_stub.c
cd build
cd src
# Extract
gunzip ../src/${pkg}.tar.gz
untar ../src/${pkg}.tar
cd ${pkg}
cp ../../files/getdate_stub.c lib/getdate_stub.c
# Compile
@ -57,7 +63,7 @@ tcc -c -I lib -DSIZEOF_UNSIGNED_LONG=4 -DHAVE_FCNTL_H src/update.c
# Link
tcc -static -o ${bindir}/tar -L lib lib/libtar.a arith.o buffer.o compare.o create.o delete.o extract.o incremen.o list.o mangle.o misc.o names.o open3.o rtapelib.o tar.o update.o -ltar
cd ..
cd ../..
# Checksums
fletcher16 checksums

View file

@ -1,6 +1,5 @@
#!/bin/sh
# SPDX-FileCopyrightText: 2021 fosslinux <fosslinux@aussies.space>
# SPDX-FileCopyrightText: 2021 fosslinux <fosslinux@aussies.space>
#
# SPDX-License-Identifier: GPL-3.0-or-later

1
sysa/untar/checksums Normal file
View file

@ -0,0 +1 @@
27524 /after/bin/untar

14
sysa/untar/untar.kaem Executable file
View file

@ -0,0 +1,14 @@
#!/bin/sh
# SPDX-FileCopyrightText: 2021 Andrius Štikonas <andrius@stikonas.eu>
#
# SPDX-License-Identifier: GPL-3.0-or-later
set -ex
# Compile
# 0.9.26 is intentional as later tcc segfaults when linking
tcc-0.9.26 src/untar.c -o ${bindir}/untar
# Checksums
fletcher16 checksums