forked from msysgit/msysgit
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrelease.sh
More file actions
35 lines (29 loc) · 725 Bytes
/
release.sh
File metadata and controls
35 lines (29 loc) · 725 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
#!/bin/sh
cd "$(dirname "$0")"
VERSION=1.15
DIR=popt-$VERSION
URL=http://rpm5.org/files/popt/$DIR.tar.gz
FILE=${URL##*/}
die () {
echo "$*" >&2
exit 1
}
test -d $DIR || {
test -f $FILE ||
curl -O $URL ||
die "Could not download $FILE"
tar xzvf $FILE && (
cd $DIR &&
git init &&
git add . &&
git commit -m "Import of $FILE" &&
git am ../patches/*
)
} || die "Could not check out $FILE"
(cd $DIR &&
CFLAGS="-I/git -I/git/compat/vcbuild/include" LDFLAGS="-L/git -L/git/xdiff" LIBS="-lgit -l:lib.a -lws2_32 -lz -liconv" ./configure --prefix=/mingw &&
make &&
index=$(/share/msysGit/pre-install.sh) &&
make install &&
/share/msysGit/post-install.sh $index "Install $FILE"
) || die "Could not install $FILE"