mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-01 01:07:51 -04:00
Added packpanda mode
This commit is contained in:
parent
01333b339c
commit
c80e8bd572
@ -25,7 +25,7 @@
|
||||
#ifdef BUILDING_PPYTHON
|
||||
#define LINK_SOURCE "\\bin\\ppython.exe"
|
||||
#define LINK_TARGET "\\python\\python.exe"
|
||||
#define GENPYCODE 0
|
||||
#define PPYTHON 1
|
||||
#endif
|
||||
|
||||
#ifdef BUILDING_GENPYCODE
|
||||
@ -34,6 +34,12 @@
|
||||
#define GENPYCODE 1
|
||||
#endif
|
||||
|
||||
#ifdef BUILDING_PACKPANDA
|
||||
#define LINK_SOURCE "\\bin\\packpanda.exe"
|
||||
#define LINK_TARGET "\\python\\python.exe"
|
||||
#define PACKPANDA 1
|
||||
#endif
|
||||
|
||||
#include <windows.h>
|
||||
#include <winuser.h>
|
||||
#include <stdlib.h>
|
||||
@ -103,9 +109,15 @@ int main(int argc, char **argv)
|
||||
|
||||
// Calculate MODCMD
|
||||
|
||||
if (GENPYCODE) {
|
||||
sprintf(modcmd,"python -c \"import direct.ffi.jGenPyCode\" %s",args);
|
||||
} else sprintf(modcmd,"python %s",args);
|
||||
#ifdef PPYTHON
|
||||
sprintf(modcmd,"python %s",args);
|
||||
#endif
|
||||
#ifdef GENPYCODE
|
||||
sprintf(modcmd,"python -c \"import direct.ffi.jGenPyCode\" %s",args);
|
||||
#endif
|
||||
#ifdef PACKPANDA
|
||||
sprintf(modcmd,"python -c \"import direct.directscripts.packpanda\" %s",args);
|
||||
#endif
|
||||
|
||||
// Run it.
|
||||
|
||||
@ -132,7 +144,7 @@ int main(int argc, char **argv)
|
||||
|
||||
#ifdef BUILDING_PPYTHON
|
||||
#define LINK_SOURCE "/bin/ppython"
|
||||
#define GENPYCODE 0
|
||||
#define PPYTHON 1
|
||||
#endif
|
||||
|
||||
#ifdef BUILDING_GENPYCODE
|
||||
@ -140,6 +152,11 @@ int main(int argc, char **argv)
|
||||
#define GENPYCODE 1
|
||||
#endif
|
||||
|
||||
#ifdef BUILDING_PACKPANDA
|
||||
#define LINK_SOURCE "/bin/packpanda"
|
||||
#define PACKPANDA 1
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <malloc.h>
|
||||
#include <stdio.h>
|
||||
@ -196,10 +213,14 @@ int main(int argc, char **argv)
|
||||
|
||||
modargc=0;
|
||||
modargv[modargc++]="python";
|
||||
if (GENPYCODE) {
|
||||
#ifdef GENPYCODE
|
||||
modargv[modargc++] = "-c";
|
||||
modargv[modargc++] = "import direct.ffi.jGenPyCode";
|
||||
}
|
||||
#endif
|
||||
#ifdef PACKPANDA
|
||||
modargv[modargc++] = "-c";
|
||||
modargv[modargc++] = "import direct.ffi.packpanda";
|
||||
#endif
|
||||
for (int i=1; i<argc; i++) modargv[modargc++] = argv[i];
|
||||
modargv[modargc] = 0;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user