mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-02 09:52:27 -04:00
Changes for windows
This commit is contained in:
parent
a4015b9543
commit
fa6c41f363
@ -261,17 +261,18 @@ if __name__ == "__main__":
|
|||||||
else:
|
else:
|
||||||
print "Making CHM file for manual..."
|
print "Making CHM file for manual..."
|
||||||
if VERSION == None:
|
if VERSION == None:
|
||||||
makeManualCHM("panda3d-manual.chm", "manual", "Panda3D Manual")
|
makeManualCHM("manual.chm", "manual", "Panda3D Manual")
|
||||||
else:
|
else:
|
||||||
makeManualCHM("panda3d-%s-manual.chm" % VERSION, "manual", "Panda3D %s Manual" % VERSION)
|
makeManualCHM("manual-%s.chm" % VERSION, "manual", "Panda3D %s Manual" % VERSION)
|
||||||
|
|
||||||
if not os.path.isdir("reference"):
|
if not os.path.isdir("reference"):
|
||||||
print "No directory named 'reference' found"
|
print "No directory named 'reference' found"
|
||||||
else:
|
else:
|
||||||
print "Making CHM file for API reference..."
|
print "Making CHM file for API reference..."
|
||||||
if VERSION == None:
|
if VERSION == None:
|
||||||
makeReferenceCHM("panda3d-reference.chm", "reference", "Panda3D Reference")
|
makeReferenceCHM("reference.chm", "reference", "Panda3D Reference")
|
||||||
else:
|
else:
|
||||||
makeReferenceCHM("panda3d-%s-reference.chm" % VERSION, "reference", "Panda3D %s Reference" % VERSION)
|
makeReferenceCHM("reference-%s.chm" % VERSION, "reference", "Panda3D %s Reference" % VERSION)
|
||||||
|
|
||||||
print "Done!"
|
print "Done!"
|
||||||
|
|
||||||
|
@ -1039,7 +1039,7 @@ else: sys.exit("Cannot find the 'direct' tree")
|
|||||||
"""
|
"""
|
||||||
|
|
||||||
if (PkgSkip("PYTHON")==0):
|
if (PkgSkip("PYTHON")==0):
|
||||||
ConditionalWriteFile('built/direct/__init__.py', DIRECTINIT)
|
ConditionalWriteFile(GetOutputDir()+'/direct/__init__.py', DIRECTINIT)
|
||||||
|
|
||||||
##########################################################################################
|
##########################################################################################
|
||||||
#
|
#
|
||||||
|
@ -460,6 +460,17 @@ def GetRegistryKey(path, subkey):
|
|||||||
_winreg.CloseKey(key)
|
_winreg.CloseKey(key)
|
||||||
return k1
|
return k1
|
||||||
|
|
||||||
|
def GetProgramFiles():
|
||||||
|
if (os.environ.has_key("PROGRAMFILES")):
|
||||||
|
return os.environ["PROGRAMFILES"]
|
||||||
|
elif (os.path.isdir("C:\\Program Files")):
|
||||||
|
return "C:\\Program Files"
|
||||||
|
elif (os.path.isdir("D:\\Program Files")):
|
||||||
|
return "D:\\Program Files"
|
||||||
|
elif (os.path.isdir("E:\\Program Files")):
|
||||||
|
return "E:\\Program Files"
|
||||||
|
return 0
|
||||||
|
|
||||||
########################################################################
|
########################################################################
|
||||||
##
|
##
|
||||||
## Parsing Compiler Option Lists
|
## Parsing Compiler Option Lists
|
||||||
@ -847,10 +858,16 @@ def SdkLocateMSPlatform():
|
|||||||
if (platsdk == 0):
|
if (platsdk == 0):
|
||||||
platsdk=GetRegistryKey("SOFTWARE\\Microsoft\\Microsoft SDKs\\Windows\\v6.1","InstallationFolder")
|
platsdk=GetRegistryKey("SOFTWARE\\Microsoft\\Microsoft SDKs\\Windows\\v6.1","InstallationFolder")
|
||||||
|
|
||||||
if (platsdk == 0 and os.path.isdir("C:\\Program Files\\Microsoft Visual Studio 9\\VC\\PlatformSDK")):
|
if (platsdk == 0 and os.path.isdir(os.path.join(GetProgramFiles(), "Microsoft Platform SDK for Windows Server 2003 R2"))):
|
||||||
platsdk = "C:\\Program Files\\Microsoft Visual Studio 9\\VC\\PlatformSDK\\"
|
platsdk = os.path.join(GetProgramFiles(), "Microsoft Platform SDK for Windows Server 2003 R2")
|
||||||
|
|
||||||
|
# Doesn't work with the Express versions, so we're checking for the "atlmfc" dir, which is not in the Express
|
||||||
|
if (platsdk == 0 and os.path.isdir(os.path.join(GetProgramFiles(), "Microsoft Visual Studio 9\\VC\\atlmfc"))):
|
||||||
|
platsdk = os.path.join(GetProgramFiles(), "Microsoft Visual Studio 9\\VC\\PlatformSDK")
|
||||||
|
|
||||||
if (platsdk != 0):
|
if (platsdk != 0):
|
||||||
|
if (not platsdk.endswith("//")):
|
||||||
|
platsdk += "//"
|
||||||
SDK["MSPLATFORM"] = platsdk
|
SDK["MSPLATFORM"] = platsdk
|
||||||
|
|
||||||
def SdkLocateMacOSX():
|
def SdkLocateMacOSX():
|
||||||
@ -930,7 +947,9 @@ def SetupVisualStudioEnviron():
|
|||||||
AddToPathEnv("PATH", SDK["VISUALSTUDIO"] + "VC\\bin")
|
AddToPathEnv("PATH", SDK["VISUALSTUDIO"] + "VC\\bin")
|
||||||
AddToPathEnv("PATH", SDK["VISUALSTUDIO"] + "Common7\\IDE")
|
AddToPathEnv("PATH", SDK["VISUALSTUDIO"] + "Common7\\IDE")
|
||||||
AddToPathEnv("INCLUDE", SDK["VISUALSTUDIO"] + "VC\\include")
|
AddToPathEnv("INCLUDE", SDK["VISUALSTUDIO"] + "VC\\include")
|
||||||
|
AddToPathEnv("INCLUDE", SDK["VISUALSTUDIO"] + "VC\\atlmfc\\include")
|
||||||
AddToPathEnv("LIB", SDK["VISUALSTUDIO"] + "VC\\lib")
|
AddToPathEnv("LIB", SDK["VISUALSTUDIO"] + "VC\\lib")
|
||||||
|
AddToPathEnv("PATH", SDK["MSPLATFORM"] + "bin")
|
||||||
AddToPathEnv("INCLUDE", SDK["MSPLATFORM"] + "include")
|
AddToPathEnv("INCLUDE", SDK["MSPLATFORM"] + "include")
|
||||||
AddToPathEnv("INCLUDE", SDK["MSPLATFORM"] + "include\\atl")
|
AddToPathEnv("INCLUDE", SDK["MSPLATFORM"] + "include\\atl")
|
||||||
AddToPathEnv("LIB", SDK["MSPLATFORM"] + "lib")
|
AddToPathEnv("LIB", SDK["MSPLATFORM"] + "lib")
|
||||||
|
@ -22,6 +22,18 @@
|
|||||||
|
|
||||||
#include "dtool_config.h"
|
#include "dtool_config.h"
|
||||||
|
|
||||||
|
/* Make sure WIN32 and WIN32_VC are defined when using MSVC */
|
||||||
|
#ifdef _WIN32
|
||||||
|
#ifndef WIN32
|
||||||
|
#define WIN32
|
||||||
|
#endif
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
#ifndef WIN32_VC
|
||||||
|
#define WIN32_VC
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef WIN32_VC
|
#ifdef WIN32_VC
|
||||||
/* These warning pragmas must appear before anything else for VC++ to
|
/* These warning pragmas must appear before anything else for VC++ to
|
||||||
respect them. Sheesh. */
|
respect them. Sheesh. */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user