CWS-TOOLING: integrate CWS mingwport19
2009-04-23 16:09:03 +0200 tono r271180 : revert changes 2009-04-20 15:15:31 +0200 tono r270988 : i101223: MinGW port: atl patch fix 2009-04-14 14:54:29 +0200 tono r270779 : i101077: mingw port: make python to work with OOo 2009-04-14 14:52:46 +0200 tono r270777 : i101073: Mingw port fix: openssl 0.9.8k in cygwin case
This commit is contained in:
@@ -51,8 +51,12 @@ DESTROOT=$(BIN)$/$(PYDIRNAME)
|
||||
.IF "$(GUI)" == "UNX"
|
||||
PYTHONBINARY=$(BIN)$/python$(EXECPOST).bin
|
||||
.ELSE
|
||||
.IF "$(COM)" == "GCC"
|
||||
PYTHONBINARY=$(DESTROOT)$/bin$/python.bin
|
||||
.ELSE
|
||||
PYTHONBINARY=$(DESTROOT)$/bin$/python$(EXECPOST)
|
||||
.ENDIF
|
||||
.ENDIF
|
||||
|
||||
FINDLIBFILES_TMP:=$(subst,/,$/ \
|
||||
$(shell @$(FIND) $(SOLARLIBDIR)$/python -type f| $(GREP) -v .pyc |$(GREP) -v .py\~ |$(GREP) -v .orig ))
|
||||
@@ -114,7 +118,11 @@ $(BIN)$/python$(EXECPOST).bin : $(SOLARBINDIR)$/python$(EXECPOST)
|
||||
.ENDIF
|
||||
chmod +x $@
|
||||
.ELSE
|
||||
.IF "$(COM)" == "GCC"
|
||||
$(DESTROOT)$/bin$/python.bin : $(SOLARBINDIR)$/python$(EXECPOST)
|
||||
.ELSE
|
||||
$(DESTROOT)$/bin$/python$(EXECPOST) : $(SOLARBINDIR)$/python$(EXECPOST)
|
||||
.ENDIF
|
||||
-$(MKDIRHIER) $(@:d)
|
||||
-rm -f $@
|
||||
cat $< > $@
|
||||
|
@@ -133,6 +133,22 @@ int wmain(int argc, wchar_t ** argv, wchar_t **) {
|
||||
if (pythonpath3End == NULL) {
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
#ifdef __MINGW32__
|
||||
wchar_t pythonpath4[MAX_PATH];
|
||||
wchar_t * pythonpath4End = tools::buildPath(
|
||||
pythonpath4, path, pathEnd,
|
||||
MY_STRING(L"\\program\\python-core-" MY_PYVERSION L"\\lib\\lib-dynload"));
|
||||
if (pythonpath4End == NULL) {
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
wchar_t pythonpath5[MAX_PATH];
|
||||
wchar_t * pythonpath5End = tools::buildPath(
|
||||
pythonpath5, path, pathEnd,
|
||||
MY_STRING(L"\\program\\python-core-" MY_PYVERSION L"\\lib\\lib-dynload"));
|
||||
if (pythonpath5End == NULL) {
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
#endif
|
||||
wchar_t pythonhome[MAX_PATH];
|
||||
wchar_t * pythonhomeEnd = tools::buildPath(
|
||||
pythonhome, path, pathEnd,
|
||||
@@ -143,8 +159,13 @@ int wmain(int argc, wchar_t ** argv, wchar_t **) {
|
||||
wchar_t pythonexe[MAX_PATH];
|
||||
wchar_t * pythonexeEnd = tools::buildPath(
|
||||
pythonexe, path, pathEnd,
|
||||
#ifdef __MINGW32__
|
||||
MY_STRING(
|
||||
L"\\program\\python-core-" MY_PYVERSION L"\\bin\\python.bin"));
|
||||
#else
|
||||
MY_STRING(
|
||||
L"\\program\\python-core-" MY_PYVERSION L"\\bin\\python.exe"));
|
||||
#endif
|
||||
if (pythonexeEnd == NULL) {
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
@@ -231,6 +252,18 @@ int wmain(int argc, wchar_t ** argv, wchar_t **) {
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
}
|
||||
#ifdef __MINGW32__
|
||||
value = new wchar_t[
|
||||
(path1End - path1) + MY_LENGTH(L";") + (pythonpath2End - pythonpath2) +
|
||||
MY_LENGTH(L";") + (pythonpath4End - pythonpath4) +
|
||||
MY_LENGTH(L";") + (pythonpath5End - pythonpath5) +
|
||||
MY_LENGTH(L";") + (pythonpath3End - pythonpath3) +
|
||||
(n == 0 ? 0 : MY_LENGTH(L";") + (n - 1)) + 1]; //TODO: overflow
|
||||
wsprintfW(
|
||||
value, L"%s;%s;%s;%s;%s%s%s", path1, pythonpath2, pythonpath4,
|
||||
pythonpath5, pythonpath3,
|
||||
n == 0 ? L"" : L";", orig);
|
||||
#else
|
||||
value = new wchar_t[
|
||||
(path1End - path1) + MY_LENGTH(L";") + (pythonpath2End - pythonpath2) +
|
||||
MY_LENGTH(L";") + (pythonpath3End - pythonpath3) +
|
||||
@@ -238,6 +271,7 @@ int wmain(int argc, wchar_t ** argv, wchar_t **) {
|
||||
wsprintfW(
|
||||
value, L"%s;%s;%s%s%s", path1, pythonpath2, pythonpath3,
|
||||
n == 0 ? L"" : L";", orig);
|
||||
#endif
|
||||
if (!SetEnvironmentVariableW(L"PYTHONPATH", value)) {
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
Reference in New Issue
Block a user