-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
57 lines (45 loc) · 1.54 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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
RELEASEVER=0.1.0
ZIPDIR=tomboy-$(RELEASEVER)
CONFIGURATION=Release
BINDIR=$(shell pwd)/Tomboy-library/bin/$(CONFIGURATION)
RELEASEDIR=$(shell pwd)/release
NUNIT_RUNNER="nuget-packages/NUnit.Runners.2.6.3/tools/nunit-console.exe"
MONO=$(shell which mono)
XBUILD=$(shell which xbuild)
XBUILD_ARGS='/p:Configuration=$(CONFIGURATION)'
MKBUNDLE=$(shell which mkbundle)
UNPACKED_LIB=$(BINDIR)/Tomboy-library.dll
PACKED_LIB=Tomboy-library.dll
# Note this is the min version for building from source; running might work
# on older mono versions
MIN_MONO_VERSION=3.0.0
pack: build
@echo "Packing all assembly deps into the final .dll"
$(MONO) ./tools/ILRepack.exe /out:$(RELEASEDIR)/$(PACKED_LIB) $(BINDIR)/ServiceStack.*.dll
@echo ""
@echo "**********"
@echo "Success! Find your executable in $(RELEASEDIR)/$(PACKED_LIB)"
@echo "**********"
@echo ""
deps:
# if the next steps fails telling about security authentication, make sure
# you have imported trusted ssl CA certs with this command and re-run:
#
# mozroots --import --sync
#
@mono tools/NuGet.exe install -o nuget-packages packages.config
@echo "Successfully fetched dependencies."
build: deps
$(XBUILD) $(XBUILD_ARGS) Tomboy-library.sln
test: deps build
@mono $(NUNIT_RUNNER) ./Tomboy-library/Tomboy-library-tests/bin/$(CONFIGURATION)/Tomboy-library-tests.dll
release: clean pack
cp -R $(RELEASEDIR) $(ZIPDIR)
zip -r $(ZIPDIR).zip $(ZIPDIR)
clean:
rm -rf Tomboy-library/obj/*
rm -rf $(ZIPDIR)
rm -rf $(ZIPDIR).zip
rm -rf $(BINDIR)/*
rm -rf $(RELEASEDIR)/*.dll
rm -rf $(RELEASEDIR)/*.pdb