OLD | NEW |
1 COCOS_ROOT = ../../../.. | 1 COCOS_ROOT = ../../../.. |
2 COCOS2DX_PATH = $(COCOS_ROOT)/cocos2dx | 2 COCOS2DX_PATH = $(COCOS_ROOT)/cocos2dx |
3 INCLUDES = -I../ -I../Classes | 3 INCLUDES = -I../ -I../Classes |
4 | 4 |
5 SOURCES = main.cpp \ | 5 SOURCES = main.cpp \ |
6 ../Classes/AppDelegate.cpp \ | 6 ../Classes/AppDelegate.cpp \ |
7 ../Classes/HelloWorldScene.cpp | 7 ../Classes/HelloWorldScene.cpp |
8 | 8 |
9 include $(COCOS_ROOT)/cocos2dx/proj.nacl/cocos2dx.mk | 9 include $(COCOS_ROOT)/cocos2dx/proj.nacl/cocos2dx.mk |
10 | 10 |
11 APP_NAME = HelloCpp | 11 APP_NAME = HelloCpp |
12 TARGET = $(BIN_DIR)/$(APP_NAME)_$(NACL_ARCH).nexe | 12 TARGET = $(BIN_DIR)/$(APP_NAME)_$(NACL_ARCH).nexe |
13 NMF = $(BIN_DIR)/$(APP_NAME).nmf | 13 NMF = $(BIN_DIR)/$(APP_NAME).nmf |
14 | 14 |
15 all: $(NMF) | 15 all: $(NMF) |
16 | 16 |
17 $(TARGET): $(OBJECTS) $(LIB_DIR)/libcocos2d.a $(CORE_MAKEFILE_LIST) | 17 $(TARGET): $(OBJECTS) $(LIB_DIR)/libcocos2d.a $(CORE_MAKEFILE_LIST) |
18 @mkdir -p $(@D) | 18 @mkdir -p $(@D) |
19 $(LOG_LINK)$(NACL_CXX) $(CXXFLAGS) $(LDFLAGS) $(OBJECTS) -o $@ $(SHAREDL
IBS) $(STATICLIBS) | 19 $(LOG_LINK)$(NACL_CXX) $(CXXFLAGS) $(LDFLAGS) $(OBJECTS) -o $@ $(SHAREDL
IBS) $(STATICLIBS) |
20 | 20 |
21 $(OBJ_DIR)/%.o: ../%.cpp $(CORE_MAKEFILE_LIST) | 21 $(OBJ_DIR)/%.o: ../%.cpp $(CORE_MAKEFILE_LIST) |
22 @mkdir -p $(@D) | 22 @mkdir -p $(@D) |
23 $(LOG_CXX)$(NACL_CXX) -MMD $(CXXFLAGS) $(INCLUDES) $(DEFINES) -c $< -o $
@ | 23 $(LOG_CXX)$(NACL_CXX) -MMD $(CXXFLAGS) $(INCLUDES) $(DEFINES) -c $< -o $
@ |
24 | 24 |
25 $(OBJ_DIR)/%.o: %.cpp $(CORE_MAKEFILE_LIST) | 25 $(OBJ_DIR)/%.o: %.cpp $(CORE_MAKEFILE_LIST) |
26 @mkdir -p $(@D) | 26 @mkdir -p $(@D) |
27 $(LOG_CXX)$(NACL_CXX) -MMD $(CXXFLAGS) $(INCLUDES) $(DEFINES) -c $< -o $
@ | 27 $(LOG_CXX)$(NACL_CXX) -MMD $(CXXFLAGS) $(INCLUDES) $(DEFINES) -c $< -o $
@ |
28 | 28 |
29 $(NMF): $(TARGET) | 29 $(NMF): $(TARGET) |
30 » $(NACL_SDK_ROOT)/tools/create_nmf.py -o $@ $(BIN_DIR)/*.nexe --objdump=i
686-nacl-objdump -L$(NACL_SDK_ROOT)/toolchain/linux_x86_newlib/x86_64-nacl/lib/
-s $(BIN_DIR) | 30 » $(NACL_SDK_ROOT)/tools/create_nmf.py -o $@ $(BIN_DIR)/*.nexe -s $(BIN_DI
R) $(NMF_FLAGS) |
31 | 31 |
32 run: all | 32 run: all |
33 /bin/cp -ar ../Resources/ . | 33 /bin/cp -ar ../Resources/ . |
34 $(NACL_SDK_ROOT)/tools/httpd.py --no_dir_check | 34 $(NACL_SDK_ROOT)/tools/httpd.py --no_dir_check |
35 | 35 |
36 .PHONY: run | 36 .PHONY: run |
OLD | NEW |