-
-
Notifications
You must be signed in to change notification settings - Fork 4
/
Makefile
34 lines (27 loc) · 858 Bytes
/
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
32
33
34
clean:
go clean
rm -rf build/
build:
CGO_ENABLED=1 GOOS=darwin GOARCH=arm64 go build -o build/timeow-mac_arm64
CGO_ENABLED=1 GOOS=darwin GOARCH=amd64 go build -o build/timeow-mac_amd64
lipo -create -output build/timeow-mac build/timeow-mac_amd64 build/timeow-mac_arm64
build-mac-app:
mkdir -p build/app
cd Timeow/ && xcodebuild
cp -r Timeow/build/Release/Timeow.app build/app/
copy-binary-to-mac:
cp build/timeow-mac build/app/Timeow.app/Contents/MacOS/Timeow
create-dmg:
create-dmg \
--volname "Timeow Installer" \
--window-pos 200 120 \
--window-size 800 400 \
--icon-size 100 \
--icon "Timeow.app" 200 190 \
--hide-extension "Timeow.app" \
--app-drop-link 600 185 \
"build/Timeow.dmg" \
"build/app/"
dist-mac-app: clean build build-mac-app copy-binary-to-mac
dist-mac-dmg: dist-mac-app create-dmg
.PHONY: build