summaryrefslogtreecommitdiff
path: root/unzip
diff options
context:
space:
mode:
authorJoseph Hunkeler <jhunkeler@gmail.com>2020-06-04 17:53:44 -0400
committerJoseph Hunkeler <jhunkeler@gmail.com>2020-06-04 17:53:44 -0400
commit3b30be51008b8259db9b826b10096fb35d324a2e (patch)
tree40ed563750a299b93caa1f91f7f1885119833ea7 /unzip
parentbb038280d2b5e12916d14587fd5e82455b456698 (diff)
downloadspm_packages-3b30be51008b8259db9b826b10096fb35d324a2e.tar.gz
Back to linux development
Diffstat (limited to 'unzip')
-rw-r--r--unzip/build.sh23
1 files changed, 11 insertions, 12 deletions
diff --git a/unzip/build.sh b/unzip/build.sh
index 1f76944..bd26dc7 100644
--- a/unzip/build.sh
+++ b/unzip/build.sh
@@ -8,6 +8,7 @@ sources=(
build_depends=(
"bzip2"
"tar"
+ "patch"
)
depends=(
"bzip2"
@@ -33,29 +34,27 @@ function prepare() {
function build() {
DEFINES=
if [[ $(uname -s) == Linux ]]; then
- DEFINES='-DACORN_FTYPE_NFS -DWILD_STOP_AT_DIR -DLARGE_FILE_SUPPORT \
- -DUNICODE_SUPPORT -DUNICODE_WCHAR -DUTF8_MAYBE_NATIVE -DNO_LCHMOD \
- -DDATE_FORMAT=DF_YMD -DUSE_BZIP2 -DNOMEMCPY -DNO_WORKING_ISPRINT'
+ DEFINES='-DACORN_FTYPE_NFS -DWILD_STOP_AT_DIR -DLARGE_FILE_SUPPORT -DUNICODE_SUPPORT -DUNICODE_WCHAR -DUTF8_MAYBE_NATIVE -DNO_LCHMOD -DDATE_FORMAT=DF_YMD -DUSE_BZIP2 -DNOMEMCPY -DNO_WORKING_ISPRINT'
LF2="$LDFLAGS"
elif [[ $(uname -s) == Darwin ]]; then
DEFINES="-DUNIX -DBSD -DUSE_BZIP2"
LF2=""
fi
-
- echo make -f unix/Makefile \
+ make -f unix/Makefile \
D_USE_BZ2=-DUSE_BZIP2 \
L_BZ2=-lbz2 \
- CF=\"$CFLAGS $CPPFLAGS -I. $DEFINES\" \
- prefix=\"${_pkgdir}${_prefix}\" \
- unzips > run.sh
-
- chmod +x run.sh
- bash run.sh
+ CF="$CFLAGS $CPPFLAGS -I. $DEFINES" \
+ LF="$LDFLAGS" \
+ prefix="${_prefix}" \
+ unzips
}
function package() {
+ mkdir -p "${_pkgdir}${_prefix}"
+
+ [[ -f a.out ]] && mv a.out unzip
make -f unix/Makefile \
install \
- prefix="${_pkgdir}${_prefix}"
+ prefix="${_pkgdir}${_prefix}" || spm_debug_shell
}