Skip to content

Commit

Permalink
Implement create cli binary task
Browse files Browse the repository at this point in the history
  • Loading branch information
Econa77 committed Jul 20, 2017
1 parent 2f7490c commit cc2f912
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
TEMPORARY_FOLDER?=/tmp/BartyCrouch.dst
BUILD_TOOL?=xcodebuild

XCODEFLAGS=-project 'BartyCrouch.xcodeproj' \
-scheme 'BartyCrouch CLI' \
-configuration 'Release' \
DSTROOT=$(TEMPORARY_FOLDER) \
OTHER_LDFLAGS=-Wl,-headerpad_max_install_names

BINARIES_FOLDER=/usr/local/bin
LICENSE_PATH="$(shell pwd)/LICENSE.md"

clean:
rm -rf "$(TEMPORARY_FOLDER)"
$(BUILD_TOOL) $(XCODEFLAGS) clean

installables: clean
$(BUILD_TOOL) $(XCODEFLAGS) install

portable_zip: installables
cp -f "$(TEMPORARY_FOLDER)$(BINARIES_FOLDER)/bartycrouch" "$(TEMPORARY_FOLDER)"
rm -f "./portable_bartycrouch.zip"
cp -f "$(LICENSE_PATH)" "$(TEMPORARY_FOLDER)"
(cd "$(TEMPORARY_FOLDER)"; zip -yr - "bartycrouch" "LICENSE.md") > "./portable_bartycrouch.zip"

0 comments on commit cc2f912

Please sign in to comment.