mirror of
https://github.com/gnss-sdr/gnss-sdr
synced 2025-01-31 03:14:56 +00:00
Merge branch 'no-six' into next
Remove python3-six dependency
This commit is contained in:
commit
cda1be81e5
14
.github/workflows/main.yml
vendored
14
.github/workflows/main.yml
vendored
@ -10,7 +10,7 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: install dependencies
|
||||
run: sudo apt-get update && sudo apt-get install ninja-build libboost-dev libboost-date-time-dev libboost-system-dev libboost-filesystem-dev libboost-thread-dev libboost-chrono-dev libboost-serialization-dev liblog4cpp5-dev gnuradio-dev gr-osmosdr libpugixml-dev libpcap-dev libblas-dev liblapack-dev libarmadillo-dev libgflags-dev libgoogle-glog-dev libgnutls-openssl-dev libmatio-dev googletest protobuf-compiler libprotobuf-dev python3-mako python3-six
|
||||
run: sudo apt-get update && sudo apt-get install ninja-build libboost-dev libboost-date-time-dev libboost-system-dev libboost-filesystem-dev libboost-thread-dev libboost-chrono-dev libboost-serialization-dev liblog4cpp5-dev gnuradio-dev gr-osmosdr libpugixml-dev libpcap-dev libblas-dev liblapack-dev libarmadillo-dev libgflags-dev libgoogle-glog-dev libgnutls-openssl-dev libmatio-dev googletest protobuf-compiler libprotobuf-dev python3-mako
|
||||
- name: configure
|
||||
run: cd build && cmake -GNinja ..
|
||||
- name: build
|
||||
@ -26,7 +26,7 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: install dependencies
|
||||
run: brew install ninja pkg-config hdf5 libtool automake armadillo lapack gflags glog gnuradio log4cpp pugixml protobuf && pip3 install mako && pip3 install six
|
||||
run: brew install ninja pkg-config hdf5 libtool automake armadillo lapack gflags glog gnuradio log4cpp pugixml protobuf && pip3 install mako
|
||||
- name: configure
|
||||
run: cd build && cmake -GNinja ..
|
||||
- name: build
|
||||
@ -54,7 +54,7 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: install dependencies
|
||||
run: brew install llvm pkg-config hdf5 armadillo lapack gflags glog gnuradio libmatio log4cpp pugixml protobuf && ln -s /usr/local/opt/llvm/bin/clang-tidy /usr/local/bin && ln -s /usr/local/Cellar/llvm/10.*/bin/clang-apply-replacements /usr/local/bin && cp /usr/local/Cellar/llvm/10.*/share/clang/run-clang-tidy.py /usr/local/bin && pip3 install mako && pip3 install six
|
||||
run: brew install llvm pkg-config hdf5 armadillo lapack gflags glog gnuradio libmatio log4cpp pugixml protobuf && ln -s /usr/local/opt/llvm/bin/clang-tidy /usr/local/bin && ln -s /usr/local/Cellar/llvm/10.*/bin/clang-apply-replacements /usr/local/bin && cp /usr/local/Cellar/llvm/10.*/share/clang/run-clang-tidy.py /usr/local/bin && pip3 install mako
|
||||
- name: Prepare run
|
||||
run: cd build && cmake .. && make volk_gnsssdr_module gtest-1.10.0 core_monitor pvt_libs
|
||||
- name: run clang-tidy
|
||||
@ -103,7 +103,7 @@ jobs:
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install mako six
|
||||
pip install mako
|
||||
- name: configure
|
||||
shell: powershell
|
||||
run: cd build; cmake -G "Visual Studio 16 2019" ..\src\algorithms\libs\volk_gnsssdr_module\volk_gnsssdr
|
||||
@ -119,7 +119,7 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: install dependencies
|
||||
run: sudo apt-get install build-essential python3-mako python3-six cmake
|
||||
run: sudo apt-get install build-essential python3-mako cmake
|
||||
- name: configure
|
||||
run: cd build && cmake ../src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr
|
||||
- name: build
|
||||
@ -135,7 +135,7 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: install dependencies
|
||||
run: pip3 install mako && pip3 install six
|
||||
run: pip3 install mako
|
||||
- name: configure
|
||||
run: cd build && cmake ../src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr
|
||||
- name: build
|
||||
@ -149,7 +149,7 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v1
|
||||
- name: install dependencies
|
||||
run: pip3 install mako && pip3 install six
|
||||
run: pip3 install mako
|
||||
- name: configure
|
||||
run: cd build && cmake -GXcode ../src/algorithms/libs/volk_gnsssdr_module/volk_gnsssdr
|
||||
- name: build
|
||||
|
@ -803,29 +803,36 @@ if(NOT VOLKGNSSSDR_FOUND)
|
||||
if(NOT MAKO_FOUND)
|
||||
message(STATUS "Mako template library not found. See https://www.makotemplates.org/")
|
||||
message(STATUS " You can try to install it by typing:")
|
||||
if(${LINUX_DISTRIBUTION} MATCHES "Fedora" OR ${LINUX_DISTRIBUTION} MATCHES "Red Hat")
|
||||
message(STATUS " sudo yum install ${PYTHON_NAME}-mako")
|
||||
elseif(${LINUX_DISTRIBUTION} MATCHES "openSUSE")
|
||||
message(STATUS " sudo zypper install ${PYTHON_NAME}-Mako")
|
||||
else()
|
||||
message(STATUS " sudo apt-get install ${PYTHON_NAME}-mako")
|
||||
if(${CMAKE_SYSTEM_NAME} MATCHES "Linux|kFreeBSD|GNU")
|
||||
if(${LINUX_DISTRIBUTION} MATCHES "Fedora" OR ${LINUX_DISTRIBUTION} MATCHES "Red Hat")
|
||||
message(STATUS " sudo yum install ${PYTHON_NAME}-mako")
|
||||
elseif(${LINUX_DISTRIBUTION} MATCHES "openSUSE")
|
||||
message(STATUS " sudo zypper install ${PYTHON_NAME}-Mako")
|
||||
else()
|
||||
message(STATUS " sudo apt-get install ${PYTHON_NAME}-mako")
|
||||
endif()
|
||||
endif()
|
||||
message(FATAL_ERROR "Mako templates required to build VOLK_GNSSSDR")
|
||||
endif()
|
||||
|
||||
# Six
|
||||
if(NOT SIX_FOUND)
|
||||
message(STATUS "python-six not found. See https://pythonhosted.org/six/")
|
||||
message(STATUS " You can try to install it by typing:")
|
||||
if(${LINUX_DISTRIBUTION} MATCHES "Fedora" OR ${LINUX_DISTRIBUTION} MATCHES "Red Hat")
|
||||
message(STATUS " sudo yum install ${PYTHON_NAME}-six")
|
||||
elseif(${LINUX_DISTRIBUTION} MATCHES "openSUSE")
|
||||
message(STATUS " sudo zypper install ${PYTHON_NAME}-six")
|
||||
else()
|
||||
message(STATUS " sudo apt-get install ${PYTHON_NAME}-six")
|
||||
if(PYTHON_NAME STREQUAL "python")
|
||||
# Six
|
||||
if(NOT SIX_FOUND)
|
||||
message(STATUS "python-six not found. See https://pythonhosted.org/six/")
|
||||
if(${CMAKE_SYSTEM_NAME} MATCHES "Linux|kFreeBSD|GNU")
|
||||
message(STATUS " You can try to install it by typing:")
|
||||
if(${LINUX_DISTRIBUTION} MATCHES "Fedora" OR ${LINUX_DISTRIBUTION} MATCHES "Red Hat")
|
||||
message(STATUS " sudo yum install ${PYTHON_NAME}-six")
|
||||
elseif(${LINUX_DISTRIBUTION} MATCHES "openSUSE")
|
||||
message(STATUS " sudo zypper install ${PYTHON_NAME}-six")
|
||||
else()
|
||||
message(STATUS " sudo apt-get install ${PYTHON_NAME}-six")
|
||||
endif()
|
||||
endif()
|
||||
message(FATAL_ERROR "six - python 2 and 3 compatibility library required to build VOLK_GNSSSDR")
|
||||
endif()
|
||||
message(FATAL_ERROR "six - python 2 and 3 compatibility library required to build VOLK_GNSSSDR")
|
||||
endif()
|
||||
|
||||
if(CMAKE_VERSION VERSION_GREATER 3.12)
|
||||
set_package_properties(Python3 PROPERTIES
|
||||
URL "https://www.python.org/"
|
||||
|
25
README.md
25
README.md
@ -96,7 +96,7 @@ $ sudo apt-get install build-essential cmake git pkg-config libboost-dev libboos
|
||||
libboost-serialization-dev liblog4cpp5-dev libuhd-dev gnuradio-dev gr-osmosdr \
|
||||
libblas-dev liblapack-dev libarmadillo-dev libgflags-dev libgoogle-glog-dev \
|
||||
libgnutls-openssl-dev libpcap-dev libmatio-dev libpugixml-dev libgtest-dev \
|
||||
libprotobuf-dev protobuf-compiler python3-mako python3-six
|
||||
libprotobuf-dev protobuf-compiler python3-mako
|
||||
```
|
||||
|
||||
Please note that the required files from `libgtest-dev` were moved to
|
||||
@ -115,11 +115,13 @@ the `libmatio-dev` package and install `libtool`, `automake` and `libhdf5-dev`
|
||||
instead. A recent version of the library will be downloaded and built
|
||||
automatically if CMake does not find it installed.
|
||||
|
||||
In distributions older than Ubuntu 16.04 or Debian 9, `python3-mako` and
|
||||
`python3-six` must be replaced by `python-mako` and `python-six`.
|
||||
In distributions older than Ubuntu 16.04 or Debian 9, `python3-mako` must be
|
||||
replaced by `python-mako`. For Ubuntu 14.04, you will need to add the package
|
||||
`python-six` to the list of dependencies.
|
||||
|
||||
**Note for Debian 8 "jessie" users:** please see the note about `libmatio-dev`
|
||||
above. Install `libtool`, `automake` and `libhdf5-dev` instead.
|
||||
above. Install `libtool`, `automake` and `libhdf5-dev` instead. You will also
|
||||
need `python-six`.
|
||||
|
||||
Once you have installed these packages, you can jump directly to
|
||||
[download the source code and build GNSS-SDR](#download-and-build-linux).
|
||||
@ -130,8 +132,8 @@ If you are using Arch Linux:
|
||||
|
||||
```
|
||||
$ pacman -S gcc make cmake pkgconf git boost boost-libs log4cpp libvolk gnuradio \
|
||||
blas lapack gflags google-glog openssl pugixml \
|
||||
python-mako python-six libmatio libpcap gtest protobuf
|
||||
blas lapack gflags google-glog openssl pugixml libmatio protobuf \
|
||||
python-mako libpcap gtest
|
||||
```
|
||||
|
||||
Once you have installed these packages, you can jump directly to
|
||||
@ -166,8 +168,8 @@ $ sudo yum install make automake gcc gcc-c++ kernel-devel cmake git boost-devel
|
||||
boost-date-time boost-system boost-filesystem boost-thread boost-chrono \
|
||||
boost-serialization log4cpp-devel gnuradio-devel gr-osmosdr-devel \
|
||||
blas-devel lapack-devel matio-devel armadillo-devel gflags-devel \
|
||||
glog-devel openssl-devel libpcap-devel python3-mako python3-six \
|
||||
pugixml-devel protobuf-devel protobuf-compiler
|
||||
glog-devel openssl-devel libpcap-devel pugixml-devel python3-mako \
|
||||
protobuf-devel protobuf-compiler
|
||||
```
|
||||
|
||||
Once you have installed these packages, you can jump directly to
|
||||
@ -182,7 +184,7 @@ zypper install cmake git gcc-c++ boost-devel libboost_atomic-devel \
|
||||
libboost_system-devel libboost_filesystem-devel libboost_chrono-devel \
|
||||
libboost_thread-devel libboost_serialization-devel log4cpp-devel \
|
||||
gnuradio-devel pugixml-devel libpcap-devel armadillo-devel libtool \
|
||||
automake hdf5-devel openssl-devel python3-Mako python3-six protobuf-devel
|
||||
automake hdf5-devel openssl-devel python3-Mako protobuf-devel
|
||||
```
|
||||
|
||||
If you are using openSUSE Tumbleweed:
|
||||
@ -193,7 +195,7 @@ zypper install cmake git gcc-c++ boost-devel libboost_atomic-devel \
|
||||
libboost_thread-devel libboost_chrono-devel libboost_serialization-devel \
|
||||
log4cpp-devel gtest gnuradio-devel pugixml-devel libpcap-devel \
|
||||
armadillo-devel libtool automake hdf5-devel libopenssl-devel \
|
||||
python3-Mako python3-six protobuf-devel
|
||||
python3-Mako protobuf-devel
|
||||
```
|
||||
|
||||
Once you have installed these packages, you can jump directly to
|
||||
@ -739,7 +741,7 @@ $ sudo port selfupdate
|
||||
$ sudo port upgrade outdated
|
||||
$ sudo port install armadillo cmake gnuradio gnutls lapack libad9361-iio libiio \
|
||||
matio pkgconfig protobuf3-cpp pugixml google-glog +gflags
|
||||
$ sudo port install py37-mako py37-six
|
||||
$ sudo port install py37-mako
|
||||
$ sudo port install doxygen +docs
|
||||
```
|
||||
|
||||
@ -781,7 +783,6 @@ $ brew update && brew upgrade
|
||||
$ brew install armadillo cmake hdf5 gflags glog gnuradio lapack libmatio log4cpp \
|
||||
openssl pkg-config protobuf pugixml
|
||||
$ pip3 install mako
|
||||
$ pip3 install six
|
||||
$ brew cask install mactex # when completed, restart Terminal
|
||||
$ brew install graphviz doxygen
|
||||
```
|
||||
|
@ -60,10 +60,11 @@ if(CMAKE_VERSION VERSION_LESS 3.12)
|
||||
endif()
|
||||
gnsssdr_python_check_module("python >= ${GNSSSDR_PYTHON_MIN_VERSION}" sys "sys.version.split()[0] >= '${GNSSSDR_PYTHON_MIN_VERSION}'" PYTHON_MIN_VER_FOUND)
|
||||
gnsssdr_python_check_module("mako >= ${GNSSSDR_MAKO_MIN_VERSION}" mako "mako.__version__ >= '${GNSSSDR_MAKO_MIN_VERSION}'" MAKO_FOUND)
|
||||
gnsssdr_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||
if(IS_PYTHON3 EQUAL -1)
|
||||
gnsssdr_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||
endif()
|
||||
else()
|
||||
message(STATUS "PYTHON_EXECUTABLE not set - trying by default python3")
|
||||
message(STATUS "Use -DPYTHON_EXECUTABLE=/path/to/python to build for python 2.7")
|
||||
set(Python_ADDITIONAL_VERSIONS 3.4 3.5 3.6 3.7 3.8 3.9)
|
||||
find_package(PythonInterp ${GNSSSDR_PYTHON_MIN3_VERSION})
|
||||
if(NOT PYTHONINTERP_FOUND)
|
||||
@ -72,7 +73,9 @@ if(CMAKE_VERSION VERSION_LESS 3.12)
|
||||
endif()
|
||||
gnsssdr_python_check_module("python >= ${GNSSSDR_PYTHON_MIN_VERSION}" sys "sys.version.split()[0] >= '${GNSSSDR_PYTHON_MIN_VERSION}'" PYTHON_MIN_VER_FOUND)
|
||||
gnsssdr_python_check_module("mako >= ${GNSSSDR_MAKO_MIN_VERSION}" mako "mako.__version__ >= '${GNSSSDR_MAKO_MIN_VERSION}'" MAKO_FOUND)
|
||||
gnsssdr_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||
if(PYTHON_VERSION_STRING VERSION_LESS "3.0")
|
||||
gnsssdr_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||
endif()
|
||||
endif()
|
||||
else()
|
||||
find_package(Python3 COMPONENTS Interpreter)
|
||||
@ -81,9 +84,8 @@ else()
|
||||
set(PYTHON_VERSION_MAJOR ${Python3_VERSION_MAJOR})
|
||||
gnsssdr_python_check_module("python >= ${GNSSSDR_PYTHON_MIN_VERSION}" sys "sys.version.split()[0] >= '${GNSSSDR_PYTHON_MIN_VERSION}'" PYTHON_MIN_VER_FOUND)
|
||||
gnsssdr_python_check_module("mako >= ${GNSSSDR_MAKO_MIN_VERSION}" mako "mako.__version__ >= '${GNSSSDR_MAKO_MIN_VERSION}'" MAKO_FOUND)
|
||||
gnsssdr_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||
endif()
|
||||
if(NOT Python3_FOUND OR NOT MAKO_FOUND OR NOT SIX_FOUND)
|
||||
if(NOT Python3_FOUND OR NOT MAKO_FOUND)
|
||||
find_package(Python2 COMPONENTS Interpreter)
|
||||
if(Python2_FOUND)
|
||||
set(PYTHON_EXECUTABLE ${Python2_EXECUTABLE})
|
||||
@ -97,7 +99,9 @@ else()
|
||||
find_package(PythonInterp ${GNSSSDR_PYTHON_MIN_VERSION})
|
||||
gnsssdr_python_check_module("python >= ${GNSSSDR_PYTHON_MIN_VERSION}" sys "sys.version.split()[0] >= '${GNSSSDR_PYTHON_MIN_VERSION}'" PYTHON_MIN_VER_FOUND)
|
||||
gnsssdr_python_check_module("mako >= ${GNSSSDR_MAKO_MIN_VERSION}" mako "mako.__version__ >= '${GNSSSDR_MAKO_MIN_VERSION}'" MAKO_FOUND)
|
||||
gnsssdr_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||
if(PYTHON_VERSION_STRING VERSION_LESS "3.0")
|
||||
gnsssdr_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
|
@ -20,6 +20,7 @@ SPDX-FileCopyrightText: 2011-2020 Carles Fernandez-Prades <carles.fernandez@cttc
|
||||
|
||||
- The software can now be built against the GNU Radio 3.9 API that uses C++11
|
||||
smart pointers instead of Boost smart pointers.
|
||||
- Remove python six module as a dependency if using Python 3.x.
|
||||
|
||||
### Improvements in Portability:
|
||||
|
||||
|
@ -228,10 +228,12 @@ endif()
|
||||
########################################################################
|
||||
|
||||
# Python
|
||||
include(VolkPython) # sets PYTHON_EXECUTABLE and PYTHON_DASH_B
|
||||
include(VolkPython) # sets PYTHON_EXECUTABLE
|
||||
volk_python_check_module("python >= 2.7" sys "sys.version.split()[0] >= '2.7'" PYTHON_MIN_VER_FOUND)
|
||||
volk_python_check_module("mako >= 0.4.2" mako "mako.__version__ >= '0.4.2'" MAKO_FOUND)
|
||||
volk_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||
if(Python2_VERSION OR (PYTHON_VERSION_STRING VERSION_LESS "3.0"))
|
||||
volk_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||
endif()
|
||||
|
||||
if(NOT PYTHON_MIN_VER_FOUND)
|
||||
message(FATAL_ERROR "Python 2.7 or greater required to build VOLK_GNSSSDR")
|
||||
@ -241,9 +243,12 @@ endif()
|
||||
if(NOT MAKO_FOUND)
|
||||
message(FATAL_ERROR "Mako templates required to build VOLK_GNSSSDR")
|
||||
endif()
|
||||
|
||||
# Six
|
||||
if(NOT SIX_FOUND)
|
||||
message(FATAL_ERROR "six - python 2 and 3 compatibility library required to build VOLK")
|
||||
if(Python2_VERSION OR (PYTHON_VERSION_STRING VERSION_LESS "3.0"))
|
||||
if(NOT SIX_FOUND)
|
||||
message(FATAL_ERROR "six - python 2 and 3 compatibility library required to build VOLK_GNSSSDR")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
|
@ -78,14 +78,15 @@ else()
|
||||
if(Python3_FOUND)
|
||||
set(PYTHON_EXECUTABLE ${Python3_EXECUTABLE})
|
||||
set(PYTHON_VERSION_MAJOR ${Python3_VERSION_MAJOR})
|
||||
set(PYTHON_VERSION_STRING ${Python3_VERSION})
|
||||
volk_python_check_module("mako >= 0.4.2" mako "mako.__version__ >= '0.4.2'" MAKO_FOUND)
|
||||
volk_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||
endif()
|
||||
if(NOT Python3_FOUND OR NOT MAKO_FOUND OR NOT SIX_FOUND)
|
||||
if(NOT Python3_FOUND OR NOT MAKO_FOUND)
|
||||
find_package(Python2 COMPONENTS Interpreter)
|
||||
if(Python2_FOUND)
|
||||
set(PYTHON_EXECUTABLE ${Python2_EXECUTABLE})
|
||||
set(PYTHON_VERSION_MAJOR ${Python2_VERSION_MAJOR})
|
||||
set(PYTHON_VERSION_STRING ${Python2_VERSION})
|
||||
volk_python_check_module("mako >= 0.4.2" mako "mako.__version__ >= '0.4.2'" MAKO_FOUND)
|
||||
volk_python_check_module("six - python 2 and 3 compatibility library" six "True" SIX_FOUND)
|
||||
endif()
|
||||
|
@ -10,9 +10,10 @@
|
||||
#
|
||||
|
||||
from __future__ import print_function
|
||||
|
||||
import six
|
||||
|
||||
import sys
|
||||
if sys.version_info[0] < 3:
|
||||
import six
|
||||
|
||||
archs = list()
|
||||
arch_dict = dict()
|
||||
|
||||
@ -75,8 +76,9 @@ for arch_xml in archs_xml:
|
||||
name = flag_xml.attributes["compiler"].value
|
||||
if name not in flags: flags[name] = list()
|
||||
flags[name].append(flag_xml.firstChild.data)
|
||||
#force kwargs keys to be of type str, not unicode for py25
|
||||
kwargs = dict((str(k), v) for k, v in six.iteritems(kwargs))
|
||||
if sys.version_info[0] < 3:
|
||||
#force kwargs keys to be of type str, not unicode for py25
|
||||
kwargs = dict((str(k), v) for k, v in six.iteritems(kwargs))
|
||||
register_arch(flags=flags, checks=checks, **kwargs)
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
@ -8,9 +8,11 @@
|
||||
#
|
||||
# SPDX-License-Identifier: GPL-3.0-or-later
|
||||
#
|
||||
from __future__ import print_function
|
||||
|
||||
import six
|
||||
from __future__ import print_function
|
||||
import sys
|
||||
if sys.version_info[0] < 3:
|
||||
import six
|
||||
|
||||
from volk_gnsssdr_arch_defs import arch_dict
|
||||
|
||||
@ -28,7 +30,7 @@ class machine_class(object):
|
||||
self.archs.append(arch)
|
||||
self.arch_names.append(arch_name)
|
||||
self.alignment = max([a.alignment for a in self.archs])
|
||||
|
||||
|
||||
def __repr__(self): return self.name
|
||||
|
||||
def register_machine(name, archs):
|
||||
@ -64,7 +66,8 @@ for machine_xml in machines_xml:
|
||||
except: pass
|
||||
kwargs['archs'] = kwargs['archs'].split()
|
||||
#force kwargs keys to be of type str, not unicode for py25
|
||||
kwargs = dict((str(k), v) for k, v in six.iteritems(kwargs))
|
||||
if sys.version_info[0] < 3:
|
||||
kwargs = dict((str(k), v) for k, v in six.iteritems(kwargs))
|
||||
register_machine(**kwargs)
|
||||
|
||||
if __name__ == '__main__':
|
||||
|
Loading…
Reference in New Issue
Block a user