-
Notifications
You must be signed in to change notification settings - Fork 88
/
Copy pathMakefile
40 lines (33 loc) · 1.04 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
32
33
34
35
36
37
38
39
40
BINARY?=appicon
BUILD_FOLDER?=.build
OS?=ventura
PREFIX?=/usr/local
PROJECT?=AppIcon
RELEASE_BINARY_FOLDER?=$(BUILD_FOLDER)/release/$(PROJECT)
VERSION?=1.0.6
debug:
swift build
build:
swift build -c release --disable-sandbox --manifest-cache none
test:
swift test
clean:
swift package clean
rm -rf DerivedData
rm -rf $(BUILD_FOLDER)
install: build
mkdir -p $(PREFIX)/bin
cp -f $(RELEASE_BINARY_FOLDER) $(PREFIX)/bin/$(BINARY)
bottle: clean build
mkdir -p $(BINARY)/$(VERSION)/bin
cp README.md $(BINARY)/$(VERSION)/README.md
cp LICENSE.md $(BINARY)/$(VERSION)/LICENSE.md
cp INSTALL_RECEIPT.json $(BINARY)/$(VERSION)/INSTALL_RECEIPT.json
cp -f $(RELEASE_BINARY_FOLDER) $(BINARY)/$(VERSION)/bin/$(BINARY)
tar cfvz $(BINARY)-$(VERSION).$(OS).bottle.tar.gz --exclude='*/.*' $(BINARY)
shasum -a 256 $(BINARY)-$(VERSION).$(OS).bottle.tar.gz
rm -rf $(BINARY)
sha256:
wget https://github.com/Nonchalant/$(PROJECT)/archive/$(VERSION).tar.gz -O $(PROJECT)-$(VERSION).tar.gz
shasum -a 256 $(PROJECT)-$(VERSION).tar.gz
rm $(PROJECT)-$(VERSION).tar.gz