-
Notifications
You must be signed in to change notification settings - Fork 48
/
Makefile
31 lines (25 loc) · 1.02 KB
/
Makefile
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
# Shameless fork from the far superior https://github.com/clburlison/pinpoint/blob/master/Makefile
PKGTITLE="vfuse"
PKGVERSION="3.0.0"
PKGID=com.github.vfuse
PROJECT="vfuse"
#################################################
##Help - Show this help menu
help:
@fgrep -h "##" $(MAKEFILE_LIST) | fgrep -v fgrep | sed -e 's/\\$$//' | sed -e 's/##//'
## clean - Clean up temporary working directories
clean:
rm -f ./vfuse*.{dmg,pkg}
rm -f ./pkgroot/usr/local/vfuse/bin/*.pyc
## pkg - Create a package using pkgbuild
pkg: clean
pkgbuild --root pkgroot --identifier ${PKGID} --version ${PKGVERSION} --ownership recommended ./${PKGTITLE}-${PKGVERSION}.pkg
## dmg - Wrap the package inside a dmg
dmg: pkg
rm -f ./${PROJECT}*.dmg
rm -rf /tmp/${PROJECT}-build
mkdir -p /tmp/${PROJECT}-build/
cp ./README.md /tmp/${PROJECT}-build
cp -R ./${PKGTITLE}-${PKGVERSION}.pkg /tmp/${PROJECT}-build
hdiutil create -srcfolder /tmp/${PROJECT}-build -volname "${PROJECT}" -format UDZO -o ${PROJECT}-${PKGVERSION}.dmg
rm -rf /tmp/${PROJECT}-build