summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--build/Makefile.am13
-rw-r--r--build/win32/Makefile.am12
-rw-r--r--build/win32/detectenv-msvc.mak (renamed from build/detectenv_msvc.mak)140
-rw-r--r--build/win32/gen-win32-cairo-gir.py (renamed from build/gen-win32-cairo-gir.py)2
-rw-r--r--build/win32/gen-win32-g-ir-tools.py (renamed from build/gen-win32-g-ir-tools.py)2
-rw-r--r--build/win32/gi-build-common-msvc.mak (renamed from build/gi-build-common-msvc.mak)9
-rw-r--r--build/win32/gi-introspection-msvc.mak (renamed from build/gi-introspection-msvc.mak)54
-rw-r--r--build/win32/gi-setenv-msvc.mak (renamed from build/gi-setenv-msvc.mak)9
-rw-r--r--build/win32/gi-tests-msvc.mak (renamed from build/gi-tests-msvc.mak)135
-rw-r--r--build/win32/gi_msvc_build_utils.py (renamed from build/gi_msvc_build_utils.py)0
-rw-r--r--build/win32/introspection-msvc.mak (renamed from build/introspection-msvc.mak)27
-rw-r--r--build/win32/replace.py (renamed from build/replace.py)0
-rw-r--r--build/win32/vs10/README.txt24
-rw-r--r--build/win32/vs10/gi-extra-paths.props6
-rw-r--r--build/win32/vs10/gi-gen-srcs.props4
-rw-r--r--build/win32/vs10/gi-install.propsin10
-rw-r--r--build/win32/vs10/gi-install.vcxproj10
-rw-r--r--build/win32/vs9/README.txt24
-rw-r--r--build/win32/vs9/gi-extra-paths.vsprops4
-rw-r--r--build/win32/vs9/gi-gen-srcs.vsprops8
-rw-r--r--build/win32/vs9/gi-install.vspropsin2
21 files changed, 251 insertions, 244 deletions
diff --git a/build/Makefile.am b/build/Makefile.am
index 55641201..701e20b3 100644
--- a/build/Makefile.am
+++ b/build/Makefile.am
@@ -1,14 +1,3 @@
SUBDIRS = win32
-EXTRA_DIST = \
- detectenv_msvc.mak \
- gen-win32-cairo-gir.py \
- gen-win32-g-ir-tools.py \
- gi-build-common-msvc.mak \
- gi-introspection-msvc.mak \
- gi_msvc_build_utils.py \
- gi-setenv-msvc.mak \
- gi-tests-msvc.mak \
- introspection-msvc.mak \
- replace.py \
- Makefile.msvc-introspection
+EXTRA_DIST = Makefile.msvc-introspection
diff --git a/build/win32/Makefile.am b/build/win32/Makefile.am
index f30ee9b8..6e4e593f 100644
--- a/build/win32/Makefile.am
+++ b/build/win32/Makefile.am
@@ -5,3 +5,15 @@ SUBDIRS = \
vs12 \
vs14
+EXTRA_DIST = \
+ detectenv-msvc.mak \
+ gen-win32-cairo-gir.py \
+ gen-win32-g-ir-tools.py \
+ gi-build-common-msvc.mak \
+ gi-introspection-msvc.mak \
+ gi_msvc_build_utils.py \
+ gi-setenv-msvc.mak \
+ gi-tests-msvc.mak \
+ introspection-msvc.mak \
+ replace.py
+
diff --git a/build/detectenv_msvc.mak b/build/win32/detectenv-msvc.mak
index d4b9b84a..2dfb8e18 100644
--- a/build/detectenv_msvc.mak
+++ b/build/win32/detectenv-msvc.mak
@@ -1,69 +1,71 @@
-# Check to see we are configured to build with MSVC (MSDEVDIR, MSVCDIR or
-# VCINSTALLDIR) or with the MS Platform SDK (MSSDK or WindowsSDKDir)
-!if !defined(VCINSTALLDIR) && !defined(WINDOWSSDKDIR)
-MSG = ^
-This Makefile is only for Visual Studio 2008 and later.^
-You need to ensure that the Visual Studio Environment is properly set up^
-before running this Makefile.
-!error $(MSG)
-!endif
-
-ERRNUL = 2>NUL
-_HASH=^#
-
-!if ![echo VCVERSION=_MSC_VER > vercl.x] \
- && ![echo $(_HASH)if defined(_M_IX86) >> vercl.x] \
- && ![echo PLAT=Win32 >> vercl.x] \
- && ![echo $(_HASH)elif defined(_M_AMD64) >> vercl.x] \
- && ![echo PLAT=x64 >> vercl.x] \
- && ![echo $(_HASH)endif >> vercl.x] \
- && ![cl -nologo -TC -P vercl.x $(ERRNUL)]
-!include vercl.i
-!if ![echo VCVER= ^\> vercl.vc] \
- && ![set /a $(VCVERSION) / 100 - 6 >> vercl.vc]
-!include vercl.vc
-!endif
-!endif
-!if ![del $(ERRNUL) /q/f vercl.x vercl.i vercl.vc]
-!endif
-
-!if $(VCVERSION) > 1499 && $(VCVERSION) < 1600
-VSVER = 9
-!elseif $(VCVERSION) > 1599 && $(VCVERSION) < 1700
-VSVER = 10
-!elseif $(VCVERSION) > 1699 && $(VCVERSION) < 1800
-VSVER = 11
-!elseif $(VCVERSION) > 1799 && $(VCVERSION) < 1900
-VSVER = 12
-!else
-VSVER = 0
-!endif
-
-!if "$(VSVER)" == "0"
-MSG = ^
-This NMake Makefile set supports Visual Studio^
-9 (2008) through 12 (2013). Your Visual Studio^
-version is not supported.
-!error $(MSG)
-!endif
-
-VALID_CFGSET = FALSE
-!if "$(CFG)" == "release" || "$(CFG)" == "debug"
-VALID_CFGSET = TRUE
-!endif
-
-!if "$(CFG)" == "release"
-!if "$(VSVER)" == "9" && "$(PLAT)" == "x64"
-CFLAGS_ADD = /MD /O1 /Oi
-!else
-CFLAGS_ADD = /MD /O2
-!endif
-!else
-CFLAGS_ADD = /MDd /Od /Zi /DG_ENABLE_DEBUG
-!endif
-
-!if "$(PLAT)" == "x64"
-LDFLAGS_ARCH = /machine:x64
-!else
-LDFLAGS_ARCH = /machine:x86
-!endif \ No newline at end of file
+# Check to see we are configured to build with MSVC (MSDEVDIR, MSVCDIR or
+# VCINSTALLDIR) or with the MS Platform SDK (MSSDK or WindowsSDKDir)
+!if !defined(VCINSTALLDIR) && !defined(WINDOWSSDKDIR)
+MSG = ^
+This Makefile is only for Visual Studio 2008 and later.^
+You need to ensure that the Visual Studio Environment is properly set up^
+before running this Makefile.
+!error $(MSG)
+!endif
+
+ERRNUL = 2>NUL
+_HASH=^#
+
+!if ![echo VCVERSION=_MSC_VER > vercl.x] \
+ && ![echo $(_HASH)if defined(_M_IX86) >> vercl.x] \
+ && ![echo PLAT=Win32 >> vercl.x] \
+ && ![echo $(_HASH)elif defined(_M_AMD64) >> vercl.x] \
+ && ![echo PLAT=x64 >> vercl.x] \
+ && ![echo $(_HASH)endif >> vercl.x] \
+ && ![cl -nologo -TC -P vercl.x $(ERRNUL)]
+!include vercl.i
+!if ![echo VCVER= ^\> vercl.vc] \
+ && ![set /a $(VCVERSION) / 100 - 6 >> vercl.vc]
+!include vercl.vc
+!endif
+!endif
+!if ![del $(ERRNUL) /q/f vercl.x vercl.i vercl.vc]
+!endif
+
+!if $(VCVERSION) > 1499 && $(VCVERSION) < 1600
+VSVER = 9
+!elseif $(VCVERSION) > 1599 && $(VCVERSION) < 1700
+VSVER = 10
+!elseif $(VCVERSION) > 1699 && $(VCVERSION) < 1800
+VSVER = 11
+!elseif $(VCVERSION) > 1799 && $(VCVERSION) < 1900
+VSVER = 12
+!elseif $(VCVERSION) > 1899 && $(VCVERSION) < 2000
+VSVER = 14
+!else
+VSVER = 0
+!endif
+
+!if "$(VSVER)" == "0"
+MSG = ^
+This NMake Makefile set supports Visual Studio^
+9 (2008) through 14 (2015). Your Visual Studio^
+version is not supported.
+!error $(MSG)
+!endif
+
+VALID_CFGSET = FALSE
+!if "$(CFG)" == "release" || "$(CFG)" == "debug"
+VALID_CFGSET = TRUE
+!endif
+
+!if "$(CFG)" == "release"
+!if "$(VSVER)" == "9" && "$(PLAT)" == "x64"
+CFLAGS_ADD = /MD /O1 /Oi
+!else
+CFLAGS_ADD = /MD /O2
+!endif
+!else
+CFLAGS_ADD = /MDd /Od /Zi /DG_ENABLE_DEBUG
+!endif
+
+!if "$(PLAT)" == "x64"
+LDFLAGS_ARCH = /machine:x64
+!else
+LDFLAGS_ARCH = /machine:x86
+!endif
diff --git a/build/gen-win32-cairo-gir.py b/build/win32/gen-win32-cairo-gir.py
index 1216daa4..464d9849 100644
--- a/build/gen-win32-cairo-gir.py
+++ b/build/win32/gen-win32-cairo-gir.py
@@ -25,7 +25,7 @@ def main(argv):
args = parser.parse_args()
# Get the srcroot and the path where the bundled .gir files reside in the package
- srcroot = parent_dir(__file__)
+ srcroot = parent_dir(parent_dir(__file__))
preset_gir_path = os.path.join(srcroot, 'gir')
# Set up variables in cairo-1.0.gir.in to produce cairo-1.0.gir
diff --git a/build/gen-win32-g-ir-tools.py b/build/win32/gen-win32-g-ir-tools.py
index 444fe80f..13360865 100644
--- a/build/gen-win32-g-ir-tools.py
+++ b/build/win32/gen-win32-g-ir-tools.py
@@ -42,7 +42,7 @@ def main(argv):
funcs = ['scanner_main','annotation_main','doc_main']
tools = ['g-ir-scanner','g-ir-annotation-tool','g-ir-doc-tool']
- srcroot = parent_dir(__file__)
+ srcroot = parent_dir(parent_dir(__file__))
preset_tools_path = os.path.join(srcroot, 'tools')
src = os.path.join(preset_tools_path, 'g-ir-tool-template.in')
diff --git a/build/gi-build-common-msvc.mak b/build/win32/gi-build-common-msvc.mak
index c7db78a8..6d108eab 100644
--- a/build/gi-build-common-msvc.mak
+++ b/build/win32/gi-build-common-msvc.mak
@@ -2,7 +2,7 @@
# Please do not change anything after this line
-!include detectenv_msvc.mak
+!include detectenv-msvc.mak
GI_APIVERSION = 1.0
GLIB_APIVERSION = 2.0
@@ -11,7 +11,8 @@ CHECK_PACKAGE = gio-$(GLIB_APIVERSION)
!include introspection-msvc.mak
-BINDIR = ..\build\win32\vs$(VSVER)\$(CFG)\$(PLAT)\bin
-G_IR_SCANNER_CURRENT = ..\tools\g-ir-scanner
-G_IR_DOC_TOOL_CURRENT = ..\tools\g-ir-doc-tool
+BINDIR = vs$(VSVER)\$(CFG)\$(PLAT)\bin
+G_IR_SCANNER_CURRENT = ..\..\tools\g-ir-scanner
+G_IR_DOC_TOOL_CURRENT = ..\..\tools\g-ir-doc-tool
G_IR_COMPILER_CURRENT = $(BINDIR)\g-ir-compiler.exe
+TOP_SRCDIR = ..\..
diff --git a/build/gi-introspection-msvc.mak b/build/win32/gi-introspection-msvc.mak
index a7d05a25..9db3e4e3 100644
--- a/build/gi-introspection-msvc.mak
+++ b/build/win32/gi-introspection-msvc.mak
@@ -50,7 +50,7 @@ built_install_typelibs = \
GIRepository-$(GLIB_APIVERSION).typelib
!if "$(BUILD_INTROSPECTION)" == "TRUE"
-all: setgirbuildnev $(built_install_girs) $(built_install_typelibs) $(bundled_girs) $(bundled_typelibs) msg_cairo
+all: setgirbuildenv $(built_install_girs) $(built_install_typelibs) $(bundled_girs) $(bundled_typelibs) msg_cairo
!include gi-setenv-msvc.mak
@@ -59,35 +59,35 @@ glib_list:
@-echo $(BASEDIR)\lib\glib-2.0\include\glibconfig.h> $@
@-for /f %%a in ('dir /b $(BASEDIR)\include\glib-2.0\glib\*.h') do @echo $(BASEDIR)\include\glib-2.0\glib\%%a>> $@
@-echo $(BASEDIR)\include\glib-2.0\gobject\glib-types.h>> $@
- @-echo ..\gir\glib-2.0.c>> $@
+ @-echo $(TOP_SRCDIR)\gir\glib-2.0.c>> $@
gobject_list:
@-echo Generating file list for GObject...
@-type NUL > $@
@-for /f %%a in ('dir /b $(BASEDIR)\include\glib-2.0\gobject\*.h') do @if not %%a == glib-types.h @echo $(BASEDIR)\include\glib-2.0\gobject\%%a>> $@
- @-echo ..\gir\gobject-2.0.c>> $@
+ @-echo $(TOP_SRCDIR)\gir\gobject-2.0.c>> $@
gio_list:
@-echo Generating file list for GIO...
@-type NUL > $@
@-for /f %%a in ('dir /b $(BASEDIR)\include\gio-win32-2.0\gio\*.h') do @echo $(BASEDIR)\include\gio-win32-2.0\gio\%%a>> $@
@-for /f %%a in ('dir /b $(BASEDIR)\include\glib-2.0\gio\*.h') do @if not %%a == gsettingsbackend.h @echo $(BASEDIR)\include\glib-2.0\gio\%%a>> $@
- @-echo ..\gir\gio-2.0.c>> $@
+ @-echo $(TOP_SRCDIR)\gir\gio-2.0.c>> $@
gi_list:
@-echo Generating file list for girepository...
- @-echo ..\girepository\girepository.h > $@
- @-echo ..\girepository\girepository.c >> $@
- @-for /f %%a in ('dir /b ..\girepository\gi*info.c') do @echo ..\girepository\%%a >> $@
- @-for /f %%a in ('dir /b ..\girepository\gi*info.h') do @echo ..\girepository\%%a >> $@
- @-echo ..\girepository\gitypelib.h >> $@
- @-echo ..\girepository\gitypes.h >> $@
+ @-echo $(TOP_SRCDIR)\girepository\girepository.h > $@
+ @-echo $(TOP_SRCDIR)\girepository\girepository.c >> $@
+ @-for /f %%a in ('dir /b $(TOP_SRCDIR)\girepository\gi*info.c') do @echo $(TOP_SRCDIR)\girepository\%%a >> $@
+ @-for /f %%a in ('dir /b $(TOP_SRCDIR)\girepository\gi*info.h') do @echo $(TOP_SRCDIR)\girepository\%%a >> $@
+ @-echo $(TOP_SRCDIR)\girepository\gitypelib.h >> $@
+ @-echo $(TOP_SRCDIR)\girepository\gitypes.h >> $@
# Generated .gir files for GLib/GModule/GObject/Gio/GIRepository
GLib-$(GLIB_APIVERSION).gir: glib_list
@-echo Generating $@...
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --verbose -I.. --add-include-path=.. \
- --add-include-path=..\gir --add-include-path=. --namespace=GLib --nsversion=$(GLIB_APIVERSION) \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --verbose -I$(TOP_SRCDIR) --add-include-path=$(TOP_SRCDIR) \
+ --add-include-path=$(TOP_SRCDIR)\gir --add-include-path=. --namespace=GLib --nsversion=$(GLIB_APIVERSION) \
--no-libtool --pkg=glib-$(GLIB_APIVERSION) --include=win32-$(GI_APIVERSION) --library=glib-2.0 --library=gobject-2.0 \
--external-library --reparse-validate --identifier-prefix=G --symbol-prefix=g \
--symbol-prefix=glib --c-include="glib.h" -I$(BASEDIR)\include\glib-$(GLIB_APIVERSION) \
@@ -96,17 +96,17 @@ GLib-$(GLIB_APIVERSION).gir: glib_list
GModule-$(GLIB_APIVERSION).gir: GLib-$(GLIB_APIVERSION).gir
@-echo Generating $@...
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --verbose -I.. --add-include-path=.. \
- --add-include-path=..\gir --add-include-path=. --namespace=GModule --nsversion=2.0 \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --verbose -I$(TOP_SRCDIR) --add-include-path=$(TOP_SRCDIR) \
+ --add-include-path=$(TOP_SRCDIR)\gir --add-include-path=. --namespace=GModule --nsversion=2.0 \
--no-libtool --include=GLib-$(GLIB_APIVERSION) --pkg=gmodule-$(GLIB_APIVERSION) --library=gmodule-2.0 \
--external-library --reparse-validate --identifier-prefix=G --c-include="gmodule.h" \
-I$(BASEDIR)\include\glib-2.0 -I$(BASEDIR)\lib\glib-2.0\include -I$(BASEDIR)\include \
- $(BASEDIR)\include\glib-2.0\gmodule.h ..\gir\gmodule-2.0.c -o $@
+ $(BASEDIR)\include\glib-2.0\gmodule.h $(TOP_SRCDIR)\gir\gmodule-2.0.c -o $@
GObject-$(GLIB_APIVERSION).gir: gobject_list GModule-$(GLIB_APIVERSION).gir
@-echo Generating $@...
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --verbose -I.. --add-include-path=.. \
- --add-include-path=..\gir --add-include-path=. --namespace=GObject --nsversion=$(GLIB_APIVERSION) \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --verbose -I$(TOP_SRCDIR) --add-include-path=$(TOP_SRCDIR) \
+ --add-include-path=$(TOP_SRCDIR)\gir --add-include-path=. --namespace=GObject --nsversion=$(GLIB_APIVERSION) \
--no-libtool --include=GLib-$(GLIB_APIVERSION) --pkg=gobject-$(GLIB_APIVERSION) --library=gobject-2.0 \
--external-library --reparse-validate --identifier-prefix=G --c-include="glib-gobject.h" \
-I$(BASEDIR)/include/glib-2.0 -I$(BASEDIR)/lib/glib-2.0/include -I$(BASEDIR)/include \
@@ -114,8 +114,8 @@ GObject-$(GLIB_APIVERSION).gir: gobject_list GModule-$(GLIB_APIVERSION).gir
Gio-$(GLIB_APIVERSION).gir: gio_list GObject-$(GLIB_APIVERSION).gir
@-echo Generating $@...
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --verbose -I.. --add-include-path=.. \
- --add-include-path=..\gir --add-include-path=. --namespace=Gio --nsversion=$(GLIB_APIVERSION) \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --verbose -I$(TOP_SRCDIR) --add-include-path=$(TOP_SRCDIR) \
+ --add-include-path=$(TOP_SRCDIR)\gir --add-include-path=. --namespace=Gio --nsversion=$(GLIB_APIVERSION) \
--no-libtool --pkg=gio-$(GLIB_APIVERSION) --pkg=gio-windows-$(GLIB_APIVERSION) --include=GObject-$(GLIB_APIVERSION) \
--library=gio-2.0 --external-library --reparse-validate --warn-all \
--identifier-prefix=G --include=GLib-$(GLIB_APIVERSION) --c-include="gio/gio.h" -DGIO_COMPILATION \
@@ -124,23 +124,23 @@ Gio-$(GLIB_APIVERSION).gir: gio_list GObject-$(GLIB_APIVERSION).gir
GIRepository-$(GLIB_APIVERSION).gir: gi_list GObject-$(GLIB_APIVERSION).gir
@-echo Generating $@...
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --verbose --warn-all \
- --add-include-path=..\gir --add-include-path=. --namespace=GIRepository --nsversion=$(GLIB_APIVERSION) \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --verbose --warn-all \
+ --add-include-path=$(TOP_SRCDIR)\gir --add-include-path=. --namespace=GIRepository --nsversion=$(GLIB_APIVERSION) \
--identifier-prefix=GI --symbol-prefix=g --c-include="girepository.h" --add-include-path=. \
--no-libtool --pkg=gobject-$(GLIB_APIVERSION) --include=GObject-$(GLIB_APIVERSION) \
- --library=girepository-1.0 -I..\girepository -I.. -I$(BASEDIR)\include \
+ --library=girepository-1.0 -I$(TOP_SRCDIR)\girepository -I$(TOP_SRCDIR) -I$(BASEDIR)\include \
-I$(BASEDIR)\include\glib-2.0 -I$(BASEDIR)\lib\glib-2.0\include --filelist=gi_list \
-DGI_COMPILATION -o $@
# Bundled cairo-1.0.gir.in processing
-cairo-1.0.gir: ..\gir\cairo-1.0.gir.in
+cairo-1.0.gir: $(TOP_SRCDIR)\gir\cairo-1.0.gir.in
@-echo Generating $@ from $*.gir.in...
- @-$(PYTHON2) gen-win32-cairo-gir.py --dllname=$(CAIROGOBJECT_DLLNAME)
+ @-$(PYTHON) gen-win32-cairo-gir.py --dllname=$(CAIROGOBJECT_DLLNAME)
# Copy the .gir's bundled with G-I to this folder
-$(bundled_girs): ..\gir\win32-1.0.gir ..\gir\fontconfig-2.0.gir ..\gir\freetype2-2.0.gir ..\gir\GL-1.0.gir ..\gir\libxml2-2.0.gir
+$(bundled_girs): $(TOP_SRCDIR)\gir\win32-1.0.gir $(TOP_SRCDIR)\gir\fontconfig-2.0.gir $(TOP_SRCDIR)\gir\freetype2-2.0.gir $(TOP_SRCDIR)\gir\GL-1.0.gir $(TOP_SRCDIR)\gir\libxml2-2.0.gir
@-echo Copying the bundled $*.gir that came with the GobjectIntrospection package...
- @-copy ..\gir\$*.gir $@
+ @-copy $(TOP_SRCDIR)\gir\$*.gir $@
# Generate .typelib's from generated .gir's
$(built_install_typelibs): $(bundled_girs) $(built_install_girs)
@@ -166,7 +166,7 @@ msg_cairo:
@-echo CAIROGOBJECT_DLLNAME^=^<your DLL full filename^> when
@-echo invoking this NMake Makefile
-install-introspection: setgirbuildnev $(built_install_girs) $(built_install_typelibs) $(bundled_girs) cairo-1.0.gir $(bundled_typelibs)
+install-introspection: all
@-mkdir $(G_IR_INCLUDEDIR)
@-mkdir $(G_IR_TYPELIBDIR)
@-copy cairo-1.0.gir $(G_IR_INCLUDEDIR)
diff --git a/build/gi-setenv-msvc.mak b/build/win32/gi-setenv-msvc.mak
index 6ebd966a..41c5e2c9 100644
--- a/build/gi-setenv-msvc.mak
+++ b/build/win32/gi-setenv-msvc.mak
@@ -3,11 +3,10 @@
# Please do not change anything after this line
-setgirbuildnev:
- @set CC=$(CC)
- @set UNINSTALLED_INTROSPECTION_SRCDIR=..
- @set UNINSTALLED_INTROSPECTION_BUILDDIR=..
- @set PYTHONPATH=..;$(BINDIR)
+setgirbuildenv:
+ @set UNINSTALLED_INTROSPECTION_SRCDIR=..\..
+ @set UNINSTALLED_INTROSPECTION_BUILDDIR=..\..
+ @set PYTHONPATH=..\..;$(BINDIR)
@set PATH=$(BINDIR);$(BASEDIR)\bin;$(PATH)
@set PKG_CONFIG_PATH=$(PKG_CONFIG_PATH)
@set LIB=win32\vs$(VSVER)\$(CFG)\$(PLAT)\bin;$(BASEDIR)\lib;$(LIB)
diff --git a/build/gi-tests-msvc.mak b/build/win32/gi-tests-msvc.mak
index f44b3bc0..caff3fb9 100644
--- a/build/gi-tests-msvc.mak
+++ b/build/win32/gi-tests-msvc.mak
@@ -5,7 +5,7 @@
!include gi-build-common-msvc.mak
BASE_GLIB_LIBS = gio-$(GLIB_APIVERSION).lib gobject-$(GLIB_APIVERSION).lib gmodule-$(GLIB_APIVERSION).lib glib-$(GLIB_APIVERSION).lib
-CFLAGS = $(CFLAGS_ADD) /I.. /W3 /we4013 /FImsvc_recommended_pragmas.h /DHAVE_CONFIG_H
+CFLAGS = $(CFLAGS_ADD) /I$(TOP_SRCDIR) /W3 /we4013 /FImsvc_recommended_pragmas.h /DHAVE_CONFIG_H
LDFLAGS = /link $(LDFLAGS_ARCH) $(BASE_GLIB_LIBS)
LDFLAGS_DLL = /link $(LDFLAGS_ARCH) /DLL /out:$@ /implib:$*-$(GI_APIVERSION).lib $(BASE_GLIB_LIBS)
@@ -56,48 +56,48 @@ built_doc_tests = \
Regress-$(GI_APIVERSION)-sections.txt
!if "$(BUILD_INTROSPECTION)" == "TRUE"
-all: setgirbuildnev $(built_test_girs) $(built_test_typelibs) $(test_programs) $(built_doc_tests) warn_tests_log.txt
+all: setgirbuildenv $(built_test_girs) $(built_test_typelibs) $(test_programs) $(built_doc_tests) warn_tests_log.txt
!include gi-setenv-msvc.mak
# Rules for building the test DLLs
-gimarshallingtests.dll: ..\tests\gimarshallingtests.c
- $(CC) $(CFLAGS) ..\tests\gimarshallingtests.c $(LDFLAGS_DLL)
+gimarshallingtests.dll: $(TOP_SRCDIR)\tests\gimarshallingtests.c
+ $(CC) $(CFLAGS) $(TOP_SRCDIR)\tests\gimarshallingtests.c $(LDFLAGS_DLL)
@-if exist $@.manifest @mt /manifest $@.manifest /outputresource:$@;2
everything.dll: everything.c everything.h
- $(CC) $(CFLAGS) /I..\tests everything.c $(LDFLAGS_DLL)
+ $(CC) $(CFLAGS) /I$(TOP_SRCDIR)\tests everything.c $(LDFLAGS_DLL)
@-if exist $@.manifest @mt /manifest $@.manifest /outputresource:$@;2
-offsets.dll: ..\tests\offsets\offsets.c
- $(CC) $(CFLAGS) /I..\tests /I..\tests\offsets ..\tests\offsets\offsets.c $(LDFLAGS_DLL)
+offsets.dll: $(TOP_SRCDIR)\tests\offsets\offsets.c
+ $(CC) $(CFLAGS) /I$(TOP_SRCDIR)\tests /I$(TOP_SRCDIR)\tests\offsets $(TOP_SRCDIR)\tests\offsets\offsets.c $(LDFLAGS_DLL)
@-if exist $@.manifest @mt /manifest $@.manifest /outputresource:$@;2
sletter.dll utility.dll gtkfrob.dll gettype.dll warnlib.dll typedefs.dll:
- $(CC) $(CFLAGS) /I..\tests ..\tests\scanner\$*.c $(LDFLAGS_DLL)
+ $(CC) $(CFLAGS) /I$(TOP_SRCDIR)\tests $(TOP_SRCDIR)\tests\scanner\$*.c $(LDFLAGS_DLL)
@-if exist $@.manifest @mt /manifest $@.manifest /outputresource:$@;2
regress.dll:
- $(CC) $(CFLAGS) /I..\tests \
+ $(CC) $(CFLAGS) /I$(TOP_SRCDIR)\tests \
$(REGRESS_CFLAGS) \
- ..\tests\scanner\regress.c \
- ..\tests\scanner\annotation.c \
- ..\tests\scanner\foo.c \
- ..\tests\scanner\drawable.c \
+ $(TOP_SRCDIR)\tests\scanner\regress.c \
+ $(TOP_SRCDIR)\tests\scanner\annotation.c \
+ $(TOP_SRCDIR)\tests\scanner\foo.c \
+ $(TOP_SRCDIR)\tests\scanner\drawable.c \
$(LDFLAGS_DLL) cairo-gobject.lib cairo.lib
@-if exist $@.manifest @mt /manifest $@.manifest /outputresource:$@;2
# Rules for test programs
gitestrepo.exe gitestthrows.exe gitypelibtest.exe:
- $(CC) $(CFLAGS) /I..\girepository ..\tests\repository\$*.c $(LDFLAGS) girepository-$(GI_APIVERSION).lib
+ $(CC) $(CFLAGS) /I$(TOP_SRCDIR)\girepository $(TOP_SRCDIR)\tests\repository\$*.c $(LDFLAGS) girepository-$(GI_APIVERSION).lib
@-if exist $@.manifest @mt /manifest $@.manifest /outputresource:$@;1
barapp.exe:
- $(CC) $(CFLAGS) /I..\girepository -I..\tests ..\tests\scanner\$*.c $(LDFLAGS) girepository-$(GI_APIVERSION).lib
+ $(CC) $(CFLAGS) /I$(TOP_SRCDIR)\girepository -I$(TOP_SRCDIR)\tests $(TOP_SRCDIR)\tests\scanner\$*.c $(LDFLAGS) girepository-$(GI_APIVERSION).lib
@-if exist $@.manifest @mt /manifest $@.manifest /outputresource:$@;1
gitestoffsets.exe: gitestoffsets.c
- $(CC) $(CFLAGS) /I..\girepository /I..\tests\offsets /I..\tests $*.c $(LDFLAGS) girepository-$(GI_APIVERSION).lib
+ $(CC) $(CFLAGS) /I$(TOP_SRCDIR)\girepository /I$(TOP_SRCDIR)\tests\offsets /I$(TOP_SRCDIR)\tests $*.c $(LDFLAGS) girepository-$(GI_APIVERSION).lib
@-if exist $@.manifest @mt /manifest $@.manifest /outputresource:$@;1
@set GI_TYPELIB_PATH=.
@-$@ offsets.compiled offsets.introspected
@@ -105,155 +105,154 @@ gitestoffsets.exe: gitestoffsets.c
# Rules for building the .gir's
GIMarshallingTests-$(GI_APIVERSION).gir: gimarshallingtests.dll
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all --warn-error --reparse-validate \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all --warn-error --reparse-validate \
--namespace=GIMarshallingTests --symbol-prefix=gi_marshalling_tests --nsversion=$(GI_APIVERSION) \
- --no-libtool -I.. \
+ --no-libtool -I$(TOP_SRCDIR) \
--add-include-path=. --include=Gio-$(GLIB_APIVERSION) \
--library=$* --output=$@ \
--c-include="tests/gimarshallingtests.h" \
- ..\tests\gimarshallingtests.h ..\tests\gimarshallingtests.c
+ $(TOP_SRCDIR)\tests\gimarshallingtests.h $(TOP_SRCDIR)\tests\gimarshallingtests.c
Everything-$(GI_APIVERSION).gir: everything.dll
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all --warn-error --reparse-validate \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all --warn-error --reparse-validate \
--namespace=Everything --nsversion=$(GI_APIVERSION) \
- --no-libtool -I.. -I..\tests \
+ --no-libtool -I$(TOP_SRCDIR) -I$(TOP_SRCDIR)\tests \
--add-include-path=. --include=Gio-$(GLIB_APIVERSION) \
--library=$* --output=$@ \
everything.h everything.c
Offsets-$(GI_APIVERSION).gir: offsets.dll
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all --warn-error --reparse-validate \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all --warn-error --reparse-validate \
--namespace=Offsets --nsversion=$(GI_APIVERSION) \
- --no-libtool -I.. -I..\tests\offsets -I..\tests \
+ --no-libtool -I$(TOP_SRCDIR) -I$(TOP_SRCDIR)\tests\offsets -I$(TOP_SRCDIR)\tests \
--pkg=gobject-$(GLIB_APIVERSION) --add-include-path=. --include=GObject-$(GLIB_APIVERSION) \
--library=$* --output=$@ \
- ..\tests\offsets\offsets.h ..\tests\offsets\offsets.c
+ $(TOP_SRCDIR)\tests\offsets\offsets.h $(TOP_SRCDIR)\tests\offsets\offsets.c
SLetter-$(GI_APIVERSION).gir: sletter.dll
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
--namespace=SLetter --nsversion=$(GI_APIVERSION) \
- --no-libtool -I..\tests -I.. \
+ --no-libtool -I$(TOP_SRCDIR)\tests -I$(TOP_SRCDIR) \
--add-include-path=. --include=Gio-$(GLIB_APIVERSION) \
--identifier-prefix=S --c-include="sletter.h" --warn-error \
--library=$* --output=$@ \
- ..\tests\scanner\sletter.h ..\tests\scanner\sletter.c
+ $(TOP_SRCDIR)\tests\scanner\sletter.h $(TOP_SRCDIR)\tests\scanner\sletter.c
Utility-$(GI_APIVERSION).gir: utility.dll
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
--namespace=Utility --nsversion=$(GI_APIVERSION) \
- --no-libtool -I..\tests -I.. --pkg=gobject-$(GLIB_APIVERSION) \
+ --no-libtool -I$(TOP_SRCDIR)\tests -I$(TOP_SRCDIR) --pkg=gobject-$(GLIB_APIVERSION) \
--add-include-path=. --include=GObject-$(GLIB_APIVERSION) \
--c-include="utility.h" --warn-error \
--library=$* --output=$@ \
- ..\tests\scanner\utility.h ..\tests\scanner\utility.c
+ $(TOP_SRCDIR)\tests\scanner\utility.h $(TOP_SRCDIR)\tests\scanner\utility.c
GtkFrob-$(GI_APIVERSION).gir: gtkfrob.dll
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
--namespace=GtkFrob --nsversion=$(GI_APIVERSION) \
- --no-libtool -I..\tests -I.. --pkg=gobject-$(GLIB_APIVERSION) \
+ --no-libtool -I$(TOP_SRCDIR)\tests -I$(TOP_SRCDIR) --pkg=gobject-$(GLIB_APIVERSION) \
--add-include-path=. --include=GObject-$(GLIB_APIVERSION) \
--identifier-prefix=Gtk --symbol-prefix=gtk_frob --warn-error \
--library=$* --output=$@ \
- ..\tests\scanner\gtkfrob.h ..\tests\scanner\gtkfrob.c
+ $(TOP_SRCDIR)\tests\scanner\gtkfrob.h $(TOP_SRCDIR)\tests\scanner\gtkfrob.c
GetType-$(GI_APIVERSION).gir: gettype.dll
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
--namespace=GetType --nsversion=$(GI_APIVERSION) \
- --no-libtool -I..\tests -I.. --pkg=gobject-$(GLIB_APIVERSION) \
+ --no-libtool -I$(TOP_SRCDIR)\tests -I$(TOP_SRCDIR) --pkg=gobject-$(GLIB_APIVERSION) \
--add-include-path=. --include=GObject-$(GLIB_APIVERSION) \
--c-include="gettype.h" --identifier-prefix=GetType --symbol-prefix=gettype \
--library=$* --output=$@ \
- ..\tests\scanner\gettype.h ..\tests\scanner\gettype.c
+ $(TOP_SRCDIR)\tests\scanner\gettype.h $(TOP_SRCDIR)\tests\scanner\gettype.c
Typedefs-$(GI_APIVERSION).gir: typedefs.dll
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
--namespace=Typedefs --nsversion=$(GI_APIVERSION) \
- --no-libtool -I..\tests -I.. --pkg=gobject-$(GLIB_APIVERSION) \
+ --no-libtool -I$(TOP_SRCDIR)\tests -I$(TOP_SRCDIR) --pkg=gobject-$(GLIB_APIVERSION) \
--add-include-path=. --include=GObject-$(GLIB_APIVERSION) \
--c-include="typedefs.h" --identifier-prefix=Typedefs --symbol-prefix=typedefs \
--library=$* --output=$@ \
- ..\tests\scanner\typedefs.h ..\tests\scanner\typedefs.c
+ $(TOP_SRCDIR)\tests\scanner\typedefs.h $(TOP_SRCDIR)\tests\scanner\typedefs.c
WarnLib-$(GI_APIVERSION).gir: warnlib.dll
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
--namespace=WarnLib --nsversion=$(GI_APIVERSION) \
- --no-libtool -I..\tests -I.. \
+ --no-libtool -I$(TOP_SRCDIR)\tests -I$(TOP_SRCDIR) \
--add-include-path=. --include=Gio-$(GLIB_APIVERSION) \
--c-include="warnlib.h" --symbol-prefix=warnlib_ \
--library=$* --output=$@ \
- ..\tests\scanner\warnlib.h ..\tests\scanner\warnlib.c
+ $(TOP_SRCDIR)\tests\scanner\warnlib.h $(TOP_SRCDIR)\tests\scanner\warnlib.c
Regress-$(GI_APIVERSION).gir: Utility-$(GI_APIVERSION).gir regress.dll
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all \
--namespace=Regress --nsversion=$(GI_APIVERSION) \
- --no-libtool -I..\tests -I.. \
+ --no-libtool -I$(TOP_SRCDIR)\tests -I$(TOP_SRCDIR) \
--add-include-path=. --include=Gio-$(GLIB_APIVERSION) \
--include=Utility-$(GI_APIVERSION) --include=cairo-$(GI_APIVERSION) \
--c-include="regress.h" --warn-error \
--library=$* --output=$@ \
$(REGRESS_CFLAGS) \
- ..\tests\scanner\regress.c ..\tests\scanner\regress.h \
- ..\tests\scanner\annotation.c ..\tests\scanner\annotation.h \
- ..\tests\scanner\foo.c ..\tests\scanner\foo.h \
- ..\tests\scanner\drawable.c ..\tests\scanner\drawable.h
+ $(TOP_SRCDIR)\tests\scanner\regress.c $(TOP_SRCDIR)\tests\scanner\regress.h \
+ $(TOP_SRCDIR)\tests\scanner\annotation.c $(TOP_SRCDIR)\tests\scanner\annotation.h \
+ $(TOP_SRCDIR)\tests\scanner\foo.c $(TOP_SRCDIR)\tests\scanner\foo.h \
+ $(TOP_SRCDIR)\tests\scanner\drawable.c $(TOP_SRCDIR)\tests\scanner\drawable.h
Bar-$(GI_APIVERSION).gir: Utility-$(GI_APIVERSION).gir barapp.exe
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all \
--namespace=Bar --nsversion=$(GI_APIVERSION) \
--program=barapp \
- --no-libtool -I..\tests -I.. --pkg=gobject-$(GLIB_APIVERSION) \
+ --no-libtool -I$(TOP_SRCDIR)\tests -I$(TOP_SRCDIR) --pkg=gobject-$(GLIB_APIVERSION) \
--add-include-path=. --include=GObject-$(GLIB_APIVERSION) \
--accept-unprefixed \
--output=$@ \
- ..\tests\scanner\barapp.c ..\tests\scanner\barapp.h
+ $(TOP_SRCDIR)\tests\scanner\barapp.c $(TOP_SRCDIR)\tests\scanner\barapp.h
Headeronly-$(GI_APIVERSION).gir:
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all \
--warn-error --reparse-validate --namespace=Headeronly --nsversion=$(GI_APIVERSION) \
- --header-only --output=$@ ..\tests\scanner\headeronly.h
+ --header-only --output=$@ $(TOP_SRCDIR)\tests\scanner\headeronly.h
Identfilter-$(GI_APIVERSION).gir:
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) --warn-all --reparse-validate \
--namespace=Identfilter --accept-unprefixed --nsversion=1.0 --header-only \
- --identifier-filter-cmd="$(PYTHON2) ..\tests\scanner\identfilter.py" \
- --output=$@ ..\tests\scanner\identfilter.h
+ --identifier-filter-cmd="$(PYTHON) $(TOP_SRCDIR)\tests\scanner\identfilter.py" \
+ --output=$@ $(TOP_SRCDIR)\tests\scanner\identfilter.h
# Rules for doc (Mallard) tests
Regress-$(GI_APIVERSION)-C: Regress-$(GI_APIVERSION).gir
@-if exist $@ @rmdir /s /q $@
- $(PYTHON2) $(G_IR_DOC_TOOL_CURRENT) --add-include-path=. --language C .\Regress-$(GI_APIVERSION).gir -o .\$@\
+ $(PYTHON) $(G_IR_DOC_TOOL_CURRENT) --add-include-path=. --language C .\Regress-$(GI_APIVERSION).gir -o .\$@\
Regress-$(GI_APIVERSION)-Python: Regress-$(GI_APIVERSION).gir
@-if exist $@ @rmdir /s /q $@
- $(PYTHON2) $(G_IR_DOC_TOOL_CURRENT) --add-include-path=. --language Python .\Regress-$(GI_APIVERSION).gir -o .\$@\
+ $(PYTHON) $(G_IR_DOC_TOOL_CURRENT) --add-include-path=. --language Python .\Regress-$(GI_APIVERSION).gir -o .\$@\
Regress-$(GI_APIVERSION)-Gjs: Regress-$(GI_APIVERSION).gir
@-if exist $@ @rmdir /s /q $@
- $(PYTHON2) $(G_IR_DOC_TOOL_CURRENT) --add-include-path=. --language Gjs .\Regress-$(GI_APIVERSION).gir -o .\$@\
+ $(PYTHON) $(G_IR_DOC_TOOL_CURRENT) --add-include-path=. --language Gjs .\Regress-$(GI_APIVERSION).gir -o .\$@\
Regress-$(GI_APIVERSION)-sections.txt: Regress-$(GI_APIVERSION).gir
- $(PYTHON2) $(G_IR_DOC_TOOL_CURRENT) --add-include-path=. --write-sections-file .\Regress-$(GI_APIVERSION).gir -o $@
+ $(PYTHON) $(G_IR_DOC_TOOL_CURRENT) --add-include-path=. --write-sections-file .\Regress-$(GI_APIVERSION).gir -o $@
# Run warn tests
warn_tests_log.txt:
@-echo Runinng warn tests...
- @-set TOP_BUILDDIR=..
- @-copy GObject-$(GLIB_APIVERSION).gir ..\gir
- @-copy GLib-$(GLIB_APIVERSION).gir ..\gir
- @-for %a in (..\tests\warn\*.h) do if not "%a" == "..\tests\warn\common.h" $(PYTHON2) ..\tests\warn\warningtester.py %a >> $@
- @-del ..\gir\GObject-$(GLIB_APIVERSION).gir
- @-del ..\gir\GLib-$(GLIB_APIVERSION).gir
+ @-copy GObject-$(GLIB_APIVERSION).gir $(TOP_SRCDIR)\gir
+ @-copy GLib-$(GLIB_APIVERSION).gir $(TOP_SRCDIR)\gir
+ @-for %a in ($(TOP_SRCDIR)\tests\warn\*.h) do if not "%a" == "$(TOP_SRCDIR)\tests\warn\common.h" $(PYTHON) $(TOP_SRCDIR)\tests\warn\warningtester.py %a >> $@
+ @-del $(TOP_SRCDIR)\gir\GObject-$(GLIB_APIVERSION).gir
+ @-del $(TOP_SRCDIR)\gir\GLib-$(GLIB_APIVERSION).gir
# Rules for source code generation
everything.c everything.h:
- $(PYTHON2) $(G_IR_SCANNER_CURRENT) -I.. \
+ $(PYTHON) $(G_IR_SCANNER_CURRENT) -I$(TOP_SRCDIR) \
--generate-typelib-tests=Everything,everything.h,everything.c \
--function-decoration=_GI_TEST_EXTERN \
--include-first-in-src=config.h \
--include-last-in-header=gitestmacros.h
gitestoffsets.c: Offsets-$(GI_APIVERSION).typelib
- $(PYTHON2) ..\tests\offsets\gen-gitestoffsets ..\tests\offsets\offsets.h > $@
+ $(PYTHON) $(TOP_SRCDIR)\tests\offsets\gen-gitestoffsets $(TOP_SRCDIR)\tests\offsets\offsets.h > $@
# Generate .typelib's from generated .gir's
$(built_test_typelibs): $(built_test_girs)
diff --git a/build/gi_msvc_build_utils.py b/build/win32/gi_msvc_build_utils.py
index 150f66ec..150f66ec 100644
--- a/build/gi_msvc_build_utils.py
+++ b/build/win32/gi_msvc_build_utils.py
diff --git a/build/introspection-msvc.mak b/build/win32/introspection-msvc.mak
index 8e363a4a..9862f715 100644
--- a/build/introspection-msvc.mak
+++ b/build/win32/introspection-msvc.mak
@@ -5,7 +5,23 @@
# You will need to have built gobject-introspection for this to work.
# Change or pass in or set the following to suit your environment
-BASEDIR = ..\..\vs$(VSVER)\$(PLAT)
+!if "$(BASEDIR)" == ""
+BASEDIR = ..\..\..\vs$(VSVER)\$(PLAT)
+!endif
+
+# Note: The PYTHON must be the Python release series that was used to build
+# the GObject-introspection scanner Python module!
+# Either having python.exe your PATH will work or passing in
+# PYTHON=<full path to your Python interpretor> will do
+
+# This is required, and gobject-introspection needs to be built
+# before this can be successfully run.
+!if "$(PYTHON)" == ""
+PYTHON=python
+!endif
+
+# Don't change anything following this line!
+
GIR_SUBDIR = share\gir-1.0
GIR_TYPELIBDIR = lib\girepository-1.0
G_IR_SCANNER = $(BASEDIR)\bin\g-ir-scanner
@@ -13,15 +29,6 @@ G_IR_COMPILER = $(BASEDIR)\bin\g-ir-compiler.exe
G_IR_INCLUDEDIR = $(BASEDIR)\$(GIR_SUBDIR)
G_IR_TYPELIBDIR = $(BASEDIR)\$(GIR_TYPELIBDIR)
-# Note: The PYTHON2 must be a Python 2.6.x or 2.7.x Interpretor!
-# Either having python.exe from Python 2.6.x/2.7.x in your PATH will work
-# or passing in PYTHON2=<full path to your Python 2.6.x/2.7.x interpretor> will do
-
-# This is required, and gobject-introspection needs to be built
-# before this can be successfully run.
-PYTHON2=python
-
-# Don't change anything following this line!
VALID_PKG_CONFIG_PATH = FALSE
MSG_INVALID_PKGCONFIG = You must set or specifiy a valid PKG_CONFIG_PATH
diff --git a/build/replace.py b/build/win32/replace.py
index 69ef417a..69ef417a 100644
--- a/build/replace.py
+++ b/build/win32/replace.py
diff --git a/build/win32/vs10/README.txt b/build/win32/vs10/README.txt
index f682fe3c..f2488db0 100644
--- a/build/win32/vs10/README.txt
+++ b/build/win32/vs10/README.txt
@@ -12,8 +12,9 @@ This VS10 solution and the projects it includes are intented to be used
in a gobject-introspection source tree unpacked from a tarball. In a git checkout you
first need to use some Unix-like environment, which will do the work for you.
-The required dependencies are Python 2.6 or later, GLib and LibFFI. It is recommended
-that GLib is built with Visual C++ 2010 to avoid problems cause by usage of different CRTs
+The required dependencies are Python 2.7 (2.7) or 3.3 (3.x) or later, GLib and LibFFI.
+It is recommended that GLib is built with Visual C++ 2010 to avoid problems cause by
+usage of different CRTs.
Please refer to the README.txt file in $(GLib_src_root)\build\win32\vs10 on how to build
GLib using Visual C++ 2010
@@ -24,9 +25,12 @@ comes with the LibFFI source package for more details on how to build LibFFI
on Visual C++-please note that the mozilla-build package from Mozilla is needed
in order to build LibFFI on Windows.
-For Python, retrieving the official Windows binaries for 2.6 or later from
-http://www.python.org will do the job-be sure that the Python version that
-you downloaded matches the configuration of your build (win32 or x64/amd64).
+For Python, retrieving the official Windows binaries for 2.7 (2.x) or 3.3 (3.x) or later
+from http://www.python.org will do the job-be sure that the Python version that
+you downloaded matches the configuration of your build (win32 or x64/amd64). Ensure that
+the correct path for your Python interpretor is set in gi-extra-paths.vsprops prior to
+opening the project files, or close the project files and delete all the *.user, *.sdf and
+*.suo files and reopening the project files.
For building the Regress test project, cairo (and possibly cairo-gobject support)
is needed.
@@ -68,13 +72,13 @@ variables, but the following environmental variables are needed (either by using
or by nmake -f gi-introspection-msvc.mak xxx=yyy) for building the introspection files (which
should be done after successfully building the Project Files):
-PYTHON2: Full path to your Python 2.6.x/2.7.x interpretor (python.exe) if it is
- not in your PATH. Please note that only 2.6.x and 2.7.x works at this time.
- You need to use an x64/amd64 version of Python for x64 builds, and a Win32/x86
- version of Python for Win32/x86 builds
+PYTHON: Full path to your Python 2.7.x/3.3.x+ interpretor (python.exe) if it is
+ not in your PATH. Please note that only 2.7.x and 3.3.x and later works.
+ You need to use an x64/amd64 version of Python for x64 builds, and a Win32/x86
+ version of Python for Win32/x86 builds
PKG_CONFIG_PATH: Location of the .pc (pkg-config) files, especially for the GLib .pc files.
-Please see $(srcroot)\build\gi-introspection-msvc.mak for more details. Doing
+Please see $(srcroot)\build\win32\gi-introspection-msvc.mak for more details. Doing
"nmake -f gi-introspection-msvc.mak (options omitted)" will build the various introspection files,
and "nmake -f gi-introspection-msvc.mak (options omitted) install-introspection" will copy the introspection
files to <root>\vs10\<PlatformName>\share\gir-1.0 (.gir files) and
diff --git a/build/win32/vs10/gi-extra-paths.props b/build/win32/vs10/gi-extra-paths.props
index 13819019..d4996471 100644
--- a/build/win32/vs10/gi-extra-paths.props
+++ b/build/win32/vs10/gi-extra-paths.props
@@ -4,9 +4,9 @@
<Import Project="gi-build-defines.props" />
</ImportGroup>
<PropertyGroup Label="UserMacros">
- <!-- PythonDir currently needs to point to a 32-bit/x86 Python 2.6/2.7 installation -->
- <PythonDir>c:\\python27</PythonDir>
- <!-- PythonDirX64 currently needs to point to an x86-64/x64 Python 2.6/2.7 installation -->
+ <!-- PythonDir needs to point to a 32-bit/x86 Python 2.7/3.3+ installation -->
+ <PythonDir>c:\\python34</PythonDir>
+ <!-- PythonDirX64 needs to point to an x86-64/x64 Python 2.7/3.3+ installation -->
<PythonDirX64>$(PythonDir).x64</PythonDirX64>
</PropertyGroup>
<PropertyGroup>
diff --git a/build/win32/vs10/gi-gen-srcs.props b/build/win32/vs10/gi-gen-srcs.props
index caaa2526..37a06c1d 100644
--- a/build/win32/vs10/gi-gen-srcs.props
+++ b/build/win32/vs10/gi-gen-srcs.props
@@ -5,8 +5,8 @@
</ImportGroup>
<PropertyGroup Label="UserMacros">
<CopyConfigH>copy ..\..\..\config.h.win32 ..\..\..\config.h</CopyConfigH>
- <GenToolsScripts>$(PythonDir)\python ..\..\..\build\gen-win32-g-ir-tools.py</GenToolsScripts>
- <GenToolsScriptsX64>$(PythonDirX64)\python ..\..\..\build\gen-win32-g-ir-tools.py</GenToolsScriptsX64>
+ <GenToolsScripts>$(PythonDir)\python ..\gen-win32-g-ir-tools.py</GenToolsScripts>
+ <GenToolsScriptsX64>$(PythonDirX64)\python ..\gen-win32-g-ir-tools.py</GenToolsScriptsX64>
</PropertyGroup>
<PropertyGroup>
<_PropertySheetDisplayName>gigensrcsprops</_PropertySheetDisplayName>
diff --git a/build/win32/vs10/gi-install.propsin b/build/win32/vs10/gi-install.propsin
index bf2c0b71..3a168dc9 100644
--- a/build/win32/vs10/gi-install.propsin
+++ b/build/win32/vs10/gi-install.propsin
@@ -5,8 +5,6 @@
</ImportGroup>
<PropertyGroup Label="UserMacros">
<BinDir>$(SolutionDir)$(Configuration)\$(Platform)\bin</BinDir>
- <InstalledDlls>$(BinDir)\$(LibGIDllPrefix)girepository$(LibGIDllSuffix).dll;$(BinDir)\_giscanner.pyd</InstalledDlls>
- <InstalledBins>$(BinDir)\g-ir-compiler.exe;$(BinDir)\g-ir-generate.exe;..\..\..\tools\g-ir-annotation-tool;..\..\..\tools\g-ir-doc-tool;..\..\..\tools\g-ir-scanner</InstalledBins>
<GIDoInstall>
mkdir $(CopyDir)
mkdir $(CopyDir)\bin
@@ -40,7 +38,7 @@ copy $(BinDir)\girepository-$(ApiVersion).lib $(CopyDir)\lib
echo Please note that building GObject-Introspection with Visual Studio is now a 2-step process
echo Please open the appropriate Visual Studio (or Windows SDK) command prompt and use the NMake Makefile
-echo in SRC_ROOT\build\gi-introspection-msvc.mak to build the introspection files
+echo in SRC_ROOT\build\win32\gi-introspection-msvc.mak to build the introspection files
</GIDoInstall>
</PropertyGroup>
<PropertyGroup>
@@ -50,12 +48,6 @@ echo in SRC_ROOT\build\gi-introspection-msvc.mak to build the introspection file
<BuildMacro Include="BinDir">
<Value>$(BinDir)</Value>
</BuildMacro>
- <BuildMacro Include="InstalledDlls">
- <Value>$(InstalledDlls)</Value>
- </BuildMacro>
- <BuildMacro Include="InstalledBins">
- <Value>$(InstalledBins)</Value>
- </BuildMacro>
<BuildMacro Include="GIDoInstall">
<Value>$(GIDoInstall)</Value>
</BuildMacro>
diff --git a/build/win32/vs10/gi-install.vcxproj b/build/win32/vs10/gi-install.vcxproj
index 808acd46..fbb757f9 100644
--- a/build/win32/vs10/gi-install.vcxproj
+++ b/build/win32/vs10/gi-install.vcxproj
@@ -88,16 +88,16 @@
<CustomBuild Include="..\..\..\config.h.win32">
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Installing Build Results...</Message>
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(GIDoInstall)</Command>
- <Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(InstalledDlls);$(InstalledBins);%(Outputs)</Outputs>
+ <Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">some_random_file;%(Outputs)</Outputs>
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Installing Build Results...</Message>
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(GIDoInstall)</Command>
- <Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(InstalledDlls);$(InstalledBins);%(Outputs)</Outputs>
+ <Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">some_random_file;%(Outputs)</Outputs>
<Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Installing Build Results...</Message>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(GIDoInstall)</Command>
- <Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(InstalledDlls);$(InstalledBins);%(Outputs)</Outputs>
+ <Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">some_random_file;%(Outputs)</Outputs>
<Message Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Installing Build Results...</Message>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(GIDoInstall)</Command>
- <Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(InstalledDlls);$(InstalledBins);%(Outputs)</Outputs>
+ <Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">some_random_file;%(Outputs)</Outputs>
</CustomBuild>
</ItemGroup>
<ItemGroup>
@@ -121,4 +121,4 @@
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
-</Project> \ No newline at end of file
+</Project>
diff --git a/build/win32/vs9/README.txt b/build/win32/vs9/README.txt
index 2aa7891e..85e17a8d 100644
--- a/build/win32/vs9/README.txt
+++ b/build/win32/vs9/README.txt
@@ -12,8 +12,9 @@ This VS9 solution and the projects it includes are intented to be used
in a gobject-introspection source tree unpacked from a tarball. In a git checkout you
first need to use some Unix-like environment, which will do the work for you.
-The required dependencies are Python 2.6 or later, GLib and LibFFI. It is recommended
-that GLib is built with Visual C++ 2008 to avoid problems cause by usage of different CRTs
+The required dependencies are Python 2.7 (2.7) or 3.3 (3.x) or later, GLib and LibFFI.
+It is recommended that GLib is built with Visual C++ 2008 to avoid problems cause by
+usage of different CRTs.
Please refer to the README.txt file in $(GLib_src_root)\build\win32\vs9 on how to build
GLib using Visual C++ 2008
@@ -24,9 +25,12 @@ comes with the LibFFI source package for more details on how to build LibFFI
on Visual C++-please note that the mozilla-build package from Mozilla is needed
in order to build LibFFI on Windows.
-For Python, retrieving the official Windows binaries for 2.6 or later from
-http://www.python.org will do the job-be sure that the Python version that
-you downloaded matches the configuration of your build (win32 or x64/amd64).
+For Python, retrieving the official Windows binaries for 2.7 (2.x) or 3.3 (3.x) or later
+from http://www.python.org will do the job-be sure that the Python version that
+you downloaded matches the configuration of your build (win32 or x64/amd64). Ensure that
+the correct path for your Python interpretor is set in gi-extra-paths.vsprops prior to
+opening the project files, or close the project files and delete all the *.user, *.ncb and
+*.suo files and reopening the project files.
For building the Regress test project, cairo (and possibly cairo-gobject support)
is needed.
@@ -68,13 +72,13 @@ variables, but the following environmental variables are needed (either by using
or by nmake -f gi-introspection-msvc.mak xxx=yyy) for building the introspection files (which
should be done after successfully building the Project Files):
-PYTHON2: Full path to your Python 2.6.x/2.7.x interpretor (python.exe) if it is
- not in your PATH. Please note that only 2.6.x and 2.7.x works at this time.
- You need to use an x64/amd64 version of Python for x64 builds, and a Win32/x86
- version of Python for Win32/x86 builds
+PYTHON: Full path to your Python 2.7.x/3.3.x+ interpretor (python.exe) if it is
+ not in your PATH. Please note that only 2.7.x and 3.3.x and later works.
+ You need to use an x64/amd64 version of Python for x64 builds, and a Win32/x86
+ version of Python for Win32/x86 builds
PKG_CONFIG_PATH: Location of the .pc (pkg-config) files, especially for the GLib .pc files.
-Please see $(srcroot)\build\gi-introspection-msvc.mak for more details. Doing
+Please see $(srcroot)\build\win32\gi-introspection-msvc.mak for more details. Doing
"nmake -f gi-introspection-msvc.mak (options omitted)" will build the various introspection files,
and "nmake -f gi-introspection-msvc.mak (options omitted) install-introspection" will copy the introspection
files to <root>\vs9\<PlatformName>\share\gir-1.0 (.gir files) and <root>\vs9\<PlatformName>\lib\girepository-1.0
diff --git a/build/win32/vs9/gi-extra-paths.vsprops b/build/win32/vs9/gi-extra-paths.vsprops
index 989b4994..ba7c4a6e 100644
--- a/build/win32/vs9/gi-extra-paths.vsprops
+++ b/build/win32/vs9/gi-extra-paths.vsprops
@@ -5,12 +5,12 @@
Name="giextrapaths"
InheritedPropertySheets=".\gi-build-defines.vsprops"
>
- <!-- PythonDir currently needs to point to a 32-bit/x86 Python 2.6/2.7 installation -->
+ <!-- PythonDir needs to point to a 32-bit/x86 Python 2.7/3.3+ installation -->
<UserMacro
Name="PythonDir"
Value="c:\\python27"
/>
- <!-- PythonDirX64 currently needs to point to an x86-64/x64 Python 2.6/2.7 installation -->
+ <!-- PythonDirX64 needs to point to an x86-64/x64 Python 2.7/3.3+ installation -->
<UserMacro
Name="PythonDirX64"
Value="$(PythonDir).x64"
diff --git a/build/win32/vs9/gi-gen-srcs.vsprops b/build/win32/vs9/gi-gen-srcs.vsprops
index b3a68eb6..cd83b45a 100644
--- a/build/win32/vs9/gi-gen-srcs.vsprops
+++ b/build/win32/vs9/gi-gen-srcs.vsprops
@@ -7,16 +7,14 @@
>
<UserMacro
Name="CopyConfigH"
- Value="
-copy ..\..\..\config.h.win32 ..\..\..\config.h
- "
+ Value="copy ..\..\..\config.h.win32 ..\..\..\config.h"
/>
<UserMacro
Name="GenToolsScripts"
- Value="$(PythonDir)\python ..\..\..\build\gen-win32-g-ir-tools.py"
+ Value="$(PythonDir)\python ..\gen-win32-g-ir-tools.py"
/>
<UserMacro
Name="GenToolsScriptsX64"
- Value="$(PythonDirX64)\python ..\..\..\build\gen-win32-g-ir-tools.py"
+ Value="$(PythonDirX64)\python ..\gen-win32-g-ir-tools.py"
/>
</VisualStudioPropertySheet>
diff --git a/build/win32/vs9/gi-install.vspropsin b/build/win32/vs9/gi-install.vspropsin
index f47937a3..b1d279a2 100644
--- a/build/win32/vs9/gi-install.vspropsin
+++ b/build/win32/vs9/gi-install.vspropsin
@@ -43,7 +43,7 @@ copy $(SolutionDir)$(ConfigurationName)\$(PlatformName)\bin\girepository-$(ApiVe
echo Please note that building GObject-Introspection with Visual Studio is now a 2-step process&#x0D;&#x0A;
echo Please open the appropriate Visual Studio (or Windows SDK) command prompt and use the NMake Makefile&#x0D;&#x0A;
-echo in SRC_ROOT\build\gi-introspection-msvc.mak to build the introspection files&#x0D;&#x0A;
+echo in SRC_ROOT\build\win32\gi-introspection-msvc.mak to build the introspection files&#x0D;&#x0A;
"
/>
</VisualStudioPropertySheet>