@@ -15,42 +15,46 @@ pkgver() {
15
15
printf " %s.%s.%s" " ${_ver_base} " " $( git rev-list --count HEAD -- " $startdir " ) " " $( git rev-parse --short HEAD) "
16
16
}
17
17
18
- build () {
19
- test $startdir /$pkgname .install -nt $startdir /$pkgname .install.in ||
20
- sed -e " /^@@GITCONFIG@@$/r $startdir /gitconfig" -e " /^@@GITCONFIG@@$/d" \
21
- -e " /^@@GITATTRIBUTES@@$/r $startdir /gitattributes" \
18
+ prepare () {
19
+ test $startdir /$pkgname .install -nt $startdir /$pkgname .install.in &&
20
+ test $startdir /$pkgname .install -nt $startdir /resources/gitconfig &&
21
+ test $startdir /$pkgname .install -nt $startdir /resources/gitattributes ||
22
+ sed -e " /^@@GITCONFIG@@$/r $startdir /resources/gitconfig" \
23
+ -e " /^@@GITCONFIG@@$/d" \
24
+ -e " /^@@GITATTRIBUTES@@$/r $startdir /resources/gitattributes" \
22
25
-e " /^@@GITATTRIBUTES@@$/d" \
23
26
< $startdir /$pkgname .install.in > $startdir /$pkgname .install
27
+ }
24
28
25
- gcc -o create-shortcut.exe $startdir /create-shortcut.c -luuid -lole32
29
+ build () {
30
+ export CC=${MINGW_CHOST} -gcc
31
+ export CXX=${MINGW_CHOST} -g++
32
+ export SRCDIR=$startdir /sources
33
+ export BUILDDIR=build-${MINGW_CHOST}
34
+ mkdir -p ${BUILDDIR}
35
+ make -f $startdir /sources/Makefile
26
36
}
27
37
28
38
package () {
29
- case " $CARCH " in
30
- i686)
31
- mingwdir=" mingw32"
32
- ;;
33
- x86_64)
34
- mingwdir=" mingw64"
35
- ;;
36
- esac
37
-
39
+ builddir=build-${MINGW_CHOST}
38
40
install -d -m755 $pkgdir /etc/profile.d
39
41
install -d -m755 $pkgdir /etc/post-install
40
42
install -d -m755 $pkgdir /usr/bin
41
43
install -d -m755 $pkgdir /usr/share/git
42
- install -d -m755 $pkgdir /$mingwdir /bin
43
- install -m644 $startdir /inputrc $pkgdir /etc
44
- install -m644 $startdir /vimrc $pkgdir /etc
45
- install -m755 $startdir /vi $pkgdir /usr/bin
46
- install -m755 $startdir /notepad $pkgdir /usr/bin
47
- install -m755 $startdir /wordpad $pkgdir /usr/bin
48
- install -m755 create-shortcut.exe $pkgdir /$mingwdir /bin
49
- install -m755 $startdir /git-prompt.sh $pkgdir /etc/profile.d
50
- install -m755 $startdir /aliases.sh $pkgdir /etc/profile.d
51
- install -m755 $startdir /env.sh $pkgdir /etc/profile.d
52
- install -m755 $startdir /bash_profile.sh $pkgdir /etc/profile.d
53
- install -m644 $startdir /msys2-32.ico $pkgdir /usr/share/git
54
- install -m644 $startdir /99-post-install-cleanup.post $pkgdir /etc/post-install
55
- install -m755 $startdir /astextplain $pkgdir /$mingwdir /bin
44
+ install -d -m755 $pkgdir /${MINGW_PREFIX} /bin
45
+ install -m644 $startdir /resources/inputrc $pkgdir /etc
46
+ install -m644 $startdir /resources/vimrc $pkgdir /etc
47
+ install -m755 $startdir /scripts/vi $pkgdir /usr/bin
48
+ install -m755 $startdir /scripts/notepad $pkgdir /usr/bin
49
+ install -m755 $startdir /scripts/wordpad $pkgdir /usr/bin
50
+ install -m755 $builddir /create-shortcut.exe $pkgdir /${MINGW_PREFIX} /bin
51
+ install -m755 $builddir /WhoUses.exe $pkgdir /${MINGW_PREFIX} /bin
52
+ install -m755 $startdir /profile.d/git-prompt.sh $pkgdir /etc/profile.d
53
+ install -m755 $startdir /profile.d/aliases.sh $pkgdir /etc/profile.d
54
+ install -m755 $startdir /profile.d/env.sh $pkgdir /etc/profile.d
55
+ install -m755 $startdir /profile.d/bash_profile.sh $pkgdir /etc/profile.d
56
+ install -m644 $startdir /resources/msys2-32.ico $pkgdir /usr/share/git
57
+ install -m644 $startdir /scripts/99-post-install-cleanup.post \
58
+ $pkgdir /etc/post-install
59
+ install -m755 $startdir /scripts/astextplain $pkgdir /usr/bin
56
60
}
0 commit comments