-
Notifications
You must be signed in to change notification settings - Fork 7
/
Makefile.osx
48 lines (39 loc) · 1.62 KB
/
Makefile.osx
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
36
37
38
39
40
41
42
43
44
45
46
47
48
# On OS X, we use xcode. This is just a simple makefile to call
# xcodebuild to build ezRETS
srcdir = .
include $(srcdir)/project/build/version.mk
MODE = Debug
#MODE = Release
all: ezrets ezretss register_driver
ezrets:
cd project/build && xcodebuild -target ezrets -configuration $(MODE)
ezretss:
cd project/build && xcodebuild -target ezretss -configuration $(MODE)
register_driver:
cd project/build && xcodebuild -target register_driver -configuration $(MODE)
ddl:
cd project/build && xcodebuild -target generatedef -configuration $(MODE)
clean:
cd project/build && xcodebuild -target ezrets -configuration $(MODE) clean
cd project/build && xcodebuild -target ezretss -configuration $(MODE) clean
cd project/build && xcodebuild -target register_driver -configuration $(MODE) clean
rm -rf dist
install:
cp build/xcode/$(MODE)/ezrets*.dylib /Library/ODBC/ezRETS
build/xcode/$(MODE)/register_driver -r
build/xcode/$(MODE)/register_driver -i
dist: all
mkdir -p dist/osx
cp README dist/osx/README.txt
cp LICENSE dist/osx/LICENSE.txt
/Developer/usr/bin/packagemaker -v -n $(VERSION) -i org.realtors.crt.ezrets -d project/build/new_OSX_Package.pmdoc -o dist/osx/ezRETS-$(VERSION).pkg
cp doc/SQL_Reference.html dist/osx
cp project/build/rdrive.icns 'dist/osx/.VolumeIcon.icns'
hdiutil create -ov dist/tmp.dmg -fs HFS+ -volname 'ezRETS $(VERSION)' -uid 99 -gid 99 -srcfolder dist/osx -format UDRW
hdiutil attach dist/tmp.dmg
/Developer/usr/bin/SetFile -a C /Volumes/ezRETS\ $(VERSION)
sync
sleep 1
hdiutil detach /Volumes/ezRETS\ $(VERSION)
hdiutil convert dist/tmp.dmg -format UDBZ -o dist/ezRETS-osx-$(VERSION).dmg
rm dist/tmp.dmg