changeset 1:3c2e0caab57b

Added initial sconstruct and sconscript.
author Atul Varma <varmaa@toolness.com>
date Tue, 06 May 2008 14:33:51 -0700
parents 3393caed6b2d
children 8f0e873fe0aa
files .hgignore SConstruct xpcom/src/SConscript
diffstat 3 files changed, 85 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.hgignore	Tue May 06 14:33:51 2008 -0700
@@ -0,0 +1,4 @@
+syntax: glob
+*.os
+*.dylib
+.sconsign.dblite
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/SConstruct	Tue May 06 14:33:51 2008 -0700
@@ -0,0 +1,41 @@
+import sys
+
+env = Environment(
+    ROOT_MOZ_DIR = "/Users/varmaa/Documents/mozilla-stuff/builds/basic-firefox/dist",
+    GECKO_SDK_DIR = "${ROOT_MOZ_DIR}/sdk",
+    XPCOM_INCLUDE_DIR = "${ROOT_MOZ_DIR}/include/xpcom"
+    )
+
+env.Append(
+    CPPPATH = ["${GECKO_SDK_DIR}/include", env["XPCOM_INCLUDE_DIR"],
+               sys.prefix + "/include/python" + sys.version[:3]],
+    LIBPATH = ["${GECKO_SDK_DIR}/lib"],
+    CPPFLAGS = ["-fno-rtti",
+                "-fno-exceptions",
+                "-fno-strict-aliasing",
+                "-fpascal-strings",
+                "-fno-common",
+                "-fshort-wchar",
+                # This is a replacement for including mozilla/config/gcc_hidden.h.
+                "-fvisibility=hidden",
+                "-pthread",
+                "-pipe",
+                "-Wall",
+                "-Wconversion",
+                "-Wpointer-arith",
+                "-Woverloaded-virtual",
+                "-Wsynth",
+                "-Wno-ctor-dtor-privacy",
+                "-Wno-non-virtual-dtor",
+                "-Wcast-align",
+                "-Wno-long-long",
+                "-include", "${ROOT_MOZ_DIR}/include/mozilla-config.h"],
+    CPPDEFINES = {"OSTYPE": "Darwin9.2.2",
+                  "OSARCH" : "Darwin",
+                  "NDEBUG" : "1",
+                  "TRIMMED" : "1",
+                  "MOZILLA_CLIENT" : "1",
+                  }
+    )
+
+SConscript("xpcom/src/SConscript", exports="env")
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/xpcom/src/SConscript	Tue May 06 14:33:51 2008 -0700
@@ -0,0 +1,40 @@
+Import("env")
+
+files = [
+    "ErrorUtils.cpp",
+    "PyGBase.cpp",
+    "PyGModule.cpp",
+    "PyGStub.cpp",
+    "PyGInputStream.cpp",
+    "PyGWeakReference.cpp",
+    "PyIClassInfo.cpp",
+    "PyIComponentManager.cpp",
+    "PyIInputStream.cpp",
+    "PyIEnumerator.cpp",
+    "PyIID.cpp",
+    "PyIInterfaceInfo.cpp",
+    "PyIInterfaceInfoManager.cpp",
+    "PyISimpleEnumerator.cpp",
+    "PyISupports.cpp",
+    "PyIVariant.cpp",
+    "Pyxpt_info.cpp",
+    "TypeObject.cpp",
+    "VariantUtils.cpp",
+    "dllmain.cpp",
+    ]
+
+libs = [
+    "xpcomglue_s",
+    "xpcom",
+    "nspr4",
+    "plc4"
+    ]
+
+frameworks = [
+    "Python",
+    ]
+
+env.LoadableModule(source=files,
+                   target="lib_xpcom.dylib",
+                   LIBS=libs,
+                   FRAMEWORKS=frameworks)