This commit is contained in:
2016-05-29 18:10:44 +02:00
parent 61aa1de2e0
commit cb7005fff0
381 changed files with 73702 additions and 2 deletions

48
assets/mac/Makefile Normal file
View File

@ -0,0 +1,48 @@
### Sample DamnCute Engine based app Makefile ###
SRC = src/main.cpp \
src/Game.cpp
NAME = sample
CXXFLAGS = -Wall -Wextra -ansi -W -O2 -std=c++0x -I./include
CXX = clang++
OBJS = $(SRC:.cpp=.o)
LINKER = $(CXX)
LIB = ./libs
define SFML
$(LIB)/libsfml-$(1).2.dylib
endef
LIBSFML = $(call SFML,system) $(call SFML,audio) $(call SFML,graphics) $(call SFML,window)
LDFLAGS = -std=c++0x -stdlib=libc++ -headerpad_max_install_names $(LIB)/libdamncute.1.dylib $(LIBSFML) -L$(LIB) -Wl,-rpath $(LIB)
all: $(NAME)
$(NAME): $(OBJS)
$(LINKER) $(OBJS) $(LDFLAGS) -o $(NAME)
BUNDEST = $(NAME).app/Contents
STOPCOL = \x1b[0m
GREEN = \x1b[32;01m
bundle: $(NAME)
@mkdir -p $(BUNDEST)/MacOS $(BUNDEST)/Resources
@cp -R libs $(BUNDEST)/MacOS
@mv $(NAME) $(BUNDEST)/MacOS
@cd $(BUNDEST) && ln -s MacOS/libs Frameworks
@cd $(BUNDEST) && ln -s MacOS/libs libs
@cp -R util/Info.plist $(BUNDEST)
@cp -R util/launcher.sh $(BUNDEST)/MacOS
@cp -R util/Icon.icns $(BUNDEST)/Resources
@echo "Your OS X app bundle was created as $(GREEN)$(NAME).app$(STOPCOL)"
clean:
$(RM) $(OBJS) *.swp *~ *#
fclean: clean
@$(RM) -rf $(NAME).app
$(RM) $(NAME)
.PHONY: all clean fclean re

BIN
assets/mac/util/Icon.icns Normal file

Binary file not shown.

View File

@ -0,0 +1,26 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleExecutable</key>
<string>launcher.sh</string>
<key>CFBundleIconFile</key>
<string>Icon</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleGetInfoString</key>
<string>© 2013 yourteam</string>
<key>CFBundleIdentifier</key>
<string>com.yourteam.sample</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>sample</string>
<key>CFBundleShortVersionString</key>
<string>0.1</string>
<key>LSApplicationCategoryType</key>
<string>Game</string>
</dict>
</plist>

3
assets/mac/util/launcher.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/sh
cd "${0%/*}" ; cd ..
MacOS/sample $1 $2