mirror of https://github.com/axmolengine/axmol.git
Merge pull request #1752 from dumganhar/linux-lua
fixed #1611: Adding lua support for linux platform
This commit is contained in:
commit
597a6f181d
|
@ -92,6 +92,16 @@ make -C $COCOS2DX20_TRUNK/CocosDenshion/proj.linux release
|
|||
check_make_result
|
||||
cp $COCOS2DX20_TRUNK/CocosDenshion/proj.linux/libcocosdenshion.so $OUTPUT_RELEASE
|
||||
|
||||
make -C $COCOS2DX20_TRUNK/scripting/lua/proj.linux clean
|
||||
make -C $COCOS2DX20_TRUNK/scripting/lua/proj.linux debug
|
||||
check_make_result
|
||||
cp $COCOS2DX20_TRUNK/scripting/lua/proj.linux/liblua.so $OUTPUT_DEBUG
|
||||
|
||||
make -C $COCOS2DX20_TRUNK/scripting/lua/proj.linux clean
|
||||
make -C $COCOS2DX20_TRUNK/scripting/lua/proj.linux release
|
||||
check_make_result
|
||||
cp $COCOS2DX20_TRUNK/scripting/lua/proj.linux/liblua.so $OUTPUT_RELEASE
|
||||
|
||||
make -C $COCOS2DX20_TRUNK/samples/TestCpp/proj.linux clean
|
||||
make -C $COCOS2DX20_TRUNK/samples/TestCpp/proj.linux debug
|
||||
check_make_result
|
||||
|
@ -105,3 +115,18 @@ check_make_result
|
|||
make -C $COCOS2DX20_TRUNK/samples/HelloCpp/proj.linux clean
|
||||
make -C $COCOS2DX20_TRUNK/samples/HelloCpp/proj.linux release
|
||||
check_make_result
|
||||
|
||||
make -C $COCOS2DX20_TRUNK/samples/TestLua/proj.linux clean
|
||||
make -C $COCOS2DX20_TRUNK/samples/TestLua/proj.linux debug
|
||||
check_make_result
|
||||
make -C $COCOS2DX20_TRUNK/samples/TestLua/proj.linux clean
|
||||
make -C $COCOS2DX20_TRUNK/samples/TestLua/proj.linux release
|
||||
check_make_result
|
||||
|
||||
make -C $COCOS2DX20_TRUNK/samples/HelloLua/proj.linux clean
|
||||
make -C $COCOS2DX20_TRUNK/samples/HelloLua/proj.linux debug
|
||||
check_make_result
|
||||
make -C $COCOS2DX20_TRUNK/samples/HelloLua/proj.linux clean
|
||||
make -C $COCOS2DX20_TRUNK/samples/HelloLua/proj.linux release
|
||||
check_make_result
|
||||
|
||||
|
|
|
@ -0,0 +1,223 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<?fileVersion 4.0.0?>
|
||||
|
||||
<cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
|
||||
<storageModule moduleId="org.eclipse.cdt.core.settings">
|
||||
<cconfiguration id="cdt.managedbuild.config.gnu.exe.debug.1394655853">
|
||||
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="cdt.managedbuild.config.gnu.exe.debug.1394655853" moduleId="org.eclipse.cdt.core.settings" name="Debug">
|
||||
<externalSettings/>
|
||||
<extensions>
|
||||
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.debug,org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="" id="cdt.managedbuild.config.gnu.exe.debug.1394655853" name="Debug" parent="cdt.managedbuild.config.gnu.exe.debug" prebuildStep="mkdir -p bin">
|
||||
<folderInfo id="cdt.managedbuild.config.gnu.exe.debug.1394655853." name="/" resourcePath="">
|
||||
<toolChain id="cdt.managedbuild.toolchain.gnu.exe.debug.587717503" name="Linux GCC" superClass="cdt.managedbuild.toolchain.gnu.exe.debug">
|
||||
<targetPlatform id="cdt.managedbuild.target.gnu.platform.exe.debug.1954079680" name="Debug Platform" superClass="cdt.managedbuild.target.gnu.platform.exe.debug"/>
|
||||
<builder buildPath="${workspace_loc:/HelloLua/Debug}" id="cdt.managedbuild.target.gnu.builder.exe.debug.1330170048" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="cdt.managedbuild.target.gnu.builder.exe.debug"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.archiver.base.443045420" name="GCC Archiver" superClass="cdt.managedbuild.tool.gnu.archiver.base"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.cpp.compiler.exe.debug.1641148135" name="GCC C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.exe.debug">
|
||||
<option id="gnu.cpp.compiler.exe.debug.option.optimization.level.1288035863" name="Optimization Level" superClass="gnu.cpp.compiler.exe.debug.option.optimization.level" value="gnu.cpp.compiler.optimization.level.none" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.exe.debug.option.debugging.level.1953924387" name="Debug Level" superClass="gnu.cpp.compiler.exe.debug.option.debugging.level" value="gnu.cpp.compiler.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.option.include.paths.211389888" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../Classes"/>
|
||||
<listOptionValue builtIn="false" value="../../../"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/kazmath/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/cocos2dx_support"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/lua"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/tolua"/>
|
||||
</option>
|
||||
<option id="gnu.cpp.compiler.option.preprocessor.def.1051109295" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="LINUX"/>
|
||||
</option>
|
||||
<option id="gnu.cpp.compiler.option.preprocessor.nostdinc.669368697" name="Do not search system directories (-nostdinc)" superClass="gnu.cpp.compiler.option.preprocessor.nostdinc" value="false" valueType="boolean"/>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.compiler.input.934526043" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.compiler.exe.debug.1128931475" name="GCC C Compiler" superClass="cdt.managedbuild.tool.gnu.c.compiler.exe.debug">
|
||||
<option defaultValue="gnu.c.optimization.level.none" id="gnu.c.compiler.exe.debug.option.optimization.level.836473983" name="Optimization Level" superClass="gnu.c.compiler.exe.debug.option.optimization.level" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.exe.debug.option.debugging.level.1973048529" name="Debug Level" superClass="gnu.c.compiler.exe.debug.option.debugging.level" value="gnu.c.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.option.include.paths.118045791" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../Classes"/>
|
||||
<listOptionValue builtIn="false" value="../../../"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/kazmath/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/cocos2dx_support"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/lua"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/tolua"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.133301301" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.linker.exe.debug.1072658517" name="GCC C Linker" superClass="cdt.managedbuild.tool.gnu.c.linker.exe.debug"/>
|
||||
<tool commandLinePattern="${COMMAND} ${FLAGS} ${OUTPUT_FLAG} bin/${OUTPUT_PREFIX}${OUTPUT} ${INPUTS} -Wl,-rpath,${ProjDirPath}/../../../cocos2dx/proj.linux/${ConfigName} -Wl,-rpath,${ProjDirPath}/../../../CocosDenshion/proj.linux/${ConfigName} -Wl,-rpath,${ProjDirPath}/../../../CocosDenshion/third_party/fmod/api/lib -Wl,-rpath,../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib -Wl,-rpath,${ProjDirPath}/../../../scripting/lua/proj.linux/${ConfigName}" id="cdt.managedbuild.tool.gnu.cpp.linker.exe.debug.1586375348" name="GCC C++ Linker" superClass="cdt.managedbuild.tool.gnu.cpp.linker.exe.debug">
|
||||
<option id="gnu.cpp.link.option.libs.1037237731" name="Libraries (-l)" superClass="gnu.cpp.link.option.libs" valueType="libs">
|
||||
<listOptionValue builtIn="false" value="cocos2d"/>
|
||||
<listOptionValue builtIn="false" value="cocosdenshion"/>
|
||||
<listOptionValue builtIn="false" value="z"/>
|
||||
<listOptionValue builtIn="false" value="GLEW"/>
|
||||
<listOptionValue builtIn="false" value="lua"/>
|
||||
<listOptionValue builtIn="false" srcPrefixMapping="" srcRootPath="" value="fmodex"/>
|
||||
</option>
|
||||
<option id="gnu.cpp.link.option.paths.460163571" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths" valueType="libPaths">
|
||||
<listOptionValue builtIn="false" value=""../../../../cocos2dx/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib"/>
|
||||
<listOptionValue builtIn="false" value=""../../../../CocosDenshion/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value=""../../../../scripting/lua/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/third_party/fmod/api/lib"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.linker.input.1994732022" superClass="cdt.managedbuild.tool.gnu.cpp.linker.input">
|
||||
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
|
||||
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
|
||||
</inputType>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.assembler.exe.debug.321497636" name="GCC Assembler" superClass="cdt.managedbuild.tool.gnu.assembler.exe.debug">
|
||||
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.25214244" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||
</tool>
|
||||
</toolChain>
|
||||
</folderInfo>
|
||||
<sourceEntries>
|
||||
<entry excluding="Classes|cocos2dx_support" flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name=""/>
|
||||
<entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="Classes"/>
|
||||
<entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="cocos2dx_support"/>
|
||||
</sourceEntries>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||
</cconfiguration>
|
||||
<cconfiguration id="cdt.managedbuild.config.gnu.exe.release.495970395">
|
||||
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="cdt.managedbuild.config.gnu.exe.release.495970395" moduleId="org.eclipse.cdt.core.settings" name="Release">
|
||||
<externalSettings/>
|
||||
<extensions>
|
||||
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.release,org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="" id="cdt.managedbuild.config.gnu.exe.release.495970395" name="Release" parent="cdt.managedbuild.config.gnu.exe.release" prebuildStep="mkdir -p bin">
|
||||
<folderInfo id="cdt.managedbuild.config.gnu.exe.release.495970395." name="/" resourcePath="">
|
||||
<toolChain id="cdt.managedbuild.toolchain.gnu.exe.release.1550851817" name="Linux GCC" superClass="cdt.managedbuild.toolchain.gnu.exe.release">
|
||||
<targetPlatform id="cdt.managedbuild.target.gnu.platform.exe.release.1280250072" name="Debug Platform" superClass="cdt.managedbuild.target.gnu.platform.exe.release"/>
|
||||
<builder buildPath="${workspace_loc:/HelloLua/Release}" id="cdt.managedbuild.target.gnu.builder.exe.release.110488562" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="cdt.managedbuild.target.gnu.builder.exe.release"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.archiver.base.566216984" name="GCC Archiver" superClass="cdt.managedbuild.tool.gnu.archiver.base"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.cpp.compiler.exe.release.463501277" name="GCC C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.exe.release">
|
||||
<option id="gnu.cpp.compiler.exe.release.option.optimization.level.1053195650" name="Optimization Level" superClass="gnu.cpp.compiler.exe.release.option.optimization.level" value="gnu.cpp.compiler.optimization.level.most" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.exe.release.option.debugging.level.427789803" name="Debug Level" superClass="gnu.cpp.compiler.exe.release.option.debugging.level" value="gnu.cpp.compiler.debugging.level.none" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.option.include.paths.364171968" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../Classes"/>
|
||||
<listOptionValue builtIn="false" value="../../../"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/kazmath/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/cocos2dx_support"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/lua"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/tolua"/>
|
||||
</option>
|
||||
<option id="gnu.cpp.compiler.option.preprocessor.def.1476822880" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="LINUX"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.compiler.input.1236573481" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.compiler.exe.release.256499490" name="GCC C Compiler" superClass="cdt.managedbuild.tool.gnu.c.compiler.exe.release">
|
||||
<option defaultValue="gnu.c.optimization.level.most" id="gnu.c.compiler.exe.release.option.optimization.level.1089146598" name="Optimization Level" superClass="gnu.c.compiler.exe.release.option.optimization.level" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.exe.release.option.debugging.level.694016269" name="Debug Level" superClass="gnu.c.compiler.exe.release.option.debugging.level" value="gnu.c.debugging.level.none" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.option.include.paths.2134950584" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../Classes"/>
|
||||
<listOptionValue builtIn="false" value="../../../"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/kazmath/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/cocos2dx_support"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/lua"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/tolua"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.1364172511" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.linker.exe.release.1905566123" name="GCC C Linker" superClass="cdt.managedbuild.tool.gnu.c.linker.exe.release"/>
|
||||
<tool commandLinePattern="${COMMAND} ${FLAGS} ${OUTPUT_FLAG} bin/${OUTPUT_PREFIX}${OUTPUT} ${INPUTS} -Wl,-rpath,${ProjDirPath}/../../../cocos2dx/proj.linux/${ConfigName} -Wl,-rpath,${ProjDirPath}/../../../CocosDenshion/proj.linux/${ConfigName} -Wl,-rpath,${ProjDirPath}/../../../CocosDenshion/third_party/fmod/api/lib -Wl,-rpath,../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib -Wl,-rpath,${ProjDirPath}/../../../scripting/lua/proj.linux/${ConfigName}" id="cdt.managedbuild.tool.gnu.cpp.linker.exe.release.1627066539" name="GCC C++ Linker" superClass="cdt.managedbuild.tool.gnu.cpp.linker.exe.release">
|
||||
<option id="gnu.cpp.link.option.libs.358636351" name="Libraries (-l)" superClass="gnu.cpp.link.option.libs" valueType="libs">
|
||||
<listOptionValue builtIn="false" value="cocos2d"/>
|
||||
<listOptionValue builtIn="false" value="cocosdenshion"/>
|
||||
<listOptionValue builtIn="false" value="z"/>
|
||||
<listOptionValue builtIn="false" value="GLEW"/>
|
||||
<listOptionValue builtIn="false" value="lua"/>
|
||||
<listOptionValue builtIn="false" value="fmodex"/>
|
||||
</option>
|
||||
<option id="gnu.cpp.link.option.paths.1057267673" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths" valueType="libPaths">
|
||||
<listOptionValue builtIn="false" value=""../../../../cocos2dx/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib"/>
|
||||
<listOptionValue builtIn="false" value=""../../../../CocosDenshion/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value=""../../../../scripting/lua/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/third_party/fmod/api/lib"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.linker.input.1504398445" superClass="cdt.managedbuild.tool.gnu.cpp.linker.input">
|
||||
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
|
||||
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
|
||||
</inputType>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.assembler.exe.release.1352259804" name="GCC Assembler" superClass="cdt.managedbuild.tool.gnu.assembler.exe.release">
|
||||
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.1839984020" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||
</tool>
|
||||
</toolChain>
|
||||
</folderInfo>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||
</cconfiguration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<project id="HelloLua.cdt.managedbuild.target.gnu.exe.1621885118" name="Executable" projectType="cdt.managedbuild.target.gnu.exe"/>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
|
||||
<storageModule moduleId="refreshScope" versionNumber="2">
|
||||
<configuration configurationName="Release">
|
||||
<resource resourceType="PROJECT" workspacePath="/HelloLua"/>
|
||||
</configuration>
|
||||
<configuration configurationName="Debug">
|
||||
<resource resourceType="PROJECT" workspacePath="/HelloLua"/>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="scannerConfiguration">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.release.495970395;cdt.managedbuild.config.gnu.exe.release.495970395.;cdt.managedbuild.tool.gnu.c.compiler.exe.release.256499490;cdt.managedbuild.tool.gnu.c.compiler.input.1364172511">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.debug.1394655853;cdt.managedbuild.config.gnu.exe.debug.1394655853.;cdt.managedbuild.tool.gnu.cpp.compiler.exe.debug.1641148135;cdt.managedbuild.tool.gnu.cpp.compiler.input.934526043">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.debug.1394655853;cdt.managedbuild.config.gnu.exe.debug.1394655853.;cdt.managedbuild.tool.gnu.c.compiler.exe.debug.1128931475;cdt.managedbuild.tool.gnu.c.compiler.input.133301301">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.release.495970395;cdt.managedbuild.config.gnu.exe.release.495970395.;cdt.managedbuild.tool.gnu.cpp.compiler.exe.release.463501277;cdt.managedbuild.tool.gnu.cpp.compiler.input.1236573481">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.internal.ui.text.commentOwnerProjectMappings"/>
|
||||
</cproject>
|
|
@ -0,0 +1,42 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>HelloLua</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
<project>libcocos2d</project>
|
||||
<project>libCocosDenshion</project>
|
||||
<project>liblua</project>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
|
||||
<triggers>clean,full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
|
||||
<triggers>full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.cdt.core.cnature</nature>
|
||||
<nature>org.eclipse.cdt.core.ccnature</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
|
||||
</natures>
|
||||
<linkedResources>
|
||||
<link>
|
||||
<name>Classes</name>
|
||||
<type>2</type>
|
||||
<locationURI>PARENT-1-PROJECT_LOC/Classes</locationURI>
|
||||
</link>
|
||||
<link>
|
||||
<name>cocos2dx_support</name>
|
||||
<type>2</type>
|
||||
<locationURI>PARENT-3-PROJECT_LOC/scripting/lua/cocos2dx_support</locationURI>
|
||||
</link>
|
||||
</linkedResources>
|
||||
</projectDescription>
|
|
@ -0,0 +1,95 @@
|
|||
CC = gcc
|
||||
CXX = g++
|
||||
TARGET = HelloLua
|
||||
CCFLAGS = -Wall
|
||||
CXXFLAGS = -Wall
|
||||
VISIBILITY =
|
||||
|
||||
COCOS2DX_PATH = ../../../cocos2dx
|
||||
INCLUDES = -I../ \
|
||||
-I../Classes \
|
||||
-I$(COCOS2DX_PATH) \
|
||||
-I$(COCOS2DX_PATH)/platform/third_party/linux \
|
||||
-I$(COCOS2DX_PATH)/platform/third_party/linux/libfreetype2 \
|
||||
-I$(COCOS2DX_PATH)/cocoa \
|
||||
-I$(COCOS2DX_PATH)/include \
|
||||
-I$(COCOS2DX_PATH)/platform \
|
||||
-I$(COCOS2DX_PATH)/platform/linux \
|
||||
-I$(COCOS2DX_PATH)/platform/third_party/linux/glew-1.7.0/glew-1.7.0/include/ \
|
||||
-I$(COCOS2DX_PATH)/kazmath/include \
|
||||
-I$(COCOS2DX_PATH)/platform/third_party/linux/libxml2 \
|
||||
-I$(COCOS2DX_PATH)/platform/third_party/linux/libjpeg \
|
||||
-I../../../CocosDenshion/include \
|
||||
-I../../../scripting/lua/lua \
|
||||
-I../../../scripting/lua/tolua \
|
||||
-I../../../scripting/lua/cocos2dx_support
|
||||
|
||||
DEFINES = -DLINUX
|
||||
|
||||
OBJECTS = ./main.o \
|
||||
../Classes/AppDelegate.o \
|
||||
../../../scripting/lua/cocos2dx_support/CCLuaEngine.o \
|
||||
../../../scripting/lua/cocos2dx_support/Cocos2dxLuaLoader.o \
|
||||
../../../scripting/lua/cocos2dx_support/LuaCocos2d.o \
|
||||
../../../scripting/lua/cocos2dx_support/tolua_fix.o
|
||||
|
||||
LBITS := $(shell getconf LONG_BIT)
|
||||
ifeq ($(LBITS),64)
|
||||
STATICLIBS_DIR = ../../../cocos2dx/platform/third_party/linux/libraries/lib64
|
||||
else
|
||||
STATICLIBS_DIR = ../../../cocos2dx/platform/third_party/linux/libraries
|
||||
endif
|
||||
|
||||
STATICLIBS = $(STATICLIBS_DIR)/libfreetype.a \
|
||||
$(STATICLIBS_DIR)/libxml2.a \
|
||||
$(STATICLIBS_DIR)/libpng.a \
|
||||
$(STATICLIBS_DIR)/libjpeg.a \
|
||||
$(STATICLIBS_DIR)/libtiff.a \
|
||||
# $(STATICLIBS_DIR)/libGLEW.a \
|
||||
|
||||
SHAREDLIBS += -lglfw -lcurl -llua
|
||||
SHAREDLIBS += -Wl,-rpath,../../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib
|
||||
SHAREDLIBS += -L../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib -lGLEW
|
||||
SHAREDLIBS += -Wl,-rpath,../../../../../lib/linux/Debug
|
||||
|
||||
ifeq ($(LBITS),64)
|
||||
SHAREDLIBS += -L../../../CocosDenshion/third_party/fmod/lib64/api/lib -lfmodex64 -Wl,-rpath,../../../../../CocosDenshion/third_party/fmod/lib64/api/lib
|
||||
else
|
||||
SHAREDLIBS += -L../../../CocosDenshion/third_party/fmod/api/lib -lfmodex -Wl,-rpath,../../../../../CocosDenshion/third_party/fmod/api/lib
|
||||
endif
|
||||
|
||||
#$(shell ../../build-linux.sh $<)
|
||||
|
||||
BIN_DIR_ROOT=bin
|
||||
BIN_DIR = $(BIN_DIR_ROOT)
|
||||
|
||||
debug: BIN_DIR = $(BIN_DIR_ROOT)/debug
|
||||
debug: CCFLAGS += -g3 -O0
|
||||
debug: CXXFLAGS += -g3 -O0
|
||||
debug: SHAREDLIBS += -L../../../lib/linux/Debug -lcocos2d -lrt -lz -lcocosdenshion
|
||||
debug: SHAREDLIBS += -Wl,-rpath,../../../../../lib/linux/Debug/
|
||||
debug: DEFINES += -DDEBUG
|
||||
debug: $(TARGET)
|
||||
|
||||
release: BIN_DIR = $(BIN_DIR_ROOT)/release
|
||||
release: CCFLAGS += -O3
|
||||
release: CXXFLAGS += -O3
|
||||
release: SHAREDLIBS += -L../../../lib/linux/Release -lcocos2d -lrt -lz -lcocosdenshion
|
||||
release: SHAREDLIBS += -Wl,-rpath,../../../../../lib/linux/Release/
|
||||
release: DEFINES += -DNDEBUG
|
||||
release: $(TARGET)
|
||||
|
||||
####### Build rules
|
||||
$(TARGET): $(OBJECTS)
|
||||
mkdir -p $(BIN_DIR)
|
||||
$(CXX) $(CXXFLAGS) $(INCLUDES) $(DEFINES) $(OBJECTS) -o $(BIN_DIR)/$(TARGET) $(SHAREDLIBS) $(STATICLIBS)
|
||||
|
||||
####### Compile
|
||||
%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) $(INCLUDES) $(DEFINES) $(VISIBILITY) -c $< -o $@
|
||||
|
||||
%.o: %.c
|
||||
$(CC) $(CCFLAGS) $(INCLUDES) $(DEFINES) $(VISIBILITY) -c $< -o $@
|
||||
|
||||
clean:
|
||||
rm -f $(OBJECTS) $(TARGET) core
|
|
@ -0,0 +1,34 @@
|
|||
#include "main.h"
|
||||
#include "../Classes/AppDelegate.h"
|
||||
#include "cocos2d.h"
|
||||
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <unistd.h>
|
||||
#include <string>
|
||||
|
||||
USING_NS_CC;
|
||||
|
||||
// 500 is enough?
|
||||
#define MAXPATHLEN 500
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
// get application path
|
||||
int length;
|
||||
char fullpath[MAXPATHLEN];
|
||||
length = readlink("/proc/self/exe", fullpath, sizeof(fullpath));
|
||||
fullpath[length] = '\0';
|
||||
|
||||
std::string resourcePath = fullpath;
|
||||
resourcePath = resourcePath.substr(0, resourcePath.find_last_of("/"));
|
||||
resourcePath += "/../../../Resources/";
|
||||
|
||||
// create the application instance
|
||||
AppDelegate app;
|
||||
CCApplication::sharedApplication()->setResourceRootPath(resourcePath.c_str());
|
||||
CCEGLView* eglView = CCEGLView::sharedOpenGLView();
|
||||
eglView->setFrameSize(960, 640);
|
||||
return CCApplication::sharedApplication()->run();
|
||||
}
|
|
@ -0,0 +1,7 @@
|
|||
#ifndef __MAIN_H__
|
||||
#define __MAIN_H__
|
||||
|
||||
// C RunTime Header Files
|
||||
#include "CCStdC.h"
|
||||
|
||||
#endif // __MAIN_H__
|
|
@ -0,0 +1,224 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<?fileVersion 4.0.0?>
|
||||
|
||||
<cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
|
||||
<storageModule moduleId="org.eclipse.cdt.core.settings">
|
||||
<cconfiguration id="cdt.managedbuild.config.gnu.exe.debug.684675641">
|
||||
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="cdt.managedbuild.config.gnu.exe.debug.684675641" moduleId="org.eclipse.cdt.core.settings" name="Debug">
|
||||
<externalSettings/>
|
||||
<extensions>
|
||||
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.debug,org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="" id="cdt.managedbuild.config.gnu.exe.debug.684675641" name="Debug" parent="cdt.managedbuild.config.gnu.exe.debug" prebuildStep="mkdir -p bin && cp -R ../../../../samples/TestCpp/Resources ../../../../samples/TestLua/">
|
||||
<folderInfo id="cdt.managedbuild.config.gnu.exe.debug.684675641." name="/" resourcePath="">
|
||||
<toolChain id="cdt.managedbuild.toolchain.gnu.exe.debug.1168665521" name="Linux GCC" superClass="cdt.managedbuild.toolchain.gnu.exe.debug">
|
||||
<targetPlatform id="cdt.managedbuild.target.gnu.platform.exe.debug.2039781202" name="Debug Platform" superClass="cdt.managedbuild.target.gnu.platform.exe.debug"/>
|
||||
<builder buildPath="${workspace_loc:/TestLua/Debug}" id="cdt.managedbuild.target.gnu.builder.exe.debug.102570384" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="cdt.managedbuild.target.gnu.builder.exe.debug"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.archiver.base.751250359" name="GCC Archiver" superClass="cdt.managedbuild.tool.gnu.archiver.base"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.cpp.compiler.exe.debug.889157849" name="GCC C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.exe.debug">
|
||||
<option id="gnu.cpp.compiler.exe.debug.option.optimization.level.267147213" name="Optimization Level" superClass="gnu.cpp.compiler.exe.debug.option.optimization.level" value="gnu.cpp.compiler.optimization.level.none" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.exe.debug.option.debugging.level.1198800325" name="Debug Level" superClass="gnu.cpp.compiler.exe.debug.option.debugging.level" value="gnu.cpp.compiler.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.option.preprocessor.def.1970386575" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="LINUX"/>
|
||||
</option>
|
||||
<option id="gnu.cpp.compiler.option.include.paths.1761931224" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../Classes"/>
|
||||
<listOptionValue builtIn="false" value="../../../"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/kazmath/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/cocos2dx_support"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/lua"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/tolua"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.compiler.input.103685015" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.compiler.exe.debug.1377495991" name="GCC C Compiler" superClass="cdt.managedbuild.tool.gnu.c.compiler.exe.debug">
|
||||
<option defaultValue="gnu.c.optimization.level.none" id="gnu.c.compiler.exe.debug.option.optimization.level.868044462" name="Optimization Level" superClass="gnu.c.compiler.exe.debug.option.optimization.level" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.exe.debug.option.debugging.level.234553092" name="Debug Level" superClass="gnu.c.compiler.exe.debug.option.debugging.level" value="gnu.c.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.option.include.paths.2130120472" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../Classes"/>
|
||||
<listOptionValue builtIn="false" value="../../../"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/kazmath/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/cocos2dx_support"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/lua"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/tolua"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.1540019914" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.linker.exe.debug.1450392108" name="GCC C Linker" superClass="cdt.managedbuild.tool.gnu.c.linker.exe.debug"/>
|
||||
<tool commandLinePattern="${COMMAND} ${FLAGS} ${OUTPUT_FLAG} bin/${OUTPUT_PREFIX}${OUTPUT} ${INPUTS} -Wl,-rpath,${ProjDirPath}/../../../cocos2dx/proj.linux/${ConfigName} -Wl,-rpath,${ProjDirPath}/../../../CocosDenshion/proj.linux/${ConfigName} -Wl,-rpath,${ProjDirPath}/../../../CocosDenshion/third_party/fmod/api/lib -Wl,-rpath,../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib -Wl,-rpath,${ProjDirPath}/../../../scripting/lua/proj.linux/${ConfigName}" id="cdt.managedbuild.tool.gnu.cpp.linker.exe.debug.127674845" name="GCC C++ Linker" superClass="cdt.managedbuild.tool.gnu.cpp.linker.exe.debug">
|
||||
<option id="gnu.cpp.link.option.libs.1672912039" name="Libraries (-l)" superClass="gnu.cpp.link.option.libs" valueType="libs">
|
||||
<listOptionValue builtIn="false" value="cocos2d"/>
|
||||
<listOptionValue builtIn="false" value="cocosdenshion"/>
|
||||
<listOptionValue builtIn="false" value="GLEW"/>
|
||||
<listOptionValue builtIn="false" value="rt"/>
|
||||
<listOptionValue builtIn="false" value="z"/>
|
||||
<listOptionValue builtIn="false" value="lua"/>
|
||||
<listOptionValue builtIn="false" value="fmodex"/>
|
||||
</option>
|
||||
<option id="gnu.cpp.link.option.paths.1982163393" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths" valueType="libPaths">
|
||||
<listOptionValue builtIn="false" value=""../../../../cocos2dx/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value=""../../../../CocosDenshion/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value=""../../../../scripting/lua/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/third_party/fmod/api/lib"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.linker.input.154309798" superClass="cdt.managedbuild.tool.gnu.cpp.linker.input">
|
||||
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
|
||||
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
|
||||
</inputType>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.assembler.exe.debug.172675447" name="GCC Assembler" superClass="cdt.managedbuild.tool.gnu.assembler.exe.debug">
|
||||
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.2124631163" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||
</tool>
|
||||
</toolChain>
|
||||
</folderInfo>
|
||||
<sourceEntries>
|
||||
<entry excluding="cocos2dx_support|Classes" flags="VALUE_WORKSPACE_PATH|RESOLVED" kind="sourcePath" name=""/>
|
||||
<entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="Classes"/>
|
||||
<entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="cocos2dx_support"/>
|
||||
</sourceEntries>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||
</cconfiguration>
|
||||
<cconfiguration id="cdt.managedbuild.config.gnu.exe.release.890968076">
|
||||
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="cdt.managedbuild.config.gnu.exe.release.890968076" moduleId="org.eclipse.cdt.core.settings" name="Release">
|
||||
<externalSettings/>
|
||||
<extensions>
|
||||
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.exe" buildProperties="org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.release,org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.exe" cleanCommand="rm -rf" description="" id="cdt.managedbuild.config.gnu.exe.release.890968076" name="Release" parent="cdt.managedbuild.config.gnu.exe.release" prebuildStep="mkdir -p bin && cp -R ../../../../samples/TestCpp/Resources ../../../../samples/TestLua/">
|
||||
<folderInfo id="cdt.managedbuild.config.gnu.exe.release.890968076." name="/" resourcePath="">
|
||||
<toolChain id="cdt.managedbuild.toolchain.gnu.exe.release.720811514" name="Linux GCC" superClass="cdt.managedbuild.toolchain.gnu.exe.release">
|
||||
<targetPlatform id="cdt.managedbuild.target.gnu.platform.exe.release.962949232" name="Debug Platform" superClass="cdt.managedbuild.target.gnu.platform.exe.release"/>
|
||||
<builder buildPath="${workspace_loc:/TestLua/Release}" id="cdt.managedbuild.target.gnu.builder.exe.release.1121553297" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="cdt.managedbuild.target.gnu.builder.exe.release"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.archiver.base.25255351" name="GCC Archiver" superClass="cdt.managedbuild.tool.gnu.archiver.base"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.cpp.compiler.exe.release.317133341" name="GCC C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.exe.release">
|
||||
<option id="gnu.cpp.compiler.exe.release.option.optimization.level.1020508288" name="Optimization Level" superClass="gnu.cpp.compiler.exe.release.option.optimization.level" value="gnu.cpp.compiler.optimization.level.most" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.exe.release.option.debugging.level.200368394" name="Debug Level" superClass="gnu.cpp.compiler.exe.release.option.debugging.level" value="gnu.cpp.compiler.debugging.level.none" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.option.include.paths.717016654" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../Classes"/>
|
||||
<listOptionValue builtIn="false" value="../../../"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/kazmath/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/cocos2dx_support"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/lua"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/tolua"/>
|
||||
</option>
|
||||
<option id="gnu.cpp.compiler.option.preprocessor.def.48956079" name="Defined symbols (-D)" superClass="gnu.cpp.compiler.option.preprocessor.def" valueType="definedSymbols">
|
||||
<listOptionValue builtIn="false" value="LINUX"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.compiler.input.1669186843" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.compiler.exe.release.279374166" name="GCC C Compiler" superClass="cdt.managedbuild.tool.gnu.c.compiler.exe.release">
|
||||
<option defaultValue="gnu.c.optimization.level.most" id="gnu.c.compiler.exe.release.option.optimization.level.513797541" name="Optimization Level" superClass="gnu.c.compiler.exe.release.option.optimization.level" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.exe.release.option.debugging.level.1785407921" name="Debug Level" superClass="gnu.c.compiler.exe.release.option.debugging.level" value="gnu.c.debugging.level.none" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.option.include.paths.606181663" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../Classes"/>
|
||||
<listOptionValue builtIn="false" value="../../../"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/kazmath/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/include"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/cocos2dx_support"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/lua"/>
|
||||
<listOptionValue builtIn="false" value="../../../../scripting/lua/tolua"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.1951510828" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.linker.exe.release.1196338383" name="GCC C Linker" superClass="cdt.managedbuild.tool.gnu.c.linker.exe.release"/>
|
||||
<tool commandLinePattern="${COMMAND} ${FLAGS} ${OUTPUT_FLAG} bin/${OUTPUT_PREFIX}${OUTPUT} ${INPUTS} -Wl,-rpath,${ProjDirPath}/../../../cocos2dx/proj.linux/${ConfigName} -Wl,-rpath,${ProjDirPath}/../../../CocosDenshion/proj.linux/${ConfigName} -Wl,-rpath,${ProjDirPath}/../../../CocosDenshion/third_party/fmod/api/lib -Wl,-rpath,../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib -Wl,-rpath,${ProjDirPath}/../../../scripting/lua/proj.linux/${ConfigName}" id="cdt.managedbuild.tool.gnu.cpp.linker.exe.release.968523880" name="GCC C++ Linker" superClass="cdt.managedbuild.tool.gnu.cpp.linker.exe.release">
|
||||
<option id="gnu.cpp.link.option.libs.841434875" name="Libraries (-l)" superClass="gnu.cpp.link.option.libs" valueType="libs">
|
||||
<listOptionValue builtIn="false" value="cocos2d"/>
|
||||
<listOptionValue builtIn="false" value="cocosdenshion"/>
|
||||
<listOptionValue builtIn="false" value="GLEW"/>
|
||||
<listOptionValue builtIn="false" value="rt"/>
|
||||
<listOptionValue builtIn="false" value="z"/>
|
||||
<listOptionValue builtIn="false" value="lua"/>
|
||||
<listOptionValue builtIn="false" value="fmodex"/>
|
||||
</option>
|
||||
<option id="gnu.cpp.link.option.paths.815635762" name="Library search path (-L)" superClass="gnu.cpp.link.option.paths" valueType="libPaths">
|
||||
<listOptionValue builtIn="false" value=""../../../../cocos2dx/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value=""../../../../CocosDenshion/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value=""../../../../scripting/lua/proj.linux/${ConfigName}""/>
|
||||
<listOptionValue builtIn="false" value="../../../../CocosDenshion/third_party/fmod/api/lib"/>
|
||||
<listOptionValue builtIn="false" value="../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.linker.input.760339141" superClass="cdt.managedbuild.tool.gnu.cpp.linker.input">
|
||||
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
|
||||
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
|
||||
</inputType>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.assembler.exe.release.1526892084" name="GCC Assembler" superClass="cdt.managedbuild.tool.gnu.assembler.exe.release">
|
||||
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.569443221" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||
</tool>
|
||||
</toolChain>
|
||||
</folderInfo>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||
</cconfiguration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<project id="TestLua.cdt.managedbuild.target.gnu.exe.1639529943" name="Executable" projectType="cdt.managedbuild.target.gnu.exe"/>
|
||||
</storageModule>
|
||||
<storageModule moduleId="scannerConfiguration">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.debug.684675641;cdt.managedbuild.config.gnu.exe.debug.684675641.;cdt.managedbuild.tool.gnu.cpp.compiler.exe.debug.889157849;cdt.managedbuild.tool.gnu.cpp.compiler.input.103685015">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.release.890968076;cdt.managedbuild.config.gnu.exe.release.890968076.;cdt.managedbuild.tool.gnu.cpp.compiler.exe.release.317133341;cdt.managedbuild.tool.gnu.cpp.compiler.input.1669186843">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.release.890968076;cdt.managedbuild.config.gnu.exe.release.890968076.;cdt.managedbuild.tool.gnu.c.compiler.exe.release.279374166;cdt.managedbuild.tool.gnu.c.compiler.input.1951510828">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.exe.debug.684675641;cdt.managedbuild.config.gnu.exe.debug.684675641.;cdt.managedbuild.tool.gnu.c.compiler.exe.debug.1377495991;cdt.managedbuild.tool.gnu.c.compiler.input.1540019914">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
|
||||
<storageModule moduleId="refreshScope" versionNumber="2">
|
||||
<configuration configurationName="Release">
|
||||
<resource resourceType="PROJECT" workspacePath="/TestLua"/>
|
||||
</configuration>
|
||||
<configuration configurationName="Debug">
|
||||
<resource resourceType="PROJECT" workspacePath="/TestLua"/>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.internal.ui.text.commentOwnerProjectMappings"/>
|
||||
</cproject>
|
|
@ -0,0 +1,44 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>TestLua</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
<project>libBox2D</project>
|
||||
<project>libChipmunk</project>
|
||||
<project>libcocos2d</project>
|
||||
<project>libCocosDenshion</project>
|
||||
<project>liblua</project>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
|
||||
<triggers>clean,full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
|
||||
<triggers>full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.cdt.core.cnature</nature>
|
||||
<nature>org.eclipse.cdt.core.ccnature</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
|
||||
</natures>
|
||||
<linkedResources>
|
||||
<link>
|
||||
<name>Classes</name>
|
||||
<type>2</type>
|
||||
<locationURI>PARENT-1-PROJECT_LOC/Classes</locationURI>
|
||||
</link>
|
||||
<link>
|
||||
<name>cocos2dx_support</name>
|
||||
<type>2</type>
|
||||
<locationURI>PARENT-3-PROJECT_LOC/scripting/lua/cocos2dx_support</locationURI>
|
||||
</link>
|
||||
</linkedResources>
|
||||
</projectDescription>
|
|
@ -0,0 +1,100 @@
|
|||
CC = gcc
|
||||
CXX = g++
|
||||
TARGET = TestLua
|
||||
CCFLAGS = -Wall
|
||||
CXXFLAGS = -Wall
|
||||
VISIBILITY =
|
||||
|
||||
COCOS2DX_PATH = ../../../cocos2dx
|
||||
INCLUDES = -I../ \
|
||||
-I../Classes \
|
||||
-I$(COCOS2DX_PATH) \
|
||||
-I$(COCOS2DX_PATH)/platform/third_party/linux \
|
||||
-I$(COCOS2DX_PATH)/platform/third_party/linux/libfreetype2 \
|
||||
-I$(COCOS2DX_PATH)/cocoa \
|
||||
-I$(COCOS2DX_PATH)/include \
|
||||
-I$(COCOS2DX_PATH)/platform \
|
||||
-I$(COCOS2DX_PATH)/platform/linux \
|
||||
-I$(COCOS2DX_PATH)/platform/third_party/linux/glew-1.7.0/glew-1.7.0/include/ \
|
||||
-I$(COCOS2DX_PATH)/kazmath/include \
|
||||
-I$(COCOS2DX_PATH)/platform/third_party/linux/libxml2 \
|
||||
-I$(COCOS2DX_PATH)/platform/third_party/linux/libjpeg \
|
||||
-I../../../CocosDenshion/include \
|
||||
-I../../../scripting/lua/lua \
|
||||
-I../../../scripting/lua/tolua \
|
||||
-I../../../scripting/lua/cocos2dx_support
|
||||
|
||||
|
||||
DEFINES = -DLINUX
|
||||
|
||||
OBJECTS = ./main.o \
|
||||
../Classes/AppDelegate.o \
|
||||
../../../scripting/lua/cocos2dx_support/CCLuaEngine.o \
|
||||
../../../scripting/lua/cocos2dx_support/Cocos2dxLuaLoader.o \
|
||||
../../../scripting/lua/cocos2dx_support/LuaCocos2d.o \
|
||||
../../../scripting/lua/cocos2dx_support/tolua_fix.o \
|
||||
|
||||
LBITS := $(shell getconf LONG_BIT)
|
||||
ifeq ($(LBITS),64)
|
||||
STATICLIBS_DIR = ../../../cocos2dx/platform/third_party/linux/libraries/lib64
|
||||
else
|
||||
STATICLIBS_DIR = ../../../cocos2dx/platform/third_party/linux/libraries
|
||||
endif
|
||||
|
||||
STATICLIBS = $(STATICLIBS_DIR)/libfreetype.a \
|
||||
$(STATICLIBS_DIR)/libcurl.a \
|
||||
$(STATICLIBS_DIR)/libxml2.a \
|
||||
$(STATICLIBS_DIR)/libpng.a \
|
||||
$(STATICLIBS_DIR)/libjpeg.a \
|
||||
$(STATICLIBS_DIR)/libtiff.a \
|
||||
# $(STATICLIBS_DIR)/libGLEW.a \
|
||||
../../../lib/linux/Debug/libbox2d.a \
|
||||
../../../lib/linux/Debug/libchipmunk.a
|
||||
|
||||
SHAREDLIBS += -lglfw -lcurl -llua
|
||||
SHAREDLIBS += -Wl,-rpath,../../../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib
|
||||
SHAREDLIBS += -L../../../cocos2dx/platform/third_party/linux/glew-1.7.0/glew-1.7.0/lib -lGLEW
|
||||
SHAREDLIBS += -Wl,-rpath,../../../../../lib/linux/Debug
|
||||
|
||||
ifeq ($(LBITS),64)
|
||||
SHAREDLIBS += -L../../../CocosDenshion/third_party/fmod/lib64/api/lib -lfmodex64 -Wl,-rpath,../../../../../CocosDenshion/third_party/fmod/lib64/api/lib
|
||||
else
|
||||
SHAREDLIBS += -L../../../CocosDenshion/third_party/fmod/api/lib -lfmodex -Wl,-rpath,../../../../../CocosDenshion/third_party/fmod/api/lib
|
||||
endif
|
||||
|
||||
#$(shell ../../build-linux.sh $<)
|
||||
|
||||
BIN_DIR_ROOT=bin
|
||||
BIN_DIR = $(BIN_DIR_ROOT)
|
||||
|
||||
debug: BIN_DIR = $(BIN_DIR_ROOT)/debug
|
||||
debug: CCFLAGS += -g3 -O0
|
||||
debug: CXXFLAGS += -g3 -O0
|
||||
debug: SHAREDLIBS += -L../../../lib/linux/Debug -lcocos2d -lrt -lz -lcocosdenshion
|
||||
debug: SHAREDLIBS += -Wl,-rpath,../../../../../lib/linux/Debug/
|
||||
debug: DEFINES += -DDEBUG
|
||||
debug: $(TARGET)
|
||||
|
||||
release: BIN_DIR = $(BIN_DIR_ROOT)/release
|
||||
release: CCFLAGS += -O3
|
||||
release: CXXFLAGS += -O3
|
||||
release: SHAREDLIBS += -L../../../lib/linux/Release -lcocos2d -lrt -lz -lcocosdenshion
|
||||
release: SHAREDLIBS += -Wl,-rpath,../../../../../lib/linux/Release/
|
||||
release: DEFINES += -DNDEBUG
|
||||
release: $(TARGET)
|
||||
|
||||
####### Build rules
|
||||
$(TARGET): $(OBJECTS)
|
||||
mkdir -p $(BIN_DIR)
|
||||
cp -R ../../../samples/TestCpp/Resources ../../../samples/TestLua/
|
||||
$(CXX) $(CXXFLAGS) $(INCLUDES) $(DEFINES) $(OBJECTS) -o $(BIN_DIR)/$(TARGET) $(SHAREDLIBS) $(STATICLIBS)
|
||||
|
||||
####### Compile
|
||||
%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) $(INCLUDES) $(DEFINES) $(VISIBILITY) -c $< -o $@
|
||||
|
||||
%.o: %.c
|
||||
$(CC) $(CCFLAGS) $(INCLUDES) $(DEFINES) $(VISIBILITY) -c $< -o $@
|
||||
|
||||
clean:
|
||||
rm -f $(OBJECTS) $(TARGET) core
|
|
@ -0,0 +1,35 @@
|
|||
#include "main.h"
|
||||
|
||||
#include "../Classes/AppDelegate.h"
|
||||
#include "cocos2d.h"
|
||||
#include "CCEGLView.h"
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <unistd.h>
|
||||
#include <string>
|
||||
|
||||
USING_NS_CC;
|
||||
|
||||
// 500 is enough?
|
||||
#define MAXPATHLEN 500
|
||||
|
||||
int main(int argc, char **argv)
|
||||
{
|
||||
// get application path
|
||||
int length;
|
||||
char fullpath[MAXPATHLEN];
|
||||
length = readlink("/proc/self/exe", fullpath, sizeof(fullpath));
|
||||
fullpath[length] = '\0';
|
||||
|
||||
std::string resourcePath = fullpath;
|
||||
resourcePath = resourcePath.substr(0, resourcePath.find_last_of("/"));
|
||||
resourcePath += "/../../../Resources/";
|
||||
|
||||
// create the application instance
|
||||
AppDelegate app;
|
||||
CCApplication::sharedApplication()->setResourceRootPath(resourcePath.c_str());
|
||||
CCEGLView* eglView = CCEGLView::sharedOpenGLView();
|
||||
eglView->setFrameSize(480, 320);
|
||||
return CCApplication::sharedApplication()->run();
|
||||
}
|
|
@ -0,0 +1,13 @@
|
|||
#ifndef __MAIN_H__
|
||||
#define __MAIN_H__
|
||||
|
||||
#define WIN32_LEAN_AND_MEAN // Exclude rarely-used stuff from Windows headers
|
||||
|
||||
// Windows Header Files:
|
||||
//#include <windows.h>
|
||||
//#include <tchar.h>
|
||||
|
||||
// C RunTime Header Files
|
||||
#include "CCStdC.h"
|
||||
|
||||
#endif // __MAIN_H__
|
|
@ -0,0 +1,163 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<?fileVersion 4.0.0?><cproject storage_type_id="org.eclipse.cdt.core.XmlProjectDescriptionStorage">
|
||||
<storageModule moduleId="org.eclipse.cdt.core.settings">
|
||||
<cconfiguration id="cdt.managedbuild.config.gnu.so.debug.1532040290">
|
||||
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="cdt.managedbuild.config.gnu.so.debug.1532040290" moduleId="org.eclipse.cdt.core.settings" name="Debug">
|
||||
<externalSettings>
|
||||
<externalSetting>
|
||||
<entry flags="VALUE_WORKSPACE_PATH" kind="includePath" name="/liblua"/>
|
||||
<entry flags="VALUE_WORKSPACE_PATH" kind="libraryPath" name="/liblua/Debug"/>
|
||||
<entry flags="RESOLVED" kind="libraryFile" name="lua" srcPrefixMapping="" srcRootPath=""/>
|
||||
</externalSetting>
|
||||
</externalSettings>
|
||||
<extensions>
|
||||
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactExtension="so" artifactName="lua" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.sharedLib" buildProperties="org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.debug,org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.sharedLib" cleanCommand="rm -rf" description="" id="cdt.managedbuild.config.gnu.so.debug.1532040290" name="Debug" parent="cdt.managedbuild.config.gnu.so.debug">
|
||||
<folderInfo id="cdt.managedbuild.config.gnu.so.debug.1532040290." name="/" resourcePath="">
|
||||
<toolChain id="cdt.managedbuild.toolchain.gnu.so.debug.1519046072" name="Linux GCC" superClass="cdt.managedbuild.toolchain.gnu.so.debug">
|
||||
<targetPlatform id="cdt.managedbuild.target.gnu.platform.so.debug.1984647451" name="Debug Platform" superClass="cdt.managedbuild.target.gnu.platform.so.debug"/>
|
||||
<builder buildPath="${workspace_loc:/liblua/Debug}" id="cdt.managedbuild.target.gnu.builder.so.debug.1340041275" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="cdt.managedbuild.target.gnu.builder.so.debug"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.archiver.base.741414828" name="GCC Archiver" superClass="cdt.managedbuild.tool.gnu.archiver.base"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.cpp.compiler.so.debug.1908142641" name="GCC C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.so.debug">
|
||||
<option id="gnu.cpp.compiler.so.debug.option.optimization.level.1343441140" name="Optimization Level" superClass="gnu.cpp.compiler.so.debug.option.optimization.level" value="gnu.cpp.compiler.optimization.level.none" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.so.debug.option.debugging.level.786650861" name="Debug Level" superClass="gnu.cpp.compiler.so.debug.option.debugging.level" value="gnu.cpp.compiler.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.option.include.paths.2120072997" name="Include paths (-I)" superClass="gnu.cpp.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../lua"/>
|
||||
<listOptionValue builtIn="false" value="../../tolua"/>
|
||||
</option>
|
||||
<option id="gnu.cpp.compiler.option.other.pic.1350367798" name="Position Independent Code (-fPIC)" superClass="gnu.cpp.compiler.option.other.pic" value="false" valueType="boolean"/>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.compiler.input.2035513663" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.compiler.so.debug.2114277329" name="GCC C Compiler" superClass="cdt.managedbuild.tool.gnu.c.compiler.so.debug">
|
||||
<option defaultValue="gnu.c.optimization.level.none" id="gnu.c.compiler.so.debug.option.optimization.level.1730464463" name="Optimization Level" superClass="gnu.c.compiler.so.debug.option.optimization.level" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.so.debug.option.debugging.level.1279425095" name="Debug Level" superClass="gnu.c.compiler.so.debug.option.debugging.level" value="gnu.c.debugging.level.max" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.option.include.paths.956555346" name="Include paths (-I)" superClass="gnu.c.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../lua"/>
|
||||
<listOptionValue builtIn="false" value="../../tolua"/>
|
||||
</option>
|
||||
<option id="gnu.c.compiler.option.misc.pic.859593969" name="Position Independent Code (-fPIC)" superClass="gnu.c.compiler.option.misc.pic" value="true" valueType="boolean"/>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.1259937486" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.linker.so.debug.709544732" name="GCC C Linker" superClass="cdt.managedbuild.tool.gnu.c.linker.so.debug">
|
||||
<option defaultValue="true" id="gnu.c.link.so.debug.option.shared.1270521703" name="Shared (-shared)" superClass="gnu.c.link.so.debug.option.shared" valueType="boolean"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.cpp.linker.so.debug.1186320686" name="GCC C++ Linker" superClass="cdt.managedbuild.tool.gnu.cpp.linker.so.debug">
|
||||
<option defaultValue="true" id="gnu.cpp.link.so.debug.option.shared.918465649" name="Shared (-shared)" superClass="gnu.cpp.link.so.debug.option.shared" valueType="boolean"/>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.linker.input.418512401" superClass="cdt.managedbuild.tool.gnu.cpp.linker.input">
|
||||
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
|
||||
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
|
||||
</inputType>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.assembler.so.debug.558088018" name="GCC Assembler" superClass="cdt.managedbuild.tool.gnu.assembler.so.debug">
|
||||
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.1707443272" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||
</tool>
|
||||
</toolChain>
|
||||
</folderInfo>
|
||||
<sourceEntries>
|
||||
<entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="lua"/>
|
||||
<entry flags="VALUE_WORKSPACE_PATH" kind="sourcePath" name="tolua"/>
|
||||
</sourceEntries>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||
</cconfiguration>
|
||||
<cconfiguration id="cdt.managedbuild.config.gnu.so.release.1209971451">
|
||||
<storageModule buildSystemId="org.eclipse.cdt.managedbuilder.core.configurationDataProvider" id="cdt.managedbuild.config.gnu.so.release.1209971451" moduleId="org.eclipse.cdt.core.settings" name="Release">
|
||||
<externalSettings>
|
||||
<externalSetting>
|
||||
<entry flags="VALUE_WORKSPACE_PATH" kind="includePath" name="/liblua"/>
|
||||
<entry flags="VALUE_WORKSPACE_PATH" kind="libraryPath" name="/liblua/Release"/>
|
||||
<entry flags="RESOLVED" kind="libraryFile" name="liblua" srcPrefixMapping="" srcRootPath=""/>
|
||||
</externalSetting>
|
||||
</externalSettings>
|
||||
<extensions>
|
||||
<extension id="org.eclipse.cdt.core.ELF" point="org.eclipse.cdt.core.BinaryParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GmakeErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.CWDLocator" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GCCErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GASErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
<extension id="org.eclipse.cdt.core.GLDErrorParser" point="org.eclipse.cdt.core.ErrorParser"/>
|
||||
</extensions>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<configuration artifactExtension="so" artifactName="${ProjName}" buildArtefactType="org.eclipse.cdt.build.core.buildArtefactType.sharedLib" buildProperties="org.eclipse.cdt.build.core.buildType=org.eclipse.cdt.build.core.buildType.release,org.eclipse.cdt.build.core.buildArtefactType=org.eclipse.cdt.build.core.buildArtefactType.sharedLib" cleanCommand="rm -rf" description="" id="cdt.managedbuild.config.gnu.so.release.1209971451" name="Release" parent="cdt.managedbuild.config.gnu.so.release">
|
||||
<folderInfo id="cdt.managedbuild.config.gnu.so.release.1209971451." name="/" resourcePath="">
|
||||
<toolChain id="cdt.managedbuild.toolchain.gnu.so.release.638782967" name="Linux GCC" superClass="cdt.managedbuild.toolchain.gnu.so.release">
|
||||
<targetPlatform id="cdt.managedbuild.target.gnu.platform.so.release.103979431" name="Debug Platform" superClass="cdt.managedbuild.target.gnu.platform.so.release"/>
|
||||
<builder buildPath="${workspace_loc:/liblua/Release}" id="cdt.managedbuild.target.gnu.builder.so.release.1582399077" keepEnvironmentInBuildfile="false" managedBuildOn="true" name="Gnu Make Builder" superClass="cdt.managedbuild.target.gnu.builder.so.release"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.archiver.base.320299117" name="GCC Archiver" superClass="cdt.managedbuild.tool.gnu.archiver.base"/>
|
||||
<tool id="cdt.managedbuild.tool.gnu.cpp.compiler.so.release.1495522959" name="GCC C++ Compiler" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.so.release">
|
||||
<option id="gnu.cpp.compiler.so.release.option.optimization.level.979797207" name="Optimization Level" superClass="gnu.cpp.compiler.so.release.option.optimization.level" value="gnu.cpp.compiler.optimization.level.most" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.so.release.option.debugging.level.1805098853" name="Debug Level" superClass="gnu.cpp.compiler.so.release.option.debugging.level" value="gnu.cpp.compiler.debugging.level.none" valueType="enumerated"/>
|
||||
<option id="gnu.cpp.compiler.option.include.paths.2100249291" superClass="gnu.cpp.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../lua"/>
|
||||
<listOptionValue builtIn="false" value="../../tolua"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.compiler.input.1022202619" superClass="cdt.managedbuild.tool.gnu.cpp.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.compiler.so.release.472386122" name="GCC C Compiler" superClass="cdt.managedbuild.tool.gnu.c.compiler.so.release">
|
||||
<option defaultValue="gnu.c.optimization.level.most" id="gnu.c.compiler.so.release.option.optimization.level.1883494761" name="Optimization Level" superClass="gnu.c.compiler.so.release.option.optimization.level" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.so.release.option.debugging.level.1071645760" name="Debug Level" superClass="gnu.c.compiler.so.release.option.debugging.level" value="gnu.c.debugging.level.none" valueType="enumerated"/>
|
||||
<option id="gnu.c.compiler.option.include.paths.1050038430" superClass="gnu.c.compiler.option.include.paths" valueType="includePath">
|
||||
<listOptionValue builtIn="false" value="../../lua"/>
|
||||
<listOptionValue builtIn="false" value="../../tolua"/>
|
||||
</option>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.c.compiler.input.1197021556" superClass="cdt.managedbuild.tool.gnu.c.compiler.input"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.c.linker.so.release.1511578599" name="GCC C Linker" superClass="cdt.managedbuild.tool.gnu.c.linker.so.release">
|
||||
<option defaultValue="true" id="gnu.c.link.so.release.option.shared.1652437254" name="Shared (-shared)" superClass="gnu.c.link.so.release.option.shared" valueType="boolean"/>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.cpp.linker.so.release.1230370002" name="GCC C++ Linker" superClass="cdt.managedbuild.tool.gnu.cpp.linker.so.release">
|
||||
<option defaultValue="true" id="gnu.cpp.link.so.release.option.shared.517821764" name="Shared (-shared)" superClass="gnu.cpp.link.so.release.option.shared" valueType="boolean"/>
|
||||
<inputType id="cdt.managedbuild.tool.gnu.cpp.linker.input.267988943" superClass="cdt.managedbuild.tool.gnu.cpp.linker.input">
|
||||
<additionalInput kind="additionalinputdependency" paths="$(USER_OBJS)"/>
|
||||
<additionalInput kind="additionalinput" paths="$(LIBS)"/>
|
||||
</inputType>
|
||||
</tool>
|
||||
<tool id="cdt.managedbuild.tool.gnu.assembler.so.release.1520626301" name="GCC Assembler" superClass="cdt.managedbuild.tool.gnu.assembler.so.release">
|
||||
<inputType id="cdt.managedbuild.tool.gnu.assembler.input.1578760595" superClass="cdt.managedbuild.tool.gnu.assembler.input"/>
|
||||
</tool>
|
||||
</toolChain>
|
||||
</folderInfo>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.externalSettings"/>
|
||||
</cconfiguration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="cdtBuildSystem" version="4.0.0">
|
||||
<project id="liblua.cdt.managedbuild.target.gnu.so.1215346443" name="Shared Library" projectType="cdt.managedbuild.target.gnu.so"/>
|
||||
</storageModule>
|
||||
<storageModule moduleId="scannerConfiguration">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.so.debug.1532040290;cdt.managedbuild.config.gnu.so.debug.1532040290.;cdt.managedbuild.tool.gnu.c.compiler.so.debug.2114277329;cdt.managedbuild.tool.gnu.c.compiler.input.1259937486">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.so.debug.1532040290;cdt.managedbuild.config.gnu.so.debug.1532040290.;cdt.managedbuild.tool.gnu.cpp.compiler.so.debug.1908142641;cdt.managedbuild.tool.gnu.cpp.compiler.input.2035513663">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.so.release.1209971451;cdt.managedbuild.config.gnu.so.release.1209971451.;cdt.managedbuild.tool.gnu.c.compiler.so.release.472386122;cdt.managedbuild.tool.gnu.c.compiler.input.1197021556">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
<scannerConfigBuildInfo instanceId="cdt.managedbuild.config.gnu.so.release.1209971451;cdt.managedbuild.config.gnu.so.release.1209971451.;cdt.managedbuild.tool.gnu.cpp.compiler.so.release.1495522959;cdt.managedbuild.tool.gnu.cpp.compiler.input.1022202619">
|
||||
<autodiscovery enabled="true" problemReportingEnabled="true" selectedProfileId=""/>
|
||||
</scannerConfigBuildInfo>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.core.LanguageSettingsProviders"/>
|
||||
<storageModule moduleId="refreshScope" versionNumber="2">
|
||||
<configuration configurationName="Release">
|
||||
<resource resourceType="PROJECT" workspacePath="/liblua"/>
|
||||
</configuration>
|
||||
<configuration configurationName="Debug">
|
||||
<resource resourceType="PROJECT" workspacePath="/liblua"/>
|
||||
</configuration>
|
||||
</storageModule>
|
||||
<storageModule moduleId="org.eclipse.cdt.internal.ui.text.commentOwnerProjectMappings"/>
|
||||
</cproject>
|
|
@ -0,0 +1,40 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<projectDescription>
|
||||
<name>liblua</name>
|
||||
<comment></comment>
|
||||
<projects>
|
||||
</projects>
|
||||
<buildSpec>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.genmakebuilder</name>
|
||||
<triggers>clean,full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
<buildCommand>
|
||||
<name>org.eclipse.cdt.managedbuilder.core.ScannerConfigBuilder</name>
|
||||
<triggers>full,incremental,</triggers>
|
||||
<arguments>
|
||||
</arguments>
|
||||
</buildCommand>
|
||||
</buildSpec>
|
||||
<natures>
|
||||
<nature>org.eclipse.cdt.core.cnature</nature>
|
||||
<nature>org.eclipse.cdt.core.ccnature</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.managedBuildNature</nature>
|
||||
<nature>org.eclipse.cdt.managedbuilder.core.ScannerConfigNature</nature>
|
||||
</natures>
|
||||
<linkedResources>
|
||||
<link>
|
||||
<name>lua</name>
|
||||
<type>2</type>
|
||||
<locationURI>PARENT-1-PROJECT_LOC/lua</locationURI>
|
||||
</link>
|
||||
<link>
|
||||
<name>tolua</name>
|
||||
<type>2</type>
|
||||
<locationURI>PARENT-1-PROJECT_LOC/tolua</locationURI>
|
||||
</link>
|
||||
</linkedResources>
|
||||
</projectDescription>
|
||||
|
|
@ -0,0 +1,75 @@
|
|||
CC = gcc
|
||||
CXX = g++
|
||||
TARGET = liblua.so
|
||||
CCFLAGS = -Wall -fPIC
|
||||
CXXFLAGS = -Wall -fPIC
|
||||
VISIBILITY =
|
||||
|
||||
LBITS := $(shell getconf LONG_BIT)
|
||||
INCLUDES = -I../lua \
|
||||
-I../tolua \
|
||||
|
||||
DEFINES = -DLINUX
|
||||
|
||||
OBJECTS = ../lua/lapi.o \
|
||||
../lua/lauxlib.o \
|
||||
../lua/lbaselib.o \
|
||||
../lua/lcode.o \
|
||||
../lua/ldblib.o \
|
||||
../lua/ldebug.o \
|
||||
../lua/ldo.o \
|
||||
../lua/ldump.o \
|
||||
../lua/lfunc.o \
|
||||
../lua/lgc.o \
|
||||
../lua/linit.o \
|
||||
../lua/liolib.o \
|
||||
../lua/llex.o \
|
||||
../lua/lmathlib.o \
|
||||
../lua/lmem.o \
|
||||
../lua/loadlib.o \
|
||||
../lua/lobject.o \
|
||||
../lua/lopcodes.o \
|
||||
../lua/loslib.o \
|
||||
../lua/lparser.o \
|
||||
../lua/lstate.o \
|
||||
../lua/lstring.o \
|
||||
../lua/lstrlib.o \
|
||||
../lua/ltable.o \
|
||||
../lua/ltablib.o \
|
||||
../lua/ltm.o \
|
||||
../lua/lua.o \
|
||||
../lua/lundump.o \
|
||||
../lua/lvm.o \
|
||||
../lua/lzio.o \
|
||||
../lua/print.o \
|
||||
../tolua/tolua_event.o \
|
||||
../tolua/tolua_is.o \
|
||||
../tolua/tolua_map.o \
|
||||
../tolua/tolua_push.o \
|
||||
../tolua/tolua_to.o
|
||||
|
||||
STATICLIBS =
|
||||
|
||||
debug: CCFLAGS += -g3 -O0
|
||||
debug: CXXFLAGS += -g3 -O0
|
||||
debug: DEFINES += -DDEBUG
|
||||
debug: $(TARGET)
|
||||
|
||||
release: CCFLAGS += -O3
|
||||
release: CXXFLAGS += -O3
|
||||
release: DEFINES += -DNDEBUG
|
||||
release: $(TARGET)
|
||||
|
||||
####### Build rules
|
||||
$(TARGET): $(OBJECTS)
|
||||
$(CXX) $(CXXFLAGS) $(INCLUDES) $(DEFINES) $(OBJECTS) -shared -o $(TARGET) $(SHAREDLIBS) $(STATICLIBS)
|
||||
|
||||
####### Compile
|
||||
%.o: %.cpp
|
||||
$(CXX) $(CXXFLAGS) $(INCLUDES) $(DEFINES) $(VISIBILITY) -c $< -o $@
|
||||
|
||||
%.o: %.c
|
||||
$(CC) $(CCFLAGS) $(INCLUDES) $(DEFINES) $(VISIBILITY) -c $< -o $@
|
||||
|
||||
clean:
|
||||
rm -f $(OBJECTS) $(TARGET) core
|
|
@ -12,7 +12,14 @@
|
|||
defined('DS') or define('DS', DIRECTORY_SEPARATOR);
|
||||
define('SRC_DIR', __DIR__ . DS);
|
||||
define('OUT_DIR', dirname(__DIR__) . '/../scripting/lua/cocos2dx_support/');
|
||||
define('TOLUA_BIN', (DS == '\\') ? 'tolua++.exe' : '/usr/local/bin/tolua++');
|
||||
if (PHP_OS == 'Linux')
|
||||
{
|
||||
define('TOLUA_BIN', '/usr/bin/tolua++5.1');
|
||||
}
|
||||
else
|
||||
{
|
||||
define('TOLUA_BIN', (DS == '\\') ? 'tolua++.exe' : '/usr/local/bin/tolua++');
|
||||
}
|
||||
|
||||
class Builder
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue