diff options
author | Parichay Kapoor <pk.kapoor@samsung.com> | 2019-05-15 09:20:13 +0900 |
---|---|---|
committer | Parichay Kapoor <pk.kapoor@samsung.com> | 2019-05-15 09:23:05 +0900 |
commit | 9cb4b176da20dac9829befcbd626edc36303237e (patch) | |
tree | afd308a66ebb35ca1a1bf8bebf67d3973d55b3f1 /debian | |
parent | 84b275b70f73d5fd311f62614bccc405f3d5bfa3 (diff) | |
download | pytorch-9cb4b176da20dac9829befcbd626edc36303237e.tar.gz pytorch-9cb4b176da20dac9829befcbd626edc36303237e.tar.bz2 pytorch-9cb4b176da20dac9829befcbd626edc36303237e.zip |
Added pytorch debian packaging
- Add debian rules and install for installing pytorch and caffe2
- Add pkgconfig for pytorch
- Add copyright, control, compat and corresponding change log
Signed-off-by: Parichay Kapoor <pk.kapoor@samsung.com>
Diffstat (limited to 'debian')
-rw-r--r-- | debian/changelog | 5 | ||||
-rw-r--r-- | debian/compat | 1 | ||||
-rw-r--r-- | debian/control | 35 | ||||
-rw-r--r-- | debian/copyright | 70 | ||||
-rw-r--r-- | debian/install | 4 | ||||
-rwxr-xr-x | debian/rules | 47 |
6 files changed, 162 insertions, 0 deletions
diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000000..6de624eef2 --- /dev/null +++ b/debian/changelog @@ -0,0 +1,5 @@ +pytorch (1.0.1-1) xenial; urgency=medium + + * Initial debian dist files added + + -- Parichay Kapoor <pk.kapoor@samsung.com> Fri, 10 May 2019 17:52:02 +0900 diff --git a/debian/compat b/debian/compat new file mode 100644 index 0000000000..ec635144f6 --- /dev/null +++ b/debian/compat @@ -0,0 +1 @@ +9 diff --git a/debian/control b/debian/control new file mode 100644 index 0000000000..af53976cd6 --- /dev/null +++ b/debian/control @@ -0,0 +1,35 @@ +Source: pytorch +Section: devel +Homepage: https://pytorch.org/ +Priority: optional +Standards-Version: 1.0.1-1 +Maintainer: Parichay Kapoor <pk.kapoor@samsung.com> +Build-Depends: + cmake, + debhelper (>= 9~), + dh-python, + git, + libasio-dev, + libblas-dev | libblas.so, + python, + python-yaml, + python3-all, + python3-all-dev, + python3-cffi, + python3-numpy, + python3-setuptools, + python3-yaml, + +Package: pytorch +Architecture: any +Multi-Arch: foreign +Depends: + python3 (>= 3.5), + python3-cffi, + python3-numpy, + ${misc:Depends}, + ${shlibs:Depends}, + ${python3:Depends}, +Suggests: + intel-mkl, +Description: Tensors and Dynamic neural networks with GPU acceleration diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 0000000000..2d7539f7cf --- /dev/null +++ b/debian/copyright @@ -0,0 +1,70 @@ +From PyTorch: + +Copyright (c) 2016- Facebook, Inc (Adam Paszke) +Copyright (c) 2014- Facebook, Inc (Soumith Chintala) +Copyright (c) 2011-2014 Idiap Research Institute (Ronan Collobert) +Copyright (c) 2012-2014 Deepmind Technologies (Koray Kavukcuoglu) +Copyright (c) 2011-2012 NEC Laboratories America (Koray Kavukcuoglu) +Copyright (c) 2011-2013 NYU (Clement Farabet) +Copyright (c) 2006-2010 NEC Laboratories America (Ronan Collobert, Leon Bottou, Iain Melvin, Jason Weston) +Copyright (c) 2006 Idiap Research Institute (Samy Bengio) +Copyright (c) 2001-2004 Idiap Research Institute (Ronan Collobert, Samy Bengio, Johnny Mariethoz) + +From Caffe2: + +Copyright (c) 2016-present, Facebook Inc. All rights reserved. + +All contributions by Facebook: +Copyright (c) 2016 Facebook Inc. + +All contributions by Google: +Copyright (c) 2015 Google Inc. +All rights reserved. + +All contributions by Yangqing Jia: +Copyright (c) 2015 Yangqing Jia +All rights reserved. + +All contributions from Caffe: +Copyright(c) 2013, 2014, 2015, the respective contributors +All rights reserved. + +All other contributions: +Copyright(c) 2015, 2016 the respective contributors +All rights reserved. + +Caffe2 uses a copyright model similar to Caffe: each contributor holds +copyright over their contributions to Caffe2. The project versioning records +all such contribution and copyright details. If a contributor wants to further +mark their specific copyright on a particular contribution, they should +indicate their copyright solely in the commit message of the change when it is +committed. + +All rights reserved. + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +1. Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +2. Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + +3. Neither the names of Facebook, Deepmind Technologies, NYU, NEC Laboratories America + and IDIAP Research Institute nor the names of its contributors may be + used to endorse or promote products derived from this software without + specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. diff --git a/debian/install b/debian/install new file mode 100644 index 0000000000..81e6932475 --- /dev/null +++ b/debian/install @@ -0,0 +1,4 @@ +debian/pytorch/usr/lib/python3.5/dist-packages/torch/include/* usr/include +debian/pytorch/usr/lib/python3.5/dist-packages/torch/share/* usr/share +debian/pytorch/usr/lib/python3.5/dist-packages/torch/lib/* usr/lib +pytorch.pc usr/lib/pkgconfig diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000000..143516476e --- /dev/null +++ b/debian/rules @@ -0,0 +1,47 @@ +#!/usr/bin/make -f +export PYBUILD_NAME=pytorch +export PYBUILD_DISABLE_python2=1 # No more Python2 Packages +export USE_FBGEMM=0 +export BUILD_TEST=0 +export BUILD_BINARY=1 +export NO_CUDA=1 +export PYBUILD_DISABLE=test +export DEB_BUILD_OPTIONS+=nocheck +export DEB_BUILD_OPTIONS+=noddebs + +name = ${PYBUILD_NAME} +topdir = $(shell pwd) +buildroot = ${topdir}/debian/tmp +_libdir ?= /usr/lib +_includedir ?= /usr/include +_sharedir ?= /usr/share +packagingdir = ${topdir}/packaging + +%: + dh $@ --with python3 --buildsystem=pybuild + +override_dh_python3: + dh_python3 --no-ext-rename + +override_dh_auto_clean: + dh_auto_clean + -find . -type d -name __pycache__ -exec rm -rf '{}' + + +override_dh_auto_test: + # no tests to be run + echo "No tests to be run" + +override_dh_test: + # no tests to be run + echo "No tests to be run" + +override_dh_auto_install: + dh_auto_install + dh_testdir + dh_testroot + + install -d ${buildroot} + install -d ${buildroot}${_libdir} # all .a and .so in here + install -d ${buildroot}${_includedir}/torch + install -d ${buildroot}${_sharedir}/torch + install -d ${buildroot}${_libdir}/pkgconfig |