mirror of https://github.com/axmolengine/axmol.git
make HelloWorld and tests runs ok on linux
This commit is contained in:
parent
4b02dc3e45
commit
446bd86fce
|
@ -1,7 +1,7 @@
|
|||
CC = gcc
|
||||
CXX = g++
|
||||
AR = ar
|
||||
TARGET = libBox2D.a
|
||||
TARGET = libbox2d.a
|
||||
CCFLAGS = -Wall -g -O2
|
||||
CXXFLAGS = -Wall -g -O2
|
||||
ARFLAGS = cr
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
CC = gcc
|
||||
CXX = g++
|
||||
TARGET = libCocosDenshion.so
|
||||
TARGET = libcocosdenshion.so
|
||||
CCFLAGS = -Wall -g -O2
|
||||
CXXFLAGS = -Wall -g -O2
|
||||
VISIBILITY =
|
||||
|
|
|
@ -21,7 +21,7 @@ OBJECTS = ./main.o \
|
|||
STATICLIBS =
|
||||
SHAREDLIBS = -L../../lib/linux/Debug -lcocos2d -lrt -lz -lcocosdenshion -Wl,-rpath,../../lib/linux/Debug/
|
||||
|
||||
$(shell ../../build-linux.sh $<)
|
||||
#$(shell ../../build-linux.sh $<)
|
||||
####### Build rules
|
||||
$(TARGET): $(OBJECTS)
|
||||
$(CXX) $(CXXFLAGS) $(INCLUDES) $(DEFINES) $(OBJECTS) -o $(TARGET) $(SHAREDLIBS) $(STATICLIBS)
|
||||
|
|
|
@ -2,9 +2,10 @@
|
|||
#p=$(dirname $_)
|
||||
#echo "$p"
|
||||
|
||||
path=$(dirname $0)
|
||||
path=${path/\./$(pwd)}
|
||||
echo $path
|
||||
#path=$(dirname $0)
|
||||
#path=${path/\./$(pwd)}
|
||||
#echo $path
|
||||
p=.
|
||||
|
||||
if [ ! -d "lib" ]; then
|
||||
mkdir "lib"
|
||||
|
@ -31,20 +32,41 @@ if [ $# -ne 0 ]; then
|
|||
cd $p/CocosDenshion/proj.linux
|
||||
make clean
|
||||
|
||||
cd ../..
|
||||
cd $p/Box2D/proj.linux
|
||||
make clean
|
||||
|
||||
cd ../..
|
||||
cd $p/chipmunk/proj.linux
|
||||
make clean
|
||||
|
||||
cd ../../
|
||||
rm -r lib/linux/Debug/*.so
|
||||
fi
|
||||
|
||||
else
|
||||
cd $p/cocos2dx/proj.linux
|
||||
echo "**********************building cocos2dx**************************"
|
||||
make
|
||||
|
||||
cp -f libcocos2d.so ../../lib/linux/Debug
|
||||
|
||||
echo "**********************building cocosdenshion*********************"
|
||||
cd ../../
|
||||
cd $p/CocosDenshion/proj.linux
|
||||
make
|
||||
cp -f libcocosdenshion.so ../../lib/linux/Debug
|
||||
|
||||
cp -f libCocosDenshion.so ../../lib/linux/Debug
|
||||
echo "**********************building Box2D******************************"
|
||||
cd ../..
|
||||
cd $p/Box2D/proj.linux
|
||||
make
|
||||
cp -f libbox2d.a ../../lib/linux/Debug
|
||||
|
||||
echo "**********************building chipmunk***************************"
|
||||
cd ../..
|
||||
cd $p/chipmunk/proj.linux
|
||||
make
|
||||
cp -f libchipmunk.a ../../lib/linux/Debug
|
||||
|
||||
cd ../../
|
||||
fi
|
||||
|
|
|
@ -103,8 +103,8 @@ OBJECTS = ../tests/AccelerometerTest/AccelerometerTest.o \
|
|||
./main.o
|
||||
|
||||
STATICLIBS_DIR = ../../cocos2dx/platform/third_party/linux/libraries
|
||||
STATICLIBS = ../../Box2D/lib/linux/libBox2D.a \
|
||||
../../chipmunk/lib/linux/libchipmunk.a \
|
||||
STATICLIBS = ../../lib/linux/Debug/libbox2d.a \
|
||||
../../lib/linux/Debug/libchipmunk.a \
|
||||
$(STATICLIBS_DIR)/libcurl.a
|
||||
|
||||
SHAREDLIBS = -L../../lib/linux/Debug -lcocos2d -lrt -lz -lcocosdenshion -Wl,-rpath,../../lib/linux/Debug/
|
||||
|
|
Loading…
Reference in New Issue