Commit a23b5ef6 authored by Mccaskey, Alex's avatar Mccaskey, Alex
Browse files

updates to manylinux docker file


Signed-off-by: Mccaskey, Alex's avatarAlex McCaskey <mccaskeyaj@ornl.gov>
parent 2f9128d2
......@@ -3,13 +3,13 @@ FROM xacc/manylinux1_x86_64
ARG python_version_str
ARG python_version
RUN curl -sL https://github.com/squeaky-pl/centos-devtools/releases/download/6.2/gcc-6.2.0-binutils-2.27-x86_64.tar.bz2 | tar xvj
RUN curl -sL https://github.com/squeaky-pl/centos-devtools/releases/download/6.2/gcc-6.2.0-binutils-2.27-x86_64.tar.bz2 | tar xvj
ENV CC=/opt/devtools-6.2/bin/gcc
ENV CXX=/opt/devtools-6.2/bin/g++
RUN rm -rf /usr/lib64/libstdc++.so.6* && mkdir -p all_wheels && yum remove -y gcc \
&& ln -s /opt/devtools-6.2/lib64/libstdc++* /usr/lib64/
RUN rm -rf /usr/lib64/libstdc++.so.6* && mkdir -p all_wheels && yum remove -y gcc \
&& ln -s /opt/devtools-6.2/lib64/libstdc++* /usr/lib64/
RUN git clone --recursive https://github.com/eclipse/xacc \
&& cd xacc \
......@@ -17,7 +17,7 @@ RUN git clone --recursive https://github.com/eclipse/xacc \
&& $myPython -m pip install ipopo configparser numpy scipy \
&& export xaccVersion=$($myPython -c "import os; print(open(os.path.join(os.getcwd(), 'VERSION')).read().strip())") \
&& $myPython --version \
&& $myPython setup.py build -t tmp \
&& $myPython setup.py build -t tmp \
&& echo "./xacc" >> build/lib.linux-x86_64-${python_version}/xacc.pth \
&& $myPython setup.py bdist_wheel --skip-build \
&& /opt/_internal/cpython-3.6.4/bin/python tools/wheels/fix_xacc_rpaths.py -v repair dist/xacc-$xaccVersion-${python_version_str}-linux_x86_64.whl \
......@@ -26,9 +26,9 @@ RUN git clone --recursive https://github.com/eclipse/xacc \
RUN export PATH=$PATH:/opt/devtools-6.2/bin \
&& cd / && yum install -y blas-devel lapack-devel \
&& git clone --recursive https://github.com/ornl-qci/tnqvm && cd tnqvm \
&& export myPython=/opt/python/${python_version_str}/bin/python \
&& export myPython=/opt/python/${python_version_str}/bin/python \
&& export tnqvmVersion=$($myPython -c "import os; print(open(os.path.join(os.getcwd(), 'VERSION')).read().strip())") \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
$myPython setup.py build -t tmp \
&& mkdir -p build/lib.linux-x86_64-${python_version}/xacc/lib \
&& cp /usr/lib64/liblapack.so.3 build/lib.linux-x86_64-${python_version}/xacc/lib/ \
......@@ -41,9 +41,9 @@ RUN export PATH=$PATH:/opt/devtools-6.2/bin \
RUN export PATH=$PATH:/opt/devtools-6.2/bin \
&& cd / && git clone --recursive https://github.com/ornl-qci/xacc-rigetti && cd xacc-rigetti \
&& export myPython=/opt/python/${python_version_str}/bin/python \
&& export myPython=/opt/python/${python_version_str}/bin/python \
&& export rigettiVersion=$($myPython -c "import os; print(open(os.path.join(os.getcwd(), 'VERSION')).read().strip())") \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
$myPython setup.py build -t tmp \
&& mkdir -p build/lib.linux-x86_64-${python_version}/xacc/lib \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
......@@ -51,23 +51,11 @@ RUN export PATH=$PATH:/opt/devtools-6.2/bin \
&& /opt/_internal/cpython-3.6.4/bin/python /xacc/tools/wheels/null_rpaths.py -v repair dist/xacc_rigetti-$rigettiVersion-${python_version_str}-linux_x86_64.whl \
&& cp wheelhouse/xacc_rigetti-$rigettiVersion-${python_version_str}-manylinux1_x86_64.whl /all_wheels
RUN export PATH=$PATH:/opt/devtools-6.2/bin \
&& cd / && git clone --recursive https://github.com/ornl-qci/xacc-dwave && cd xacc-dwave \
&& export myPython=/opt/python/${python_version_str}/bin/python \
&& export dwaveVersion=$($myPython -c "import os; print(open(os.path.join(os.getcwd(), 'VERSION')).read().strip())") \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
$myPython setup.py build -t tmp \
&& mkdir -p build/lib.linux-x86_64-${python_version}/xacc/lib \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
$myPython setup.py bdist_wheel --skip-build \
&& /opt/_internal/cpython-3.6.4/bin/python /xacc/tools/wheels/null_rpaths.py -v repair dist/xacc_dwave-$dwaveVersion-${python_version_str}-linux_x86_64.whl \
&& cp wheelhouse/xacc_dwave-$dwaveVersion-${python_version_str}-manylinux1_x86_64.whl /all_wheels
RUN export PATH=$PATH:/opt/devtools-6.2/bin \
&& cd / && git clone --recursive https://github.com/ornl-qci/xacc-ibm && cd xacc-ibm \
&& export myPython=/opt/python/${python_version_str}/bin/python \
&& export myPython=/opt/python/${python_version_str}/bin/python \
&& export ibmVersion=$($myPython -c "import os; print(open(os.path.join(os.getcwd(), 'VERSION')).read().strip())") \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
$myPython setup.py build -t tmp \
&& mkdir -p build/lib.linux-x86_64-${python_version}/xacc/lib \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
......@@ -77,9 +65,9 @@ RUN export PATH=$PATH:/opt/devtools-6.2/bin \
RUN export PATH=$PATH:/opt/devtools-6.2/bin \
&& cd / && git clone --recursive https://github.com/ornl-qci/xacc-vqe && cd xacc-vqe \
&& export myPython=/opt/python/${python_version_str}/bin/python \
&& export myPython=/opt/python/${python_version_str}/bin/python \
&& export vqeVersion=$($myPython -c "import os; print(open(os.path.join(os.getcwd(), 'VERSION')).read().strip())") \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
$myPython setup.py build -t tmp \
&& mkdir -p build/lib.linux-x86_64-${python_version}/xacc/lib \
&& PYTHONPATH=/xacc/build/lib.linux-x86_64-${python_version}/xacc \
......
......@@ -51,18 +51,18 @@ class CMakeBuild(build_ext):
print(sys.argv)
args = sys.argv[1:]
script_path = os.path.dirname(os.path.realpath(__file__))
if 'install' in args and not '--record' in args:
install_prefix = script_path + '/' + self.build_lib
install_prefix = script_path + '/' + self.build_lib
else:
install_prefix = script_path + '/' + self.build_lib + '/xacc'
install_prefix = script_path + '/' + self.build_lib + '/xacc'
print(self.build_lib)
cmake_args = ['-DPYTHON_INCLUDE_DIR=' + sysconfig.get_paths()['platinclude'], #sys.executable,
'-DCMAKE_INSTALL_PREFIX='+install_prefix,
'-DFROM_SETUP_PY=TRUE']
cfg = 'Debug' if self.debug else 'Release'
build_args = ['--config', cfg]
......@@ -89,7 +89,7 @@ s = setup(
description='Hardware-agnostic quantum programming framework',
long_description='XACC provides a language and hardware agnostic programming framework for hybrid classical-quantum applications.',
ext_modules=[CMakeExtension('xacc')],
install_requires=['numpy','ipopo', 'configparser'],
install_requires=['numpy','scipy','ipopo', 'configparser'],
extras_require={'all':['xacc-rigetti','xacc-ibm','tnqvm','xacc-vqe']},
cmdclass={'build_ext':CMakeBuild},
#scripts=['tools/framework/xacc-framework'],
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment