diff options
author | Jose <jose@zeroc.com> | 2016-07-01 22:06:44 +0200 |
---|---|---|
committer | Jose <jose@zeroc.com> | 2016-07-01 22:06:44 +0200 |
commit | f46cc14601a5ac724bed901f03bc547bdb41cb60 (patch) | |
tree | f6048cf559b4124ce34bf6650b93144791f94d32 /scripts/TestUtil.py | |
parent | Fixed ICE-7210 - Added IceSSL dependency when building tests (diff) | |
parent | OpenSSL-1.1.0-pre5 support (diff) | |
download | ice-f46cc14601a5ac724bed901f03bc547bdb41cb60.tar.bz2 ice-f46cc14601a5ac724bed901f03bc547bdb41cb60.tar.xz ice-f46cc14601a5ac724bed901f03bc547bdb41cb60.zip |
Merge remote-tracking branch 'origin/3.6'
Conflicts:
config/Make.common.rules
cpp/Makefile
cpp/config/Make.rules
cpp/config/Make.rules.Linux
cpp/src/Ice/InstrumentationI.cpp
cpp/src/Ice/PropertyNames.cpp
cpp/src/Ice/PropertyNames.h
cpp/src/IceSSL/Makefile
cpp/src/IceUtil/Makefile
cpp/test/Glacier2/attack/Makefile
cpp/test/Glacier2/attack/Makefile.mak
cpp/test/Glacier2/router/Makefile
cpp/test/Glacier2/sessionHelper/Makefile
cpp/test/Glacier2/staticFiltering/Makefile
cpp/test/Ice/objects/Makefile
cpp/test/IceSSL/configuration/AllTests.cpp
cpp/test/IceUtil/stacktrace/StackTrace.debug.Linux
cpp/test/IceUtil/stacktrace/StackTrace.release.Linux
csharp/src/Ice/PropertyNames.cs
java/Makefile
java/gradle.properties
java/gradle/ice.gradle
java/src/Ice/src/main/java/IceInternal/PropertyNames.java
java/test/build.gradle
js/src/Ice/PropertyNames.js
man/man1/icegridadmin.1
man/man1/transformdb.1
php/BuildInstructionsWindows.md
php/Makefile
php/config/Make.rules.Darwin
php/config/Make.rules.mak.php
php/config/Make.rules.php
php/src/IcePHP/Makefile
php/src/Makefile
php/src/Makefile.mak
php/src/php5/.depend.mak
php/src/php5/Communicator.cpp
php/src/php5/Config.h
php/src/php5/Connection.cpp
php/src/php5/Endpoint.cpp
php/src/php5/IcePHP.rc
php/src/php5/Makefile
php/src/php5/Makefile.mak
php/src/php5/Operation.cpp
php/src/php5/Types.cpp
php/src/php5/Types.h
php/src/php5/Util.cpp
php/src/php7/Communicator.cpp
php/src/php7/Communicator.h
php/src/php7/Config.h
php/src/php7/Connection.cpp
php/src/php7/Endpoint.cpp
php/src/php7/IcePHP.rc
php/src/php7/Makefile
php/src/php7/Operation.cpp
php/src/php7/Types.cpp
php/src/php7/Types.h
php/src/php7/Util.cpp
scripts/TestUtil.py
Diffstat (limited to 'scripts/TestUtil.py')
-rwxr-xr-x | scripts/TestUtil.py | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/scripts/TestUtil.py b/scripts/TestUtil.py index 0ea8a478dbd..8e53ca72e14 100755 --- a/scripts/TestUtil.py +++ b/scripts/TestUtil.py @@ -128,6 +128,16 @@ def isSparc(): else: return False +def dpkgHostMultiArch(): + p = subprocess.Popen("dpkg-architecture -qDEB_HOST_MULTIARCH", stdout=subprocess.PIPE, stderr=subprocess.STDOUT, shell=True) + if not p or not p.stdout: + print("unable to get system information!") + sys.exit(1) + return p.stdout.readline().decode("utf-8").strip() + +def isI686(): + return x86 or any(platform.machine() == p for p in ["i386", "i686"]) + def isAIX(): return sys.platform.startswith("aix") @@ -135,7 +145,7 @@ def isDarwin(): return sys.platform == "darwin" def isLinux(): - return sys.platform.startswith("linux") + return sys.platform.startswith("linux") or sys.platform.startswith("gnukfreebsd") def isUbuntu(): return isLinux() and linuxDistribution and linuxDistribution == "Ubuntu" @@ -152,6 +162,9 @@ def isDebian(): def isSles(): return isLinux() and linuxDistribution and linuxDistribution == "SUSE LINUX" +def iceUseOpenSSL(): + return any(sys.platform.startswith(p) for p in ["linux", "freebsd"]) + def getCppCompiler(): compiler = "" if os.environ.get("CPP_COMPILER", "") != "": @@ -829,7 +842,7 @@ def getIceBox(): iceBox += "++11" iceBox += ".exe" elif isLinux(): - if not x64 and not armv7l: + if isI686(): iceBox += "32" if cpp11: iceBox += "++11" @@ -1838,12 +1851,7 @@ def getCppLibDir(lang = None): else: libDir = os.path.join(getIceDir("cpp"), "lib") if isUbuntu() or isDebian(): - if armv7l: - libDir = os.path.join(libDir, "arm-linux-gnueabihf") - elif x64: - libDir = os.path.join(libDir, "x86_64-linux-gnu") - else: - libDir = os.path.join(libDir, "i386-linux-gnu") + libDir = os.path.join(libDir, dpkgHostMultiArch()) elif x64: if isSolaris(): if isSparc(): |