├── .gitignore ├── README.md ├── acquire_assets.sh ├── assets ├── packages │ └── system76-cuda-9.2 │ │ └── fetch-cuda-samples └── share │ ├── cuda_makefile │ ├── cuda_makefile_v2 │ ├── cuda_makefile_v3 │ ├── nvidia_cuda │ └── copyright │ ├── tensorflow-1.11 │ ├── CMakeLists.txt │ ├── LICENSE │ ├── cmake │ │ ├── TensorflowBase.cmake │ │ ├── TensorflowCCConfig.cmake.in │ │ ├── TensorflowShared.cmake │ │ ├── TensorflowStatic.cmake │ │ ├── build_tensorflow.sh │ │ └── copy_links.sh │ └── stream.patch │ ├── tensorflow-1.12 │ ├── CMakeLists.txt │ ├── LICENSE │ └── cmake │ │ ├── TensorflowBase.cmake │ │ ├── TensorflowCCConfig.cmake.in │ │ ├── TensorflowShared.cmake │ │ ├── TensorflowStatic.cmake │ │ ├── build_tensorflow.sh │ │ └── copy_links.sh │ ├── tensorflow-1.13 │ ├── CMakeLists.txt │ ├── LICENSE │ └── cmake │ │ ├── TensorflowBase.cmake │ │ ├── TensorflowCCConfig.cmake.in │ │ ├── TensorflowShared.cmake │ │ ├── TensorflowStatic.cmake │ │ ├── build_tensorflow.sh │ │ └── copy_links.sh │ ├── tensorflow-1.9 │ ├── CMakeLists.txt │ ├── LICENSE │ ├── cmake │ │ ├── TensorflowBase.cmake │ │ ├── TensorflowCCConfig.cmake.in │ │ ├── TensorflowShared.cmake │ │ ├── TensorflowStatic.cmake │ │ ├── build_tensorflow.sh │ │ └── copy_links.sh │ └── stream.patch │ └── tensorflow │ ├── assets │ ├── README.md │ └── examples │ │ └── cc │ │ ├── CMakeLists.txt │ │ ├── README.md │ │ └── example.cpp │ ├── copyright │ └── deps.sh ├── debian ├── README.md ├── focal │ ├── bazel │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-cuda-10.1 │ │ ├── changelog │ │ ├── control │ │ ├── postinst │ │ └── rules │ ├── system76-cuda-10.2 │ │ ├── changelog │ │ ├── control │ │ ├── postinst │ │ └── rules │ ├── system76-cuda-11.1 │ │ ├── changelog │ │ ├── control │ │ ├── postinst │ │ └── rules │ ├── system76-cuda-11.2 │ │ ├── changelog │ │ ├── control │ │ ├── postinst │ │ └── rules │ ├── system76-cuda │ │ ├── assets │ │ │ ├── fetch-cuda-samples │ │ │ ├── system76-cuda.conf │ │ │ └── system76-cuda.sh │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-cudnn-10.1 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-cudnn-10.2 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-cudnn-11.1 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-cudnn-11.2 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-nccl-10.1 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-nccl-10.2 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-nccl-11.1 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ └── system76-nccl-11.2 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules ├── groovy │ ├── bazel │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-cuda-10.1 │ │ ├── changelog │ │ ├── control │ │ ├── postinst │ │ └── rules │ ├── system76-cuda-10.2 │ │ ├── changelog │ │ ├── control │ │ ├── postinst │ │ └── rules │ ├── system76-cuda-11.1 │ │ ├── changelog │ │ ├── control │ │ ├── postinst │ │ └── rules │ ├── system76-cuda-11.2 │ │ ├── changelog │ │ ├── control │ │ ├── postinst │ │ └── rules │ ├── system76-cuda │ │ ├── assets │ │ │ ├── fetch-cuda-samples │ │ │ ├── system76-cuda.conf │ │ │ └── system76-cuda.sh │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-cudnn-10.1 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-cudnn-10.2 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-cudnn-11.1 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-cudnn-11.2 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-nccl-10.1 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-nccl-10.2 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ ├── system76-nccl-11.1 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules │ └── system76-nccl-11.2 │ │ ├── changelog │ │ ├── control │ │ ├── install │ │ └── rules └── impish │ ├── bazel │ ├── changelog │ ├── control │ ├── install │ └── rules │ ├── system76-cuda-11.1 │ ├── changelog │ ├── control │ ├── postinst │ └── rules │ ├── system76-cuda-11.2 │ ├── changelog │ ├── control │ ├── postinst │ └── rules │ ├── system76-cuda │ ├── assets │ │ ├── fetch-cuda-samples │ │ ├── system76-cuda.conf │ │ └── system76-cuda.sh │ ├── changelog │ ├── control │ ├── install │ └── rules │ ├── system76-cudnn-11.1 │ ├── changelog │ ├── control │ ├── install │ └── rules │ ├── system76-cudnn-11.2 │ ├── changelog │ ├── control │ ├── install │ └── rules │ ├── system76-nccl-11.1 │ ├── changelog │ ├── control │ ├── install │ └── rules │ └── system76-nccl-11.2 │ ├── changelog │ ├── control │ ├── install │ └── rules ├── keys └── system76-pop.asc ├── metapackages ├── focal │ ├── system76-cuda-latest.cfg │ └── system76-cudnn-latest.cfg ├── groovy │ ├── system76-cuda-latest.cfg │ └── system76-cudnn-latest.cfg └── impish │ └── system76-cuda-latest.cfg └── suites ├── focal.toml ├── groovy.toml └── impish.toml /.gitignore: -------------------------------------------------------------------------------- 1 | assets/cache 2 | assets/packages/system76-cuda-*/installer* 3 | assets/packages/system76-cuda-*/patch* 4 | assets/packages/system76-cudnn-* 5 | build 6 | record 7 | repo 8 | sources 9 | logs 10 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # System76 CUDA SDK + Tensorflow Packaging 2 | 3 | Due to issues with how NVIDIA and Canonical package the CUDA toolkit, System76 is offering better 4 | packaging for our users. This provides all of the debian packaging information needed to build 5 | multiple versions of the CUDA toolkit in parallel, where the resulting packages may be installed 6 | alongside each other. Users that install multiple toolkits only need to use `update-alternatives` 7 | to switch between different versions of the toolkit. 8 | 9 | > This repository is designed around our [debrep](https://github.com/pop-os/debrepbuild) tool. It 10 | provides the means to generate and maintain apt repositories based on a TOML spec and file system 11 | hierarchy. Using debrep, the data contained in the assets and debian directories are merged 12 | together and built with `sbuild`, then stored in a repo pool. 13 | 14 | ## tensorflow-{cuda,cpu} 15 | 16 | These packages are built with C, C++, and Python support. Similar to the CUDA packaging, it is 17 | possible to alternate between different versions of Tensorflow. We backport fixes to older 18 | versions of Tensorflow when possible. The build system we use is based on 19 | [FloopCZ's work on a Cmake build system](https://github.com/FloopCZ/tensorflow_cc). 20 | 21 | ## system76-cuda Metapackage 22 | 23 | The `cuda` directory contains the metapackage required by each of the toolkits. This installs the 24 | required shared development dependencies, as well as some system configuration files to get toolkits 25 | working out of the box. This package should be built and installed first on the build server. 26 | 27 | ## system76-cuda-X.Y Packages 28 | 29 | The `cuda-X.Y` directories contain the specific versions of the toolkit, which depend upon the 30 | `system76-cuda` metapackage built from the `cuda` directory. These can be built and installed in 31 | parallel, as there are no conflicting files. `update-alternatives` is used post-install to add a 32 | new entry for the symlink at `/usr/lib/cuda`. Each `cuda-X.Y` directory contains its own Makefile, 33 | which will download the installer & patches for that release, if they are not already located in 34 | the directory. 35 | 36 | ## Listing & Switching Between Toolkits 37 | 38 | The `update-alternatives` command may be used to view installed toolkits, and switch between them. 39 | 40 | ``` 41 | sudo update-alternatives --list cuda 42 | sudo update-alternatives --config cuda 43 | ``` 44 | 45 | You may verify that you have the correct toolkit active by checking the `version.txt` file 46 | associated with that release of the toolkit: 47 | 48 | ``` 49 | $ cat /usr/lib/cuda/version.txt 50 | CUDA Version 9.2.88 51 | CUDA Patch Version 9.2.88.1 52 | ``` 53 | -------------------------------------------------------------------------------- /acquire_assets.sh: -------------------------------------------------------------------------------- 1 | #!/usr/bin/env bash 2 | 3 | set -ex 4 | 5 | PACKAGES="assets/packages" 6 | 7 | function fetch { 8 | echo LOCATION = $1 9 | echo URL = $2 10 | echo CHECKSUM = $3 11 | 12 | mkdir $(dirname $1) -p 13 | CHECKSUM=$(sha256sum $1 | cut -d' ' -f1) 14 | if [ ! $CHECKSUM ] || [ $CHECKSUM != $3 ]; then 15 | wget $2 -O $1 16 | if [ $(sha256sum $1 | cut -d' ' -f1) != $3 ]; then 17 | echo checksum does not match 18 | exit 1; 19 | fi 20 | fi 21 | } 22 | 23 | function fetch_patches { 24 | REMOTE_PATCH_DIR=$1/patches 25 | CUDA_VERSION=$2 26 | 27 | N=1; 28 | for patch in $3; do 29 | REMOTE_PATCH=$REMOTE_PATCH_DIR/$(echo $patch | cut -d'=' -f1) 30 | CHECKSUM=$(echo $patch | cut -d'=' -f2) 31 | PATCH=$EXTRACT_DIR/patch-$CUDA_VERSION-$N.run 32 | N=$((N + 1)) 33 | 34 | fetch $PATCH $REMOTE_PATCH $CHECKSUM 35 | chmod +x $PATCH 36 | done 37 | } 38 | 39 | function get_toolkit { 40 | CUDA_VERSION=$1 41 | INSTALLER=$2 42 | 43 | EXTRACT_DIR=$PACKAGES/system76-cuda-${CUDA_VERSION:0:4} 44 | SCRIPT=$EXTRACT_DIR/installer-${CUDA_VERSION:0:4} 45 | 46 | if test "$3" = "v3"; then 47 | INSTALLER_SUM=$4 48 | REMOTE_CUDA_DIR=https://developer.download.nvidia.com/compute/cuda/${CUDA_VERSION} 49 | elif test "$3" = "v2"; then 50 | INSTALLER_SUM=$4 51 | PATCHES=$5 52 | REMOTE_CUDA_DIR=https://developer.download.nvidia.com/compute/cuda/${CUDA_VERSION}/Prod 53 | else 54 | INSTALLER_SUM=$3 55 | PATCHES=$4 56 | REMOTE_CUDA_DIR=https://developer.nvidia.com/compute/cuda/${CUDA_VERSION}/Prod 57 | fi 58 | 59 | INSTALLER_URL=${REMOTE_CUDA_DIR}/local_installers/${INSTALLER} 60 | 61 | mkdir $EXTRACT_DIR -p 62 | fetch_patches $REMOTE_CUDA_DIR ${CUDA_VERSION} $PATCHES 63 | fetch $SCRIPT $INSTALLER_URL $INSTALLER_SUM 64 | chmod +x $SCRIPT 65 | } 66 | 67 | get_cudnn () { 68 | fetch "$PACKAGES/system76-cudnn-$1/cudnn.tgz" \ 69 | "http://developer.download.nvidia.com/compute/redist/cudnn/v$2/cudnn-$1-linux-x64-v$3.tgz" $4 70 | } 71 | 72 | get_cudnn "9.0" "7.6.5" "7.6.5.32" "bd0a4c0090d5b02feec3f195738968690cc2470b9bc6026e6fe8ff245cd261c8" 73 | get_cudnn "9.2" "7.6.5" "7.6.5.32" "a2a2c7a8ba7b16d323b651766ee37dcfdbc2b50d920f73f8fde85005424960e4" 74 | get_cudnn "10.1" "8.0.4" "8.0.4.30" "eb4b888e61715168f57a0a0a21c281ada6856b728e5112618ed15f8637487715" 75 | get_cudnn "10.2" "8.0.4" "8.0.4.30" "c12c69eb16698eacac40aa46b9ce399d4cd86efb6ff0c105142f8a28fcfb980e" 76 | get_cudnn "11.1" "8.0.4" "8.0.4.30" "8f4c662343afce5998ce963500fe3bb167e9a508c1a1a949d821a4b80fa9beab" 77 | get_cudnn "11.2" "8.1.1" "8.1.1.33" "98a8784e92862f20018d20c281b30d4a0cd951f93694f6433ccf4ae9c502ba6a" 78 | 79 | 80 | get_toolkit 9.0 \ 81 | cuda_9.0.176_384.81_linux-run \ 82 | "96863423feaa50b5c1c5e1b9ec537ef7ba77576a3986652351ae43e66bcd080c" \ 83 | "/1/cuda_9.0.176.1_linux-run=a4bf63e08f01fcbdfa9ff147f54e45a84a3a70e571b28d2d62e9277c4f7a78ed \ 84 | /2/cuda_9.0.176.2_linux-run=ec345f6d17d52c0ab6ea296ec389efdabca2ca56bddde8723bcea7be646ce5eb \ 85 | /3/cuda_9.0.176.3_linux-run=429e2c30da8021ec10f047ce475bc628832a5f93110f5cf487f2327dfb1aa8ca" 86 | 87 | get_toolkit 9.1 \ 88 | cuda_9.1.85_387.26_linux \ 89 | "8496c72b16fee61889f9281449b5d633d0b358b46579175c275d85c9205fe953" \ 90 | "/1/cuda_9.1.85.1_linux=af9ce3d7ce4ea3b9b075135640077695f420d5dc585d76cbdae09d658b8ca3b8 \ 91 | /2/cuda_9.1.85.2_linux=d59f07a35ba750fc8ab04e144e7556d03b57a4f1a0060f895615af0113e0e099 \ 92 | /3/cuda_9.1.85.3_linux=421094368e4732677e5963d790fa161be2586ed90b291988477f8c8f9cd9ac8a" 93 | 94 | get_toolkit 9.2 \ 95 | cuda_9.2.88_396.26_linux \ 96 | "8d02cc2a82f35b456d447df463148ac4cc823891be8820948109ad6186f2667c" \ 97 | "/1/cuda_9.2.88.1_linux=d2f2d0e91959e4b9a93cd2fa82dced3541e3b8046c3ab7ae335d36f71dbbca13" 98 | 99 | get_toolkit 10.1 \ 100 | cuda_10.1.105_418.39_linux.run \ 101 | "33ac60685a3e29538db5094259ea85c15906cbd0f74368733f4111eab6187c8f" 102 | 103 | get_toolkit 10.2 \ 104 | cuda_10.2.89_440.33.01_linux.run \ 105 | "v2" \ 106 | "560d07fdcf4a46717f2242948cd4f92c5f9b6fc7eae10dd996614da913d5ca11" \ 107 | 108 | get_toolkit 11.1.1 \ 109 | cuda_11.1.1_455.32.00_linux.run \ 110 | "v3" \ 111 | "3eae6727086024925ebbcef3e9a45ad379d8490768fd00f9c2d8b6fd9cd8dd8f" 112 | 113 | get_toolkit 11.2.0 \ 114 | cuda_11.2.0_460.27.04_linux.run \ 115 | "v3" \ 116 | "9c50283241ac325d3085289ed9b9c170531369de41165ce271352d4a898cbdce" -------------------------------------------------------------------------------- /assets/packages/system76-cuda-9.2/fetch-cuda-samples: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -x 4 | 5 | CHECKSUM=0c67bf836eb11033e3c1aeea8d37e889 6 | CUDA_VERSION=9.2 7 | TMP_FILE=/tmp/cuda-samples-${CUDA_VERSION}.tar.gz 8 | 9 | # Fetch 9.2 samples from NVIDIA's GitHub repository. 10 | wget https://github.com/NVIDIA/cuda-samples/archive/v${CUDA_VERSION}.tar.gz \ 11 | -O ${TMP_FILE} 12 | 13 | # Verify that the downloaded file is valid. 14 | if test ${CHECKSUM} = $(md5sum ${TMP_FILE} | cut -d' ' -f1); then 15 | tar -xzvf ${TMP_FILE} 16 | rm ${TMP_FILE} 17 | else 18 | rm ${TMP_FILE} 19 | echo "The downloaded CUDA ${CUDA_VERSION} samples did not have a valid checksum." 20 | exit 1 21 | fi 22 | -------------------------------------------------------------------------------- /assets/share/cuda_makefile: -------------------------------------------------------------------------------- 1 | SCRIPT = installer-$(CUDA_VERSION) 2 | REMOTE_CUDA_DIR = https://developer.nvidia.com/compute/cuda/$(CUDA_VERSION)/Prod 3 | INSTALLER_URL = $(REMOTE_CUDA_DIR)/local_installers/$(INSTALLER) 4 | CUDA_DIR = cuda-$(CUDA_VERSION) 5 | 6 | PREFIX ?= /usr/lib 7 | 8 | BEFORE = $(DESTDIR)$(PREFIX) 9 | .PHONY: all clean install 10 | 11 | all: 12 | # Download the installer if it does not already exist, or has an invalid checksum 13 | if [ ! -f $(SCRIPT) ] || [ $(shell md5sum $(SCRIPT) | cut -d' ' -f1) != $(INSTALLER_SUM) ]; then \ 14 | echo installer checksum does not match; \ 15 | exit 1; \ 16 | fi 17 | 18 | clean: 19 | 20 | install: 21 | mkdir -p $(BEFORE)/$(CUDA_DIR) 22 | ./$(SCRIPT) --silent --override \ 23 | --no-opengl-libs --no-drm \ 24 | --toolkit --toolkitpath=$(BEFORE)/$(CUDA_DIR) 25 | 26 | # Install all of the patches for this version. 27 | if ls | grep patch; then \ 28 | for patch in patch-$(CUDA_VERSION)-*.run; do \ 29 | sh $$patch --accept-eula --silent \ 30 | --installdir=$(BEFORE)/$(CUDA_DIR); \ 31 | done \ 32 | fi 33 | 34 | # Fix the paths due to the packaging destination differing from the actual system destination. 35 | find $(BEFORE)/$(CUDA_DIR) -type f \ 36 | -not -name '*.so' -not -name '*.a' \ 37 | -exec sed -i -e 's#$(BEFORE)#$(PREFIX)#g; s#usr/local#$(PREFIX)#g' {} \; 38 | -------------------------------------------------------------------------------- /assets/share/cuda_makefile_v2: -------------------------------------------------------------------------------- 1 | SCRIPT = installer-$(CUDA_VERSION) 2 | REMOTE_CUDA_DIR = https://developer.nvidia.com/compute/cuda/$(CUDA_VERSION)/Prod 3 | INSTALLER_URL = $(REMOTE_CUDA_DIR)/local_installers/$(INSTALLER) 4 | CUDA_DIR = cuda-$(CUDA_VERSION) 5 | 6 | PREFIX ?= /usr/lib 7 | 8 | BEFORE = $(DESTDIR)$(PREFIX) 9 | .PHONY: all clean install 10 | 11 | all: 12 | # Download the installer if it does not already exist, or has an invalid checksum 13 | if [ ! -f $(SCRIPT) ] || [ $(shell md5sum $(SCRIPT) | cut -d' ' -f1) != $(INSTALLER_SUM) ]; then \ 14 | echo installer checksum does not match; \ 15 | exit 1; \ 16 | fi 17 | 18 | clean: 19 | 20 | install: 21 | mkdir -p $(BEFORE)/$(CUDA_DIR) build 22 | 23 | ./$(SCRIPT) --override --extract=$(PWD)/build 24 | 25 | mv build/cuda-toolkit/* $(BEFORE)/$(CUDA_DIR)/ 26 | 27 | if test -e build/cuda-samples; then \ 28 | mv build/cuda-samples $(BEFORE)/$(CUDA_DIR)/samples; \ 29 | fi 30 | 31 | if test -e build/cublas; then \ 32 | cp -a build/cublas/include/* $(BEFORE)/$(CUDA_DIR)/include/; \ 33 | cp -a build/cublas/lib64/* $(BEFORE)/$(CUDA_DIR)/lib64/; \ 34 | rm -R build/cublas/include build/cublas/lib64; \ 35 | cp -a build/cublas/* $(BEFORE)/$(CUDA_DIR)/; \ 36 | fi 37 | 38 | if test -e build/EULA.txt; then \ 39 | mv build/EULA.txt $(BEFORE)/$(CUDA_DIR)/; \ 40 | fi 41 | 42 | # Install all of the patches for this version. 43 | if ls | grep patch; then \ 44 | for patch in patch-$(CUDA_VERSION)-*.run; do \ 45 | sh $$patch --accept-eula --silent \ 46 | --installdir=$(BEFORE)/$(CUDA_DIR); \ 47 | done \ 48 | fi 49 | 50 | # Fix the paths due to the packaging destination differing from the actual system destination. 51 | find $(BEFORE)/$(CUDA_DIR) -type f \ 52 | -not -name '*.so' -not -name '*.a' \ 53 | -exec sed -i -e 's#$(BEFORE)#$(PREFIX)#g; s#usr/local#$(PREFIX)#g' {} \; 54 | 55 | # Add missing symlinks 56 | for file in $$(find $(BEFORE)/$(CUDA_DIR)/lib64/ -name '*.so'); do \ 57 | test -f $${file}.$(CUDA_VERSION) || ln -s $$(basename $$file) $${file}.$(CUDA_VERSION); \ 58 | done 59 | -------------------------------------------------------------------------------- /assets/share/cuda_makefile_v3: -------------------------------------------------------------------------------- 1 | SCRIPT = installer-$(CUDA_VERSION) 2 | REMOTE_CUDA_DIR = https://developer.nvidia.com/compute/cuda/$(CUDA_VERSION)/Prod 3 | INSTALLER_URL = $(REMOTE_CUDA_DIR)/local_installers/$(INSTALLER) 4 | CUDA_DIR = cuda-$(CUDA_VERSION) 5 | 6 | PREFIX ?= /usr/lib 7 | 8 | BEFORE = $(DESTDIR)$(PREFIX) 9 | .PHONY: all clean install 10 | 11 | all: 12 | # Download the installer if it does not already exist, or has an invalid checksum 13 | if [ ! -f $(SCRIPT) ] || [ $(shell md5sum $(SCRIPT) | cut -d' ' -f1) != $(INSTALLER_SUM) ]; then \ 14 | echo installer checksum does not match; \ 15 | exit 1; \ 16 | fi 17 | 18 | clean: 19 | 20 | install: 21 | mkdir -p $(BEFORE)/$(CUDA_DIR) build 22 | 23 | ./installer-$(CUDA_VERSION) --override --extract=$(PWD)/build 24 | 25 | mv build/cuda_samples $(BEFORE)/$(CUDA_DIR)/samples 26 | cd build; mv bin integration nsight_compute nsight_systems EULA.txt $(BEFORE)/$(CUDA_DIR)/ 27 | 28 | for module in build/cuda_* build/lib*; do \ 29 | cp -a $${module}/* $(BEFORE)/$(CUDA_DIR)/; \ 30 | rm -rf $${module}; \ 31 | done 32 | 33 | ls $(BEFORE)/$(CUDA_DIR) 34 | 35 | # Fix the paths due to the packaging destination differing from the actual system destination. 36 | find $(BEFORE)/$(CUDA_DIR) -type f \ 37 | -not -name '*.so' -not -name '*.a' \ 38 | -exec sed -i -e 's#$(BEFORE)#$(PREFIX)#g; s#usr/local#$(PREFIX)#g' {} \; 39 | 40 | # Add missing symlinks 41 | for file in $$(find $(BEFORE)/$(CUDA_DIR)/lib64/ -name '*.so'); do \ 42 | test -f $${file}.$(CUDA_VERSION) || ln -s $$(basename $$file) $${file}.$(CUDA_VERSION); \ 43 | done 44 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.11/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | project( 3 | "tensorflow_cc" 4 | VERSION 1.11.0 5 | ) 6 | 7 | # Static library with no GPU support is built by default. 8 | # Use the following option to build a shared library with GPU support. 9 | # If enabled, bazel has to be installed. 10 | option(TENSORFLOW_SHARED "Build shared library (required for GPU support)." OFF) 11 | option(TENSORFLOW_STATIC "Build static library." ON) 12 | set(TENSORFLOW_TAG "v1.11.0" CACHE STRING "The tensorflow release tag to be checked out (default v1.11.0).") 13 | option(SYSTEM_PROTOBUF "Use system protobuf instead of static protobuf from contrib/makefile." OFF) 14 | 15 | # ------------- 16 | # CMake Options 17 | # ------------- 18 | 19 | list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") 20 | set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/lib") 21 | set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/lib") 22 | include(CMakePackageConfigHelpers) 23 | set(CMAKECFG_INSTALL_DIR lib/cmake/TensorflowCC) 24 | 25 | # -------------------------------------------------------- 26 | # Include External Projects for Shared / Static Tensorflow 27 | # -------------------------------------------------------- 28 | 29 | include(TensorflowBase) 30 | if(TENSORFLOW_SHARED) 31 | include(TensorflowShared) 32 | endif() 33 | if(TENSORFLOW_STATIC) 34 | include(TensorflowStatic) 35 | # Add shared lib as dependency to avoid race 36 | if(TENSORFLOW_SHARED) 37 | add_dependencies( 38 | tensorflow_static 39 | tensorflow_shared 40 | ) 41 | endif() 42 | endif() 43 | 44 | # ---------------------------------- 45 | # Define Shared Tensorflow Interface 46 | # ---------------------------------- 47 | if(SYSTEM_PROTOBUF) 48 | find_package(Protobuf REQUIRED) 49 | endif() 50 | 51 | # ---------------------------------- 52 | # Define Shared Tensorflow Interface 53 | # ---------------------------------- 54 | 55 | if(TENSORFLOW_SHARED) 56 | add_library(tensorflow_cc_shared INTERFACE) 57 | target_compile_options( 58 | tensorflow_cc_shared INTERFACE 59 | "$<$:-std=c++11>" 60 | ) 61 | add_dependencies( 62 | tensorflow_cc_shared 63 | tensorflow_shared 64 | ) 65 | target_include_directories( 66 | tensorflow_cc_shared INTERFACE 67 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow" 68 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/bazel-genfiles" 69 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/bazel-genfiles/genfiles" 70 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads" 71 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/eigen" 72 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/gemmlowp" 73 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/nsync/public" 74 | ) 75 | target_link_libraries( 76 | tensorflow_cc_shared INTERFACE 77 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libtensorflow_cc.so" 78 | dl pthread 79 | ) 80 | if(SYSTEM_PROTOBUF) 81 | target_include_directories( 82 | tensorflow_cc_shared INTERFACE 83 | "${Protobuf_INCLUDE_DIRS}" 84 | ) 85 | target_link_libraries( 86 | tensorflow_cc_shared INTERFACE 87 | "${Protobuf_LIBRARIES}" 88 | ) 89 | else() 90 | target_include_directories( 91 | tensorflow_cc_shared INTERFACE 92 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/include" 93 | ) 94 | target_link_libraries( 95 | tensorflow_cc_shared INTERFACE 96 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libprotobuf.a" 97 | ) 98 | endif() 99 | endif() 100 | 101 | # ---------------------------------- 102 | # Define Static Tensorflow Interface 103 | # ---------------------------------- 104 | 105 | if(TENSORFLOW_STATIC) 106 | add_library(tensorflow_cc_static INTERFACE) 107 | target_compile_options( 108 | tensorflow_cc_static INTERFACE 109 | "$<$:-std=c++11>" 110 | ) 111 | add_dependencies( 112 | tensorflow_cc_static 113 | tensorflow_static 114 | ) 115 | target_include_directories( 116 | tensorflow_cc_static INTERFACE 117 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow" 118 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/host_obj" 119 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads" 120 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/eigen" 121 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/gemmlowp" 122 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/nsync/public" 123 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/proto" 124 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/proto_text" 125 | ) 126 | target_link_libraries( 127 | tensorflow_cc_static INTERFACE 128 | "-Wl,--allow-multiple-definition" 129 | "-Wl,--whole-archive ${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libtensorflow-core.a" 130 | "-Wl,--no-whole-archive" 131 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/nsync.a" 132 | dl pthread 133 | ) 134 | if(SYSTEM_PROTOBUF) 135 | target_include_directories( 136 | tensorflow_cc_static INTERFACE 137 | "${Protobuf_INCLUDE_DIRS}" 138 | ) 139 | target_link_libraries( 140 | tensorflow_cc_static INTERFACE 141 | "${Protobuf_LIBRARIES}" 142 | ) 143 | else() 144 | target_include_directories( 145 | tensorflow_cc_static INTERFACE 146 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/include" 147 | ) 148 | target_link_libraries( 149 | tensorflow_cc_static INTERFACE 150 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libprotobuf.a" 151 | ) 152 | endif() 153 | endif() 154 | 155 | # ---------------------------------------- 156 | # Configure CMake Config and Version Files 157 | # ---------------------------------------- 158 | 159 | write_basic_package_version_file( 160 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfigVersion.cmake" 161 | VERSION ${PROJECT_VERSION} 162 | COMPATIBILITY SameMajorVersion 163 | ) 164 | configure_package_config_file( 165 | "${CMAKE_CURRENT_SOURCE_DIR}/cmake/TensorflowCCConfig.cmake.in" 166 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfig.cmake" 167 | INSTALL_DESTINATION "${CMAKECFG_INSTALL_DIR}" 168 | NO_SET_AND_CHECK_MACRO # TensorflowCC only uses interface libraries 169 | NO_CHECK_REQUIRED_COMPONENTS_MACRO # TensorflowCC does not have components 170 | ) 171 | 172 | # ------- 173 | # Install 174 | # ------- 175 | 176 | # install all header files 177 | install( 178 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/" 179 | DESTINATION include/tensorflow 180 | FILES_MATCHING PATTERN "*.h" 181 | ) 182 | # install all header files downloaded by contrib/makefile 183 | # (Note that we cannot simply include all *.h or *.hpp files, since e.g., eigen 184 | # does not use file extensions for header files.) 185 | install( 186 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/downloads/" 187 | DESTINATION include/tensorflow/tensorflow/contrib/makefile/downloads 188 | FILES_MATCHING PATTERN "*" 189 | PATTERN "Makefile*" EXCLUDE 190 | PATTERN "*unittest*" EXCLUDE 191 | PATTERN "*.o" EXCLUDE 192 | PATTERN "*.so" EXCLUDE 193 | PATTERN "*.so.*" EXCLUDE 194 | PATTERN "*.a" EXCLUDE 195 | PATTERN "*.tbz" EXCLUDE 196 | PATTERN "*.tgz" EXCLUDE 197 | PATTERN "*.tar" EXCLUDE 198 | PATTERN "*.tar.*" EXCLUDE 199 | PATTERN "*.zip" EXCLUDE 200 | ) 201 | # install all files from third_party folder (e.g., Eigen/Tensor) 202 | install( 203 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/third_party/" 204 | DESTINATION include/tensorflow/third_party 205 | ) 206 | # install static libprotobuf from contrib/makefile 207 | if (NOT SYSTEM_PROTOBUF) 208 | install( 209 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/lib/libprotobuf.a" 210 | DESTINATION lib/tensorflow_cc 211 | ) 212 | endif() 213 | # shared library specific 214 | if(TENSORFLOW_SHARED) 215 | install( 216 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/bazel-bin/tensorflow/libtensorflow_cc.so" 217 | DESTINATION lib/tensorflow_cc 218 | ) 219 | endif() 220 | # static library specific 221 | if(TENSORFLOW_STATIC) 222 | install( 223 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/gen/lib/libtensorflow-core.a" 224 | "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/downloads/nsync/builds/default.linux.c++11/nsync.a" 225 | DESTINATION lib/tensorflow_cc 226 | ) 227 | endif() 228 | 229 | # -------------------------- 230 | # Install CMake targets file 231 | # -------------------------- 232 | 233 | if(TENSORFLOW_SHARED) 234 | set_target_properties( 235 | tensorflow_cc_shared PROPERTIES EXPORT_NAME Shared 236 | ) 237 | install( 238 | TARGETS tensorflow_cc_shared 239 | EXPORT TensorflowCCSharedTargets 240 | ) 241 | install( 242 | EXPORT TensorflowCCSharedTargets 243 | FILE TensorflowCCSharedTargets.cmake 244 | NAMESPACE TensorflowCC:: 245 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 246 | ) 247 | endif() 248 | if(TENSORFLOW_STATIC) 249 | set_target_properties( 250 | tensorflow_cc_static PROPERTIES EXPORT_NAME Static 251 | ) 252 | install( 253 | TARGETS tensorflow_cc_static 254 | EXPORT TensorflowCCStaticTargets 255 | ) 256 | install( 257 | EXPORT TensorflowCCStaticTargets 258 | FILE TensorflowCCStaticTargets.cmake 259 | NAMESPACE TensorflowCC:: 260 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 261 | ) 262 | endif() 263 | 264 | # install config and version files 265 | install( 266 | FILES 267 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfig.cmake" 268 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfigVersion.cmake" 269 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 270 | ) 271 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.11/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017 Filip Matzner 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.11/cmake/TensorflowBase.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | set(OLD_PROTOBUF "https://mirror.bazel.build/github.com/google/protobuf/archive/396336eb961b75f03b25824fe86cf6490fb75e3a.tar.gz") 5 | set(FIXED_PROTOBUF "https://github.com/protocolbuffers/protobuf/releases/download/v3.6.0/protobuf-all-3.6.0.tar.gz") 6 | 7 | ExternalProject_Add( 8 | tensorflow_base 9 | GIT_REPOSITORY https://github.com/tensorflow/tensorflow.git 10 | GIT_TAG "${TENSORFLOW_TAG}" 11 | TMP_DIR "/tmp" 12 | STAMP_DIR "tensorflow-stamp" 13 | DOWNLOAD_DIR "tensorflow" 14 | SOURCE_DIR "tensorflow" 15 | BUILD_IN_SOURCE 1 16 | UPDATE_COMMAND "" 17 | CONFIGURE_COMMAND make -f tensorflow/contrib/makefile/Makefile clean 18 | # Fix github.com/tensorflow/tensorflow/issues/19840 19 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/stream.patch" . 20 | COMMAND patch -p1 < stream.patch 21 | 22 | # Fix Tensorflow providing the wrong version of protobuf 23 | COMMAND sed -i "s#${OLD_PROTOBUF}#${FIXED_PROTOBUF}#g" tensorflow/contrib/makefile/download_dependencies.sh 24 | 25 | COMMAND tensorflow/contrib/makefile/download_dependencies.sh 26 | BUILD_COMMAND "" 27 | INSTALL_COMMAND "" 28 | ) 29 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.11/cmake/TensorflowCCConfig.cmake.in: -------------------------------------------------------------------------------- 1 | @PACKAGE_INIT@ 2 | 3 | if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/TensorflowCCSharedTargets.cmake") 4 | include("${CMAKE_CURRENT_LIST_DIR}/TensorflowCCSharedTargets.cmake") 5 | set(TensorflowCC_Shared_FOUND ON) 6 | endif() 7 | 8 | if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/TensorflowCCStaticTargets.cmake") 9 | include("${CMAKE_CURRENT_LIST_DIR}/TensorflowCCStaticTargets.cmake") 10 | set(TensorflowCC_Static_FOUND ON) 11 | endif() 12 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.11/cmake/TensorflowShared.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | ExternalProject_Add( 5 | tensorflow_shared 6 | DEPENDS tensorflow_base 7 | TMP_DIR "/tmp" 8 | STAMP_DIR "tensorflow-stamp" 9 | SOURCE_DIR "tensorflow" 10 | BUILD_IN_SOURCE 1 11 | DOWNLOAD_COMMAND "" 12 | UPDATE_COMMAND "" 13 | CONFIGURE_COMMAND tensorflow/contrib/makefile/compile_linux_protobuf.sh 14 | # patch nsync to use g++-7 15 | COMMAND sed -i "s/ g++/ g++-7/g" tensorflow/contrib/makefile/compile_nsync.sh 16 | COMMAND tensorflow/contrib/makefile/compile_nsync.sh 17 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/build_tensorflow.sh" . 18 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/copy_links.sh" . 19 | COMMAND ./build_tensorflow.sh 20 | COMMAND ./copy_links.sh . 21 | BUILD_COMMAND "" 22 | INSTALL_COMMAND "" 23 | ) 24 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.11/cmake/TensorflowStatic.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | ExternalProject_Add( 5 | tensorflow_static 6 | DEPENDS tensorflow_base 7 | TMP_DIR "/tmp" 8 | STAMP_DIR "tensorflow-stamp" 9 | SOURCE_DIR "tensorflow" 10 | BUILD_IN_SOURCE 1 11 | DOWNLOAD_COMMAND "" 12 | UPDATE_COMMAND "" 13 | CONFIGURE_COMMAND tensorflow/contrib/makefile/build_all_linux.sh 14 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/copy_links.sh" . 15 | COMMAND ./copy_links.sh . 16 | BUILD_COMMAND "" 17 | INSTALL_COMMAND "" 18 | ) 19 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.11/cmake/build_tensorflow.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | # Test whether one version ($1) is less than or equal to other ($2). 5 | function version_gt { 6 | test "`printf '%s\n' "$@" | sort -V | head -n 1`" != "$1" 7 | } 8 | 9 | # configure environmental variables 10 | export CC_OPT_FLAGS=${CC_OPT_FLAGS:-"-march=ivybridge"} 11 | export TF_NEED_GCP=${TF_NEED_GCP:-0} 12 | export TF_NEED_HDFS=${TF_NEED_HDFS:-0} 13 | export TF_NEED_OPENCL=${TF_NEED_OPENCL:-0} 14 | export TF_NEED_OPENCL_SYCL=${TF_NEED_OPENCL_SYCL:-0} 15 | export TF_NEED_TENSORRT=${TF_NEED_TENSORRT:-0} 16 | export TF_NEED_JEMALLOC=${TF_NEED_JEMALLOC:-1} 17 | export TF_NEED_VERBS=${TF_NEED_VERBS:-0} 18 | export TF_NEED_MKL=${TF_NEED_MKL:-1} 19 | export TF_DOWNLOAD_MKL=${TF_DOWNLOAD_MKL:-1} 20 | export TF_NEED_MPI=${TF_NEED_MPI:-0} 21 | export TF_ENABLE_XLA=${TF_ENABLE_XLA:-1} 22 | export TF_NEED_S3=${TF_NEED_S3:-0} # TODO: Remove when replaced by the next line. 23 | export TF_NEED_AWS=${TF_NEED_AWS:-0} 24 | export TF_NEED_GDR=${TF_NEED_GDR:-0} 25 | export TF_CUDA_CLANG=${TF_CUDA_CLANG:-0} 26 | export TF_SET_ANDROID_WORKSPACE=${TF_SET_ANDROID_WORKSPACE:-0} 27 | export TF_NEED_KAFKA=${TF_NEED_KAFKA:-0} 28 | export TF_DOWNLOAD_CLANG=${TF_DOWNLOAD_CLANG:-0} 29 | export TF_NCCL_VERSION=${TF_NCCL_VERSION:-1.3} # _DEFAULT_NCCL_VERSION from configure.py 30 | export PYTHON_BIN_PATH=${PYTHON_BIN_PATH:-"$(which python3)"} 31 | export PYTHON_LIB_PATH="$($PYTHON_BIN_PATH -c 'import site; print(site.getsitepackages()[0])')" 32 | 33 | export CUDNN_INSTALL_PATH=$CUDA_TOOLKIT_PATH 34 | 35 | if [ -n "${CUDA_TOOLKIT_PATH}" ]; then 36 | if [[ -z "${CUDNN_INSTALL_PATH}" ]]; then 37 | echo "CUDA found but no cudnn.h found. Please install cuDNN." 38 | exit 1 39 | fi 40 | echo "CUDA support enabled" 41 | cuda_config_opts="--config=cuda" 42 | export TF_NEED_CUDA=1 43 | export TF_CUDA_COMPUTE_CAPABILITIES=${TF_CUDA_COMPUTE_CAPABILITIES:-"3.5,5.2,6.1,6.2"} 44 | export TF_CUDA_VERSION="$($CUDA_TOOLKIT_PATH/bin/nvcc --version | sed -n 's/^.*release \(.*\),.*/\1/p')" 45 | export TF_CUDNN_VERSION="$(sed -n 's/^#define CUDNN_MAJOR\s*\(.*\).*/\1/p' $CUDNN_INSTALL_PATH/include/cudnn.h)" 46 | 47 | # choose the right version of CUDA compiler 48 | if [ -z "$GCC_HOST_COMPILER_PATH" ]; then 49 | if hash gcc-7 2>/dev/null && version_gt 7.4 `gcc-7 -dumpversion`; then 50 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-7"} 51 | elif hash gcc-6 2>/dev/null && version_gt 6.4 `gcc-6 -dumpversion`; then 52 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-6"} 53 | elif hash gcc-5 2>/dev/null && version_gt 5.5 `gcc-5 -dumpversion`; then 54 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-5"} 55 | elif hash gcc-4 2>/dev/null && version_gt 4.9 `gcc-4 -dumpversion`; then 56 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-4"} 57 | else 58 | echo "No supported CUDA compiler available. If you are sure your compiler" 59 | echo "version is supported by your CUDA version, please run e.g.:" 60 | echo "export GCC_HOST_COMPILER_PATH=/usr/bin/gcc" 61 | echo "before the build. For the list of supported compilers refer to:" 62 | echo "https://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html" 63 | exit 1 64 | fi 65 | fi 66 | 67 | export CLANG_CUDA_COMPILER_PATH=${CLANG_CUDA_COMPILER_PATH:-"/usr/bin/clang"} 68 | export TF_CUDA_CLANG=${TF_CUDA_CLANG:-0} 69 | else 70 | echo "CUDA support disabled" 71 | cuda_config_opts="" 72 | export TF_NEED_CUDA=0 73 | fi 74 | 75 | # configure and build 76 | ./configure 77 | 78 | bazel build --config=opt \ 79 | --config=monolithic \ 80 | $cuda_config_opts \ 81 | tensorflow:libtensorflow_cc.so 82 | 83 | bazel build --config=opt \ 84 | --config=monolithic \ 85 | $cuda_config_opts \ 86 | //tensorflow:libtensorflow.so 87 | 88 | # Python API 89 | bazel build --config=opt \ 90 | --config=monolithic \ 91 | $cuda_config_opts \ 92 | //tensorflow/tools/pip_package:build_pip_package 93 | 94 | bazel shutdown 95 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.11/cmake/copy_links.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | # This file recursively traverses a directory and replaces each 4 | # link by a copy of its target. 5 | 6 | echo "Replacing links with the copies of their targets." 7 | echo "This may take a while..." 8 | # To properly handle whitespace characters in filenames, we need to use 9 | # an ugly `find` and `read` trick. 10 | find -L "$1" -depth -print0 | 11 | while IFS= read -r -d $'\0' f; do 12 | # We need to check whether the file is still a link. 13 | # It may have happened that we have already replaced it by 14 | # the original when some of its parent directories were copied. 15 | # Also the first check is to detect whether the file (after 16 | # symlink dereference) exists so that `realpath` does not fail. 17 | if [[ -w "$f" ]] && [[ -L "$f" ]]; then 18 | realf="$(realpath "$f")" 19 | rm "$f" 20 | cp -r --link "$realf" "$f" 2>/dev/null || cp -r "$realf" "$f" 21 | fi 22 | done 23 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.11/stream.patch: -------------------------------------------------------------------------------- 1 | --- ./tensorflow/tf_version_script.lds.old 2018-10-31 12:15:05.127429879 -0600 2 | +++ ./tensorflow/tf_version_script.lds 2018-10-31 12:15:32.347077298 -0600 3 | @@ -6,6 +6,7 @@ 4 | *TFE_*; 5 | *nsync_*; 6 | *pywrap_xla*; 7 | + *stream_executor*; 8 | local: 9 | *; 10 | }; 11 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.12/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | project( 3 | "tensorflow_cc" 4 | VERSION 1.12.0 5 | ) 6 | 7 | # Static library with no GPU support is built by default. 8 | # Use the following option to build a shared library with GPU support. 9 | # If enabled, bazel has to be installed. 10 | option(TENSORFLOW_SHARED "Build shared library (required for GPU support)." OFF) 11 | option(TENSORFLOW_STATIC "Build static library." ON) 12 | set(TENSORFLOW_TAG "v1.12.0" CACHE STRING "The tensorflow release tag to be checked out (default v1.12.0).") 13 | option(SYSTEM_PROTOBUF "Use system protobuf instead of static protobuf from contrib/makefile." OFF) 14 | 15 | # ------------- 16 | # CMake Options 17 | # ------------- 18 | 19 | list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") 20 | set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/lib") 21 | set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/lib") 22 | include(CMakePackageConfigHelpers) 23 | set(CMAKECFG_INSTALL_DIR lib/cmake/TensorflowCC) 24 | 25 | # -------------------------------------------------------- 26 | # Include External Projects for Shared / Static Tensorflow 27 | # -------------------------------------------------------- 28 | 29 | include(TensorflowBase) 30 | if(TENSORFLOW_SHARED) 31 | include(TensorflowShared) 32 | endif() 33 | if(TENSORFLOW_STATIC) 34 | include(TensorflowStatic) 35 | # Add shared lib as dependency to avoid race 36 | if(TENSORFLOW_SHARED) 37 | add_dependencies( 38 | tensorflow_static 39 | tensorflow_shared 40 | ) 41 | endif() 42 | endif() 43 | 44 | # ---------------------------------- 45 | # Define Shared Tensorflow Interface 46 | # ---------------------------------- 47 | if(SYSTEM_PROTOBUF) 48 | find_package(Protobuf REQUIRED) 49 | endif() 50 | 51 | # ---------------------------------- 52 | # Define Shared Tensorflow Interface 53 | # ---------------------------------- 54 | 55 | if(TENSORFLOW_SHARED) 56 | add_library(tensorflow_cc_shared INTERFACE) 57 | target_compile_options( 58 | tensorflow_cc_shared INTERFACE 59 | "$<$:-std=c++11>" 60 | ) 61 | add_dependencies( 62 | tensorflow_cc_shared 63 | tensorflow_shared 64 | ) 65 | target_include_directories( 66 | tensorflow_cc_shared INTERFACE 67 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow" 68 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/bazel-genfiles" 69 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/bazel-genfiles/genfiles" 70 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads" 71 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/absl" 72 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/eigen" 73 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/gemmlowp" 74 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/nsync/public" 75 | ) 76 | target_link_libraries( 77 | tensorflow_cc_shared INTERFACE 78 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libtensorflow_cc.so" 79 | dl pthread 80 | ) 81 | if(SYSTEM_PROTOBUF) 82 | target_include_directories( 83 | tensorflow_cc_shared INTERFACE 84 | "${Protobuf_INCLUDE_DIRS}" 85 | ) 86 | target_link_libraries( 87 | tensorflow_cc_shared INTERFACE 88 | "${Protobuf_LIBRARIES}" 89 | ) 90 | else() 91 | target_include_directories( 92 | tensorflow_cc_shared INTERFACE 93 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/include" 94 | ) 95 | target_link_libraries( 96 | tensorflow_cc_shared INTERFACE 97 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libprotobuf.a" 98 | ) 99 | endif() 100 | endif() 101 | 102 | # ---------------------------------- 103 | # Define Static Tensorflow Interface 104 | # ---------------------------------- 105 | 106 | if(TENSORFLOW_STATIC) 107 | add_library(tensorflow_cc_static INTERFACE) 108 | target_compile_options( 109 | tensorflow_cc_static INTERFACE 110 | "$<$:-std=c++11>" 111 | ) 112 | add_dependencies( 113 | tensorflow_cc_static 114 | tensorflow_static 115 | ) 116 | target_include_directories( 117 | tensorflow_cc_static INTERFACE 118 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow" 119 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/host_obj" 120 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads" 121 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/absl" 122 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/eigen" 123 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/gemmlowp" 124 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/nsync/public" 125 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/proto" 126 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/proto_text" 127 | ) 128 | target_link_libraries( 129 | tensorflow_cc_static INTERFACE 130 | "-Wl,--allow-multiple-definition" 131 | "-Wl,--whole-archive ${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libtensorflow-core.a" 132 | "-Wl,--no-whole-archive" 133 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/nsync.a" 134 | dl pthread 135 | ) 136 | if(SYSTEM_PROTOBUF) 137 | target_include_directories( 138 | tensorflow_cc_static INTERFACE 139 | "${Protobuf_INCLUDE_DIRS}" 140 | ) 141 | target_link_libraries( 142 | tensorflow_cc_static INTERFACE 143 | "${Protobuf_LIBRARIES}" 144 | ) 145 | else() 146 | target_include_directories( 147 | tensorflow_cc_static INTERFACE 148 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/include" 149 | ) 150 | target_link_libraries( 151 | tensorflow_cc_static INTERFACE 152 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libprotobuf.a" 153 | ) 154 | endif() 155 | endif() 156 | 157 | # ---------------------------------------- 158 | # Configure CMake Config and Version Files 159 | # ---------------------------------------- 160 | 161 | write_basic_package_version_file( 162 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfigVersion.cmake" 163 | VERSION ${PROJECT_VERSION} 164 | COMPATIBILITY SameMajorVersion 165 | ) 166 | configure_package_config_file( 167 | "${CMAKE_CURRENT_SOURCE_DIR}/cmake/TensorflowCCConfig.cmake.in" 168 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfig.cmake" 169 | INSTALL_DESTINATION "${CMAKECFG_INSTALL_DIR}" 170 | NO_SET_AND_CHECK_MACRO # TensorflowCC only uses interface libraries 171 | NO_CHECK_REQUIRED_COMPONENTS_MACRO # TensorflowCC does not have components 172 | ) 173 | 174 | # ------- 175 | # Install 176 | # ------- 177 | 178 | # install all header files 179 | install( 180 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/" 181 | DESTINATION include/tensorflow 182 | FILES_MATCHING PATTERN "*.h" 183 | ) 184 | # install all header files downloaded by contrib/makefile 185 | # (Note that we cannot simply include all *.h or *.hpp files, since e.g., eigen 186 | # does not use file extensions for header files.) 187 | install( 188 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/downloads/" 189 | DESTINATION include/tensorflow/tensorflow/contrib/makefile/downloads 190 | FILES_MATCHING PATTERN "*" 191 | PATTERN "Makefile*" EXCLUDE 192 | PATTERN "*unittest*" EXCLUDE 193 | PATTERN "*.o" EXCLUDE 194 | PATTERN "*.so" EXCLUDE 195 | PATTERN "*.so.*" EXCLUDE 196 | PATTERN "*.a" EXCLUDE 197 | PATTERN "*.tbz" EXCLUDE 198 | PATTERN "*.tgz" EXCLUDE 199 | PATTERN "*.tar" EXCLUDE 200 | PATTERN "*.tar.*" EXCLUDE 201 | PATTERN "*.zip" EXCLUDE 202 | ) 203 | # install all files from third_party folder (e.g., Eigen/Tensor) 204 | install( 205 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/third_party/" 206 | DESTINATION include/tensorflow/third_party 207 | ) 208 | # install static libprotobuf from contrib/makefile 209 | if (NOT SYSTEM_PROTOBUF) 210 | install( 211 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/lib/libprotobuf.a" 212 | DESTINATION lib/tensorflow_cc 213 | ) 214 | endif() 215 | # shared library specific 216 | if(TENSORFLOW_SHARED) 217 | install( 218 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/bazel-bin/tensorflow/libtensorflow_cc.so" 219 | DESTINATION lib/tensorflow_cc 220 | ) 221 | endif() 222 | # static library specific 223 | if(TENSORFLOW_STATIC) 224 | install( 225 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/gen/lib/libtensorflow-core.a" 226 | "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/downloads/nsync/builds/default.linux.c++11/nsync.a" 227 | DESTINATION lib/tensorflow_cc 228 | ) 229 | endif() 230 | 231 | # -------------------------- 232 | # Install CMake targets file 233 | # -------------------------- 234 | 235 | if(TENSORFLOW_SHARED) 236 | set_target_properties( 237 | tensorflow_cc_shared PROPERTIES EXPORT_NAME Shared 238 | ) 239 | install( 240 | TARGETS tensorflow_cc_shared 241 | EXPORT TensorflowCCSharedTargets 242 | ) 243 | install( 244 | EXPORT TensorflowCCSharedTargets 245 | FILE TensorflowCCSharedTargets.cmake 246 | NAMESPACE TensorflowCC:: 247 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 248 | ) 249 | endif() 250 | if(TENSORFLOW_STATIC) 251 | set_target_properties( 252 | tensorflow_cc_static PROPERTIES EXPORT_NAME Static 253 | ) 254 | install( 255 | TARGETS tensorflow_cc_static 256 | EXPORT TensorflowCCStaticTargets 257 | ) 258 | install( 259 | EXPORT TensorflowCCStaticTargets 260 | FILE TensorflowCCStaticTargets.cmake 261 | NAMESPACE TensorflowCC:: 262 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 263 | ) 264 | endif() 265 | 266 | # install config and version files 267 | install( 268 | FILES 269 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfig.cmake" 270 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfigVersion.cmake" 271 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 272 | ) 273 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.12/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 Filip Matzner 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.12/cmake/TensorflowBase.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | # TODO This is a patch for 1.12.0. 5 | set(OLD_PROTOBUF "https://mirror.bazel.build/github.com/google/protobuf/archive/396336eb961b75f03b25824fe86cf6490fb75e3a.tar.gz") 6 | set(FIXED_PROTOBUF "https://github.com/protocolbuffers/protobuf/releases/download/v3.6.0/protobuf-all-3.6.0.tar.gz") 7 | 8 | ExternalProject_Add( 9 | tensorflow_base 10 | GIT_REPOSITORY https://github.com/tensorflow/tensorflow.git 11 | GIT_TAG "${TENSORFLOW_TAG}" 12 | TMP_DIR "/tmp" 13 | STAMP_DIR "tensorflow-stamp" 14 | DOWNLOAD_DIR "tensorflow" 15 | SOURCE_DIR "tensorflow" 16 | BUILD_IN_SOURCE 1 17 | UPDATE_COMMAND "" 18 | CONFIGURE_COMMAND make -f tensorflow/contrib/makefile/Makefile clean 19 | 20 | # TODO This is a patch for 1.12.0. 21 | COMMAND git checkout master -- tensorflow/tf_version_script.lds 22 | COMMAND sed -i "s#${OLD_PROTOBUF}#${FIXED_PROTOBUF}#g" tensorflow/contrib/makefile/download_dependencies.sh 23 | 24 | COMMAND tensorflow/contrib/makefile/download_dependencies.sh 25 | BUILD_COMMAND "" 26 | INSTALL_COMMAND "" 27 | ) -------------------------------------------------------------------------------- /assets/share/tensorflow-1.12/cmake/TensorflowCCConfig.cmake.in: -------------------------------------------------------------------------------- 1 | @PACKAGE_INIT@ 2 | 3 | if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/TensorflowCCSharedTargets.cmake") 4 | include("${CMAKE_CURRENT_LIST_DIR}/TensorflowCCSharedTargets.cmake") 5 | set(TensorflowCC_Shared_FOUND ON) 6 | endif() 7 | 8 | if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/TensorflowCCStaticTargets.cmake") 9 | include("${CMAKE_CURRENT_LIST_DIR}/TensorflowCCStaticTargets.cmake") 10 | set(TensorflowCC_Static_FOUND ON) 11 | endif() 12 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.12/cmake/TensorflowShared.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | ExternalProject_Add( 5 | tensorflow_shared 6 | DEPENDS tensorflow_base 7 | TMP_DIR "/tmp" 8 | STAMP_DIR "tensorflow-stamp" 9 | SOURCE_DIR "tensorflow" 10 | BUILD_IN_SOURCE 1 11 | DOWNLOAD_COMMAND "" 12 | UPDATE_COMMAND "" 13 | CONFIGURE_COMMAND tensorflow/contrib/makefile/compile_linux_protobuf.sh 14 | # patch nsync to use g++-7 15 | COMMAND sed -i "s/ g++/ g++-7/g" tensorflow/contrib/makefile/compile_nsync.sh 16 | COMMAND tensorflow/contrib/makefile/compile_nsync.sh 17 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/build_tensorflow.sh" . 18 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/copy_links.sh" . 19 | COMMAND ./build_tensorflow.sh 20 | COMMAND ./copy_links.sh . 21 | # For some reason, Bazel sometimes puts the headers into 22 | # `bazel-genfiles/genfiles` and sometimes just to `bazel-genfiles`. 23 | # So we just create and include both the directories. 24 | COMMAND mkdir -p bazel-genfiles/genfiles 25 | COMMAND touch bazel-genfiles/_placeholder.h 26 | COMMAND touch bazel-genfiles/genfiles/_placeholder.h 27 | BUILD_COMMAND "" 28 | INSTALL_COMMAND "" 29 | ) -------------------------------------------------------------------------------- /assets/share/tensorflow-1.12/cmake/TensorflowStatic.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | ExternalProject_Add( 5 | tensorflow_static 6 | DEPENDS tensorflow_base 7 | TMP_DIR "/tmp" 8 | STAMP_DIR "tensorflow-stamp" 9 | SOURCE_DIR "tensorflow" 10 | BUILD_IN_SOURCE 1 11 | DOWNLOAD_COMMAND "" 12 | UPDATE_COMMAND "" 13 | CONFIGURE_COMMAND tensorflow/contrib/makefile/build_all_linux.sh 14 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/copy_links.sh" . 15 | COMMAND ./copy_links.sh . 16 | BUILD_COMMAND "" 17 | INSTALL_COMMAND "" 18 | ) 19 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.12/cmake/build_tensorflow.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | # Test whether one version ($1) is less than or equal to other ($2). 5 | function version_gt { 6 | test "`printf '%s\n' "$@" | sort -V | head -n 1`" != "$1" 7 | } 8 | 9 | # configure environmental variables 10 | export CC_OPT_FLAGS=${CC_OPT_FLAGS:-"-march=ivybridge"} 11 | export TF_NEED_GCP=${TF_NEED_GCP:-0} 12 | export TF_NEED_HDFS=${TF_NEED_HDFS:-0} 13 | export TF_NEED_OPENCL=${TF_NEED_OPENCL:-0} 14 | export TF_NEED_OPENCL_SYCL=${TF_NEED_OPENCL_SYCL:-0} 15 | export TF_NEED_TENSORRT=${TF_NEED_TENSORRT:-0} 16 | export TF_NEED_NGRAPH=${TF_NEED_NGRAPH:-0} 17 | export TF_NEED_JEMALLOC=${TF_NEED_JEMALLOC:-1} 18 | export TF_NEED_VERBS=${TF_NEED_VERBS:-0} 19 | export TF_NEED_MKL=${TF_NEED_MKL:-1} 20 | export TF_DOWNLOAD_MKL=${TF_DOWNLOAD_MKL:-1} 21 | export TF_NEED_MPI=${TF_NEED_MPI:-0} 22 | export TF_ENABLE_XLA=${TF_ENABLE_XLA:-1} 23 | export TF_NEED_AWS=${TF_NEED_AWS:-0} 24 | export TF_NEED_GDR=${TF_NEED_GDR:-0} 25 | export TF_CUDA_CLANG=${TF_CUDA_CLANG:-0} 26 | export TF_SET_ANDROID_WORKSPACE=${TF_SET_ANDROID_WORKSPACE:-0} 27 | export TF_NEED_KAFKA=${TF_NEED_KAFKA:-0} 28 | export TF_DOWNLOAD_CLANG=${TF_DOWNLOAD_CLANG:-0} 29 | export TF_NEED_IGNITE=${TF_NEED_IGNITE:-0} 30 | export TF_NEED_ROCM=${TF_NEED_ROCM:-0} 31 | export TF_NCCL_VERSION=${TF_NCCL_VERSION:-2.3} # _DEFAULT_NCCL_VERSION from configure.py 32 | export NCCL_INSTALL_PATH=${NCCL_INSTALL_PATH:-${CUDA_TOOLKIT_PATH}} 33 | export PYTHON_BIN_PATH=${PYTHON_BIN_PATH:-"$(which python3)"} 34 | export PYTHON_LIB_PATH="$($PYTHON_BIN_PATH -c 'import site; print(site.getsitepackages()[0])')" 35 | export CUDNN_INSTALL_PATH=$CUDA_TOOLKIT_PATH 36 | 37 | if [ -n "${CUDA_TOOLKIT_PATH}" ]; then 38 | if [[ -z "${CUDNN_INSTALL_PATH}" ]]; then 39 | echo "CUDA found but no cudnn.h found. Please install cuDNN." 40 | exit 1 41 | fi 42 | echo "CUDA support enabled" 43 | cuda_config_opts="--config=cuda" 44 | export TF_NEED_CUDA=1 45 | export TF_CUDA_COMPUTE_CAPABILITIES=${TF_CUDA_COMPUTE_CAPABILITIES:-"3.5,7.0"} # default from configure.py 46 | export TF_CUDA_VERSION="$($CUDA_TOOLKIT_PATH/bin/nvcc --version | sed -n 's/^.*release \(.*\),.*/\1/p')" 47 | export TF_CUDNN_VERSION="$(sed -n 's/^#define CUDNN_MAJOR\s*\(.*\).*/\1/p' $CUDNN_INSTALL_PATH/include/cudnn.h)" 48 | 49 | # choose the right version of CUDA compiler 50 | if [ -z "$GCC_HOST_COMPILER_PATH" ]; then 51 | if hash gcc-7 2>/dev/null && version_gt 7.4 `gcc-7 -dumpversion`; then 52 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-7"} 53 | elif hash gcc-6 2>/dev/null && version_gt 6.4 `gcc-6 -dumpversion`; then 54 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-6"} 55 | elif hash gcc-5 2>/dev/null && version_gt 5.5 `gcc-5 -dumpversion`; then 56 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-5"} 57 | elif hash gcc-4 2>/dev/null && version_gt 4.9 `gcc-4 -dumpversion`; then 58 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-4"} 59 | else 60 | echo "No supported CUDA compiler available. If you are sure your compiler" 61 | echo "version is supported by your CUDA version, please run e.g.:" 62 | echo "export GCC_HOST_COMPILER_PATH=/usr/bin/gcc" 63 | echo "before the build. For the list of supported compilers refer to:" 64 | echo "https://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html" 65 | exit 1 66 | fi 67 | fi 68 | 69 | export CLANG_CUDA_COMPILER_PATH=${CLANG_CUDA_COMPILER_PATH:-"/usr/bin/clang"} 70 | export TF_CUDA_CLANG=${TF_CUDA_CLANG:-0} 71 | else 72 | echo "CUDA support disabled" 73 | cuda_config_opts="" 74 | export TF_NEED_CUDA=0 75 | fi 76 | 77 | # configure and build 78 | ./configure 79 | 80 | bazel build --config=opt \ 81 | --config=monolithic \ 82 | $cuda_config_opts \ 83 | tensorflow:libtensorflow_cc.so 84 | 85 | bazel build --config=opt \ 86 | --config=monolithic \ 87 | $cuda_config_opts \ 88 | //tensorflow:libtensorflow.so 89 | 90 | # Python API 91 | bazel build --config=opt \ 92 | --config=monolithic \ 93 | $cuda_config_opts \ 94 | //tensorflow/tools/pip_package:build_pip_package 95 | 96 | bazel shutdown 97 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.12/cmake/copy_links.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | # This file recursively traverses a directory and replaces each 4 | # link by a copy of its target. 5 | 6 | echo "Replacing links with the copies of their targets." 7 | echo "This may take a while..." 8 | # To properly handle whitespace characters in filenames, we need to use 9 | # an ugly `find` and `read` trick. 10 | find -L "$1" -depth -print0 | 11 | while IFS= read -r -d $'\0' f; do 12 | # We need to check whether the file is still a link. 13 | # It may have happened that we have already replaced it by 14 | # the original when some of its parent directories were copied. 15 | # Also the first check is to detect whether the file (after 16 | # symlink dereference) exists so that `realpath` does not fail. 17 | if [[ -w "$f" ]] && [[ -L "$f" ]]; then 18 | realf="$(realpath "$f")" 19 | rm "$f" 20 | cp -r --link "$realf" "$f" 2>/dev/null || cp -r "$realf" "$f" 21 | fi 22 | done 23 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.13/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | project( 3 | "tensorflow_cc" 4 | VERSION 1.13.1 5 | ) 6 | 7 | # Static library with no GPU support is built by default. 8 | # Use the following option to build a shared library with GPU support. 9 | # If enabled, bazel has to be installed. 10 | option(TENSORFLOW_SHARED "Build shared library (required for GPU support)." OFF) 11 | option(TENSORFLOW_STATIC "Build static library." ON) 12 | set(TENSORFLOW_TAG "v1.13.1" CACHE STRING "The tensorflow release tag to be checked out (default v1.13.1).") 13 | option(SYSTEM_PROTOBUF "Use system protobuf instead of static protobuf from contrib/makefile." OFF) 14 | 15 | # ------------- 16 | # CMake Options 17 | # ------------- 18 | 19 | list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") 20 | set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/lib") 21 | set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/lib") 22 | include(CMakePackageConfigHelpers) 23 | set(CMAKECFG_INSTALL_DIR lib/cmake/TensorflowCC) 24 | 25 | # -------------------------------------------------------- 26 | # Include External Projects for Shared / Static Tensorflow 27 | # -------------------------------------------------------- 28 | 29 | include(TensorflowBase) 30 | if(TENSORFLOW_SHARED) 31 | include(TensorflowShared) 32 | endif() 33 | if(TENSORFLOW_STATIC) 34 | include(TensorflowStatic) 35 | # Add shared lib as dependency to avoid race 36 | if(TENSORFLOW_SHARED) 37 | add_dependencies( 38 | tensorflow_static 39 | tensorflow_shared 40 | ) 41 | endif() 42 | endif() 43 | 44 | # ---------------------------------- 45 | # Define Shared Tensorflow Interface 46 | # ---------------------------------- 47 | if(SYSTEM_PROTOBUF) 48 | find_package(Protobuf REQUIRED) 49 | endif() 50 | 51 | # ---------------------------------- 52 | # Define Shared Tensorflow Interface 53 | # ---------------------------------- 54 | 55 | if(TENSORFLOW_SHARED) 56 | add_library(tensorflow_cc_shared INTERFACE) 57 | target_compile_options( 58 | tensorflow_cc_shared INTERFACE 59 | "$<$:-std=c++11>" 60 | ) 61 | add_dependencies( 62 | tensorflow_cc_shared 63 | tensorflow_shared 64 | ) 65 | target_include_directories( 66 | tensorflow_cc_shared INTERFACE 67 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow" 68 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/bazel-genfiles" 69 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/bazel-genfiles/genfiles" 70 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads" 71 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/absl" 72 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/eigen" 73 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/gemmlowp" 74 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/nsync/public" 75 | ) 76 | target_link_libraries( 77 | tensorflow_cc_shared INTERFACE 78 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libtensorflow_cc.so" 79 | dl pthread 80 | ) 81 | if(SYSTEM_PROTOBUF) 82 | target_include_directories( 83 | tensorflow_cc_shared INTERFACE 84 | "${Protobuf_INCLUDE_DIRS}" 85 | ) 86 | target_link_libraries( 87 | tensorflow_cc_shared INTERFACE 88 | "${Protobuf_LIBRARIES}" 89 | ) 90 | else() 91 | target_include_directories( 92 | tensorflow_cc_shared INTERFACE 93 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/include" 94 | ) 95 | target_link_libraries( 96 | tensorflow_cc_shared INTERFACE 97 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libprotobuf.a" 98 | ) 99 | endif() 100 | endif() 101 | 102 | # ---------------------------------- 103 | # Define Static Tensorflow Interface 104 | # ---------------------------------- 105 | 106 | if(TENSORFLOW_STATIC) 107 | add_library(tensorflow_cc_static INTERFACE) 108 | target_compile_options( 109 | tensorflow_cc_static INTERFACE 110 | "$<$:-std=c++11>" 111 | ) 112 | add_dependencies( 113 | tensorflow_cc_static 114 | tensorflow_static 115 | ) 116 | target_include_directories( 117 | tensorflow_cc_static INTERFACE 118 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow" 119 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/host_obj" 120 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads" 121 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/absl" 122 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/eigen" 123 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/gemmlowp" 124 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/nsync/public" 125 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/proto" 126 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/proto_text" 127 | ) 128 | target_link_libraries( 129 | tensorflow_cc_static INTERFACE 130 | "-Wl,--allow-multiple-definition" 131 | "-Wl,--whole-archive ${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libtensorflow-core.a" 132 | "-Wl,--no-whole-archive" 133 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/nsync.a" 134 | dl pthread 135 | ) 136 | if(SYSTEM_PROTOBUF) 137 | target_include_directories( 138 | tensorflow_cc_static INTERFACE 139 | "${Protobuf_INCLUDE_DIRS}" 140 | ) 141 | target_link_libraries( 142 | tensorflow_cc_static INTERFACE 143 | "${Protobuf_LIBRARIES}" 144 | ) 145 | else() 146 | target_include_directories( 147 | tensorflow_cc_static INTERFACE 148 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/include" 149 | ) 150 | target_link_libraries( 151 | tensorflow_cc_static INTERFACE 152 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libprotobuf.a" 153 | ) 154 | endif() 155 | endif() 156 | 157 | # ---------------------------------------- 158 | # Configure CMake Config and Version Files 159 | # ---------------------------------------- 160 | 161 | write_basic_package_version_file( 162 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfigVersion.cmake" 163 | VERSION ${PROJECT_VERSION} 164 | COMPATIBILITY SameMajorVersion 165 | ) 166 | configure_package_config_file( 167 | "${CMAKE_CURRENT_SOURCE_DIR}/cmake/TensorflowCCConfig.cmake.in" 168 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfig.cmake" 169 | INSTALL_DESTINATION "${CMAKECFG_INSTALL_DIR}" 170 | NO_SET_AND_CHECK_MACRO # TensorflowCC only uses interface libraries 171 | NO_CHECK_REQUIRED_COMPONENTS_MACRO # TensorflowCC does not have components 172 | ) 173 | 174 | # ------- 175 | # Install 176 | # ------- 177 | 178 | # install all header files 179 | install( 180 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/" 181 | DESTINATION include/tensorflow 182 | FILES_MATCHING PATTERN "*.h" 183 | ) 184 | # install all header files downloaded by contrib/makefile 185 | # (Note that we cannot simply include all *.h or *.hpp files, since e.g., eigen 186 | # does not use file extensions for header files.) 187 | install( 188 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/downloads/" 189 | DESTINATION include/tensorflow/tensorflow/contrib/makefile/downloads 190 | FILES_MATCHING PATTERN "*" 191 | PATTERN "Makefile*" EXCLUDE 192 | PATTERN "*unittest*" EXCLUDE 193 | PATTERN "*.o" EXCLUDE 194 | PATTERN "*.so" EXCLUDE 195 | PATTERN "*.so.*" EXCLUDE 196 | PATTERN "*.a" EXCLUDE 197 | PATTERN "*.tbz" EXCLUDE 198 | PATTERN "*.tgz" EXCLUDE 199 | PATTERN "*.tar" EXCLUDE 200 | PATTERN "*.tar.*" EXCLUDE 201 | PATTERN "*.zip" EXCLUDE 202 | ) 203 | # install all files from third_party folder (e.g., Eigen/Tensor) 204 | install( 205 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/third_party/" 206 | DESTINATION include/tensorflow/third_party 207 | ) 208 | # install static libprotobuf from contrib/makefile 209 | if (NOT SYSTEM_PROTOBUF) 210 | install( 211 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/lib/libprotobuf.a" 212 | DESTINATION lib/tensorflow_cc 213 | ) 214 | endif() 215 | # shared library specific 216 | if(TENSORFLOW_SHARED) 217 | install( 218 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/bazel-bin/tensorflow/libtensorflow_cc.so" 219 | DESTINATION lib/tensorflow_cc 220 | ) 221 | endif() 222 | # static library specific 223 | if(TENSORFLOW_STATIC) 224 | install( 225 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/gen/lib/libtensorflow-core.a" 226 | "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/downloads/nsync/builds/default.linux.c++11/nsync.a" 227 | DESTINATION lib/tensorflow_cc 228 | ) 229 | endif() 230 | 231 | # -------------------------- 232 | # Install CMake targets file 233 | # -------------------------- 234 | 235 | if(TENSORFLOW_SHARED) 236 | set_target_properties( 237 | tensorflow_cc_shared PROPERTIES EXPORT_NAME Shared 238 | ) 239 | install( 240 | TARGETS tensorflow_cc_shared 241 | EXPORT TensorflowCCSharedTargets 242 | ) 243 | install( 244 | EXPORT TensorflowCCSharedTargets 245 | FILE TensorflowCCSharedTargets.cmake 246 | NAMESPACE TensorflowCC:: 247 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 248 | ) 249 | endif() 250 | if(TENSORFLOW_STATIC) 251 | set_target_properties( 252 | tensorflow_cc_static PROPERTIES EXPORT_NAME Static 253 | ) 254 | install( 255 | TARGETS tensorflow_cc_static 256 | EXPORT TensorflowCCStaticTargets 257 | ) 258 | install( 259 | EXPORT TensorflowCCStaticTargets 260 | FILE TensorflowCCStaticTargets.cmake 261 | NAMESPACE TensorflowCC:: 262 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 263 | ) 264 | endif() 265 | 266 | # install config and version files 267 | install( 268 | FILES 269 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfig.cmake" 270 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfigVersion.cmake" 271 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 272 | ) 273 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.13/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 Filip Matzner 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.13/cmake/TensorflowBase.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | # TODO This is a patch for 1.12.0. 5 | set(OLD_PROTOBUF "https://mirror.bazel.build/github.com/google/protobuf/archive/396336eb961b75f03b25824fe86cf6490fb75e3a.tar.gz") 6 | set(FIXED_PROTOBUF "https://github.com/protocolbuffers/protobuf/releases/download/v3.6.0/protobuf-all-3.6.0.tar.gz") 7 | 8 | ExternalProject_Add( 9 | tensorflow_base 10 | GIT_REPOSITORY https://github.com/tensorflow/tensorflow.git 11 | GIT_TAG "${TENSORFLOW_TAG}" 12 | TMP_DIR "/tmp" 13 | STAMP_DIR "tensorflow-stamp" 14 | DOWNLOAD_DIR "tensorflow" 15 | SOURCE_DIR "tensorflow" 16 | BUILD_IN_SOURCE 1 17 | UPDATE_COMMAND "" 18 | CONFIGURE_COMMAND make -f tensorflow/contrib/makefile/Makefile clean 19 | 20 | # TODO This is a patch for 1.12.0. 21 | COMMAND git checkout master -- tensorflow/tf_version_script.lds 22 | COMMAND sed -i "s#${OLD_PROTOBUF}#${FIXED_PROTOBUF}#g" tensorflow/contrib/makefile/download_dependencies.sh 23 | 24 | COMMAND tensorflow/contrib/makefile/download_dependencies.sh 25 | BUILD_COMMAND "" 26 | INSTALL_COMMAND "" 27 | ) -------------------------------------------------------------------------------- /assets/share/tensorflow-1.13/cmake/TensorflowCCConfig.cmake.in: -------------------------------------------------------------------------------- 1 | @PACKAGE_INIT@ 2 | 3 | if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/TensorflowCCSharedTargets.cmake") 4 | include("${CMAKE_CURRENT_LIST_DIR}/TensorflowCCSharedTargets.cmake") 5 | set(TensorflowCC_Shared_FOUND ON) 6 | endif() 7 | 8 | if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/TensorflowCCStaticTargets.cmake") 9 | include("${CMAKE_CURRENT_LIST_DIR}/TensorflowCCStaticTargets.cmake") 10 | set(TensorflowCC_Static_FOUND ON) 11 | endif() 12 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.13/cmake/TensorflowShared.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | ExternalProject_Add( 5 | tensorflow_shared 6 | DEPENDS tensorflow_base 7 | TMP_DIR "/tmp" 8 | STAMP_DIR "tensorflow-stamp" 9 | SOURCE_DIR "tensorflow" 10 | BUILD_IN_SOURCE 1 11 | DOWNLOAD_COMMAND "" 12 | UPDATE_COMMAND "" 13 | CONFIGURE_COMMAND tensorflow/contrib/makefile/compile_linux_protobuf.sh 14 | # patch nsync to use g++-7 15 | COMMAND sed -i "s/ g++/ g++-7/g" tensorflow/contrib/makefile/compile_nsync.sh 16 | COMMAND tensorflow/contrib/makefile/compile_nsync.sh 17 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/build_tensorflow.sh" . 18 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/copy_links.sh" . 19 | COMMAND ./build_tensorflow.sh 20 | COMMAND ./copy_links.sh . 21 | # For some reason, Bazel sometimes puts the headers into 22 | # `bazel-genfiles/genfiles` and sometimes just to `bazel-genfiles`. 23 | # So we just create and include both the directories. 24 | COMMAND mkdir -p bazel-genfiles/genfiles 25 | COMMAND touch bazel-genfiles/_placeholder.h 26 | COMMAND touch bazel-genfiles/genfiles/_placeholder.h 27 | BUILD_COMMAND "" 28 | INSTALL_COMMAND "" 29 | ) -------------------------------------------------------------------------------- /assets/share/tensorflow-1.13/cmake/TensorflowStatic.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | ExternalProject_Add( 5 | tensorflow_static 6 | DEPENDS tensorflow_base 7 | TMP_DIR "/tmp" 8 | STAMP_DIR "tensorflow-stamp" 9 | SOURCE_DIR "tensorflow" 10 | BUILD_IN_SOURCE 1 11 | DOWNLOAD_COMMAND "" 12 | UPDATE_COMMAND "" 13 | CONFIGURE_COMMAND tensorflow/contrib/makefile/build_all_linux.sh 14 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/copy_links.sh" . 15 | COMMAND ./copy_links.sh . 16 | BUILD_COMMAND "" 17 | INSTALL_COMMAND "" 18 | ) 19 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.13/cmake/build_tensorflow.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | # Test whether one version ($1) is less than or equal to other ($2). 5 | function version_gt { 6 | test "`printf '%s\n' "$@" | sort -V | head -n 1`" != "$1" 7 | } 8 | 9 | # configure environmental variables 10 | export CC_OPT_FLAGS=${CC_OPT_FLAGS:-"-march=ivybridge"} 11 | export TF_NEED_GCP=${TF_NEED_GCP:-0} 12 | export TF_NEED_HDFS=${TF_NEED_HDFS:-0} 13 | export TF_NEED_OPENCL=${TF_NEED_OPENCL:-0} 14 | export TF_NEED_OPENCL_SYCL=${TF_NEED_OPENCL_SYCL:-0} 15 | export TF_NEED_TENSORRT=${TF_NEED_TENSORRT:-0} 16 | export TF_NEED_NGRAPH=${TF_NEED_NGRAPH:-0} 17 | export TF_NEED_JEMALLOC=${TF_NEED_JEMALLOC:-1} 18 | export TF_NEED_VERBS=${TF_NEED_VERBS:-0} 19 | export TF_NEED_MKL=${TF_NEED_MKL:-1} 20 | export TF_DOWNLOAD_MKL=${TF_DOWNLOAD_MKL:-1} 21 | export TF_NEED_MPI=${TF_NEED_MPI:-0} 22 | export TF_ENABLE_XLA=${TF_ENABLE_XLA:-1} 23 | export TF_NEED_AWS=${TF_NEED_AWS:-0} 24 | export TF_NEED_GDR=${TF_NEED_GDR:-0} 25 | export TF_CUDA_CLANG=${TF_CUDA_CLANG:-0} 26 | export TF_SET_ANDROID_WORKSPACE=${TF_SET_ANDROID_WORKSPACE:-0} 27 | export TF_NEED_KAFKA=${TF_NEED_KAFKA:-0} 28 | export TF_DOWNLOAD_CLANG=${TF_DOWNLOAD_CLANG:-0} 29 | export TF_NEED_IGNITE=${TF_NEED_IGNITE:-0} 30 | export TF_NEED_ROCM=${TF_NEED_ROCM:-0} 31 | export TF_NCCL_VERSION=${TF_NCCL_VERSION:-2.3} # _DEFAULT_NCCL_VERSION from configure.py 32 | export NCCL_INSTALL_PATH=${NCCL_INSTALL_PATH:-${CUDA_TOOLKIT_PATH}} 33 | export PYTHON_BIN_PATH=${PYTHON_BIN_PATH:-"$(which python3)"} 34 | export PYTHON_LIB_PATH="$($PYTHON_BIN_PATH -c 'import site; print(site.getsitepackages()[0])')" 35 | export CUDNN_INSTALL_PATH=$CUDA_TOOLKIT_PATH 36 | 37 | if [ -n "${CUDA_TOOLKIT_PATH}" ]; then 38 | if [[ -z "${CUDNN_INSTALL_PATH}" ]]; then 39 | echo "CUDA found but no cudnn.h found. Please install cuDNN." 40 | exit 1 41 | fi 42 | echo "CUDA support enabled" 43 | cuda_config_opts="--config=cuda" 44 | export TF_NEED_CUDA=1 45 | export TF_CUDA_COMPUTE_CAPABILITIES=${TF_CUDA_COMPUTE_CAPABILITIES:-"3.5,7.0"} # default from configure.py 46 | export TF_CUDA_VERSION="$($CUDA_TOOLKIT_PATH/bin/nvcc --version | sed -n 's/^.*release \(.*\),.*/\1/p')" 47 | export TF_CUDNN_VERSION="$(sed -n 's/^#define CUDNN_MAJOR\s*\(.*\).*/\1/p' $CUDNN_INSTALL_PATH/include/cudnn.h)" 48 | 49 | # choose the right version of CUDA compiler 50 | if [ -z "$GCC_HOST_COMPILER_PATH" ]; then 51 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-7"} 52 | fi 53 | 54 | export CLANG_CUDA_COMPILER_PATH=${CLANG_CUDA_COMPILER_PATH:-"/usr/bin/clang"} 55 | export TF_CUDA_CLANG=${TF_CUDA_CLANG:-0} 56 | else 57 | echo "CUDA support disabled" 58 | cuda_config_opts="" 59 | export TF_NEED_CUDA=0 60 | fi 61 | 62 | # configure and build 63 | ./configure 64 | 65 | bazel build --config=opt \ 66 | --config=monolithic \ 67 | --define=framework_shared_object=true \ 68 | $cuda_config_opts \ 69 | //tensorflow:libtensorflow.so \ 70 | //tensorflow:libtensorflow_cc.so \ 71 | //tensorflow/tools/pip_package:build_pip_package 72 | 73 | bazel shutdown 74 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.13/cmake/copy_links.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | # This file recursively traverses a directory and replaces each 4 | # link by a copy of its target. 5 | 6 | echo "Replacing links with the copies of their targets." 7 | echo "This may take a while..." 8 | # To properly handle whitespace characters in filenames, we need to use 9 | # an ugly `find` and `read` trick. 10 | find -L "$1" -depth -print0 | 11 | while IFS= read -r -d $'\0' f; do 12 | # We need to check whether the file is still a link. 13 | # It may have happened that we have already replaced it by 14 | # the original when some of its parent directories were copied. 15 | # Also the first check is to detect whether the file (after 16 | # symlink dereference) exists so that `realpath` does not fail. 17 | if [[ -w "$f" ]] && [[ -L "$f" ]]; then 18 | realf="$(realpath "$f")" 19 | rm "$f" 20 | cp -r --link "$realf" "$f" 2>/dev/null || cp -r "$realf" "$f" 21 | fi 22 | done 23 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.9/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | project( 3 | "tensorflow_cc" 4 | VERSION 1.9.0 5 | ) 6 | 7 | # Static library with no GPU support is built by default. 8 | # Use the following option to build a shared library with GPU support. 9 | # If enabled, bazel has to be installed. 10 | option(TENSORFLOW_SHARED "Build shared library (required for GPU support)." OFF) 11 | option(TENSORFLOW_STATIC "Build static library." ON) 12 | set(TENSORFLOW_TAG "v1.9.0" CACHE STRING "The tensorflow release tag to be checked out (default v1.9.0).") 13 | option(SYSTEM_PROTOBUF "Use system protobuf instead of static protobuf from contrib/makefile." OFF) 14 | 15 | # ------------- 16 | # CMake Options 17 | # ------------- 18 | 19 | list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") 20 | set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/lib") 21 | set(CMAKE_LIBRARY_OUTPUT_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/lib") 22 | include(CMakePackageConfigHelpers) 23 | set(CMAKECFG_INSTALL_DIR lib/cmake/TensorflowCC) 24 | 25 | # -------------------------------------------------------- 26 | # Include External Projects for Shared / Static Tensorflow 27 | # -------------------------------------------------------- 28 | 29 | include(TensorflowBase) 30 | if(TENSORFLOW_SHARED) 31 | include(TensorflowShared) 32 | endif() 33 | if(TENSORFLOW_STATIC) 34 | include(TensorflowStatic) 35 | # Add shared lib as dependency to avoid race 36 | if(TENSORFLOW_SHARED) 37 | add_dependencies( 38 | tensorflow_static 39 | tensorflow_shared 40 | ) 41 | endif() 42 | endif() 43 | 44 | # ---------------------------------- 45 | # Define Shared Tensorflow Interface 46 | # ---------------------------------- 47 | if(SYSTEM_PROTOBUF) 48 | find_package(Protobuf REQUIRED) 49 | endif() 50 | 51 | # ---------------------------------- 52 | # Define Shared Tensorflow Interface 53 | # ---------------------------------- 54 | 55 | if(TENSORFLOW_SHARED) 56 | add_library(tensorflow_cc_shared INTERFACE) 57 | target_compile_options( 58 | tensorflow_cc_shared INTERFACE 59 | "$<$:-std=c++11>" 60 | ) 61 | add_dependencies( 62 | tensorflow_cc_shared 63 | tensorflow_shared 64 | ) 65 | target_include_directories( 66 | tensorflow_cc_shared INTERFACE 67 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow" 68 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/bazel-genfiles" 69 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/bazel-genfiles/genfiles" 70 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads" 71 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/eigen" 72 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/gemmlowp" 73 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/nsync/public" 74 | ) 75 | target_link_libraries( 76 | tensorflow_cc_shared INTERFACE 77 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libtensorflow_cc.so" 78 | dl pthread 79 | ) 80 | if(SYSTEM_PROTOBUF) 81 | target_include_directories( 82 | tensorflow_cc_shared INTERFACE 83 | "${Protobuf_INCLUDE_DIRS}" 84 | ) 85 | target_link_libraries( 86 | tensorflow_cc_shared INTERFACE 87 | "${Protobuf_LIBRARIES}" 88 | ) 89 | else() 90 | target_include_directories( 91 | tensorflow_cc_shared INTERFACE 92 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/include" 93 | ) 94 | target_link_libraries( 95 | tensorflow_cc_shared INTERFACE 96 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libprotobuf.a" 97 | ) 98 | endif() 99 | endif() 100 | 101 | # ---------------------------------- 102 | # Define Static Tensorflow Interface 103 | # ---------------------------------- 104 | 105 | if(TENSORFLOW_STATIC) 106 | add_library(tensorflow_cc_static INTERFACE) 107 | target_compile_options( 108 | tensorflow_cc_static INTERFACE 109 | "$<$:-std=c++11>" 110 | ) 111 | add_dependencies( 112 | tensorflow_cc_static 113 | tensorflow_static 114 | ) 115 | target_include_directories( 116 | tensorflow_cc_static INTERFACE 117 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow" 118 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/host_obj" 119 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads" 120 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/eigen" 121 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/gemmlowp" 122 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/downloads/nsync/public" 123 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/proto" 124 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/proto_text" 125 | ) 126 | target_link_libraries( 127 | tensorflow_cc_static INTERFACE 128 | "-Wl,--allow-multiple-definition" 129 | "-Wl,--whole-archive ${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libtensorflow-core.a" 130 | "-Wl,--no-whole-archive" 131 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/nsync.a" 132 | dl pthread 133 | ) 134 | if(SYSTEM_PROTOBUF) 135 | target_include_directories( 136 | tensorflow_cc_static INTERFACE 137 | "${Protobuf_INCLUDE_DIRS}" 138 | ) 139 | target_link_libraries( 140 | tensorflow_cc_static INTERFACE 141 | "${Protobuf_LIBRARIES}" 142 | ) 143 | else() 144 | target_include_directories( 145 | tensorflow_cc_static INTERFACE 146 | "${CMAKE_INSTALL_PREFIX}/include/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/include" 147 | ) 148 | target_link_libraries( 149 | tensorflow_cc_static INTERFACE 150 | "${CMAKE_INSTALL_PREFIX}/lib/tensorflow_cc/libprotobuf.a" 151 | ) 152 | endif() 153 | endif() 154 | 155 | # ---------------------------------------- 156 | # Configure CMake Config and Version Files 157 | # ---------------------------------------- 158 | 159 | write_basic_package_version_file( 160 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfigVersion.cmake" 161 | VERSION ${PROJECT_VERSION} 162 | COMPATIBILITY SameMajorVersion 163 | ) 164 | configure_package_config_file( 165 | "${CMAKE_CURRENT_SOURCE_DIR}/cmake/TensorflowCCConfig.cmake.in" 166 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfig.cmake" 167 | INSTALL_DESTINATION "${CMAKECFG_INSTALL_DIR}" 168 | NO_SET_AND_CHECK_MACRO # TensorflowCC only uses interface libraries 169 | NO_CHECK_REQUIRED_COMPONENTS_MACRO # TensorflowCC does not have components 170 | ) 171 | 172 | # ------- 173 | # Install 174 | # ------- 175 | 176 | # install all header files 177 | install( 178 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/" 179 | DESTINATION include/tensorflow 180 | FILES_MATCHING PATTERN "*.h" 181 | ) 182 | # install all header files downloaded by contrib/makefile 183 | # (Note that we cannot simply include all *.h or *.hpp files, since e.g., eigen 184 | # does not use file extensions for header files.) 185 | install( 186 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/downloads/" 187 | DESTINATION include/tensorflow/tensorflow/contrib/makefile/downloads 188 | FILES_MATCHING PATTERN "*" 189 | PATTERN "Makefile*" EXCLUDE 190 | PATTERN "*unittest*" EXCLUDE 191 | PATTERN "*.o" EXCLUDE 192 | PATTERN "*.so" EXCLUDE 193 | PATTERN "*.so.*" EXCLUDE 194 | PATTERN "*.a" EXCLUDE 195 | PATTERN "*.tbz" EXCLUDE 196 | PATTERN "*.tgz" EXCLUDE 197 | PATTERN "*.tar" EXCLUDE 198 | PATTERN "*.tar.*" EXCLUDE 199 | PATTERN "*.zip" EXCLUDE 200 | ) 201 | # install all files from third_party folder (e.g., Eigen/Tensor) 202 | install( 203 | DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/third_party/" 204 | DESTINATION include/tensorflow/third_party 205 | ) 206 | # install static libprotobuf from contrib/makefile 207 | if (NOT SYSTEM_PROTOBUF) 208 | install( 209 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/gen/protobuf-host/lib/libprotobuf.a" 210 | DESTINATION lib/tensorflow_cc 211 | ) 212 | endif() 213 | # shared library specific 214 | if(TENSORFLOW_SHARED) 215 | install( 216 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/bazel-bin/bin/tensorflow/libtensorflow_cc.so" 217 | DESTINATION lib/tensorflow_cc 218 | OPTIONAL 219 | ) 220 | install( 221 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/bazel-bin/tensorflow/libtensorflow_cc.so" 222 | DESTINATION lib/tensorflow_cc 223 | OPTIONAL 224 | ) 225 | endif() 226 | # static library specific 227 | if(TENSORFLOW_STATIC) 228 | install( 229 | FILES "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/gen/lib/libtensorflow-core.a" 230 | "${CMAKE_CURRENT_BINARY_DIR}/tensorflow/tensorflow/contrib/makefile/downloads/nsync/builds/default.linux.c++11/nsync.a" 231 | DESTINATION lib/tensorflow_cc 232 | ) 233 | endif() 234 | 235 | # -------------------------- 236 | # Install CMake targets file 237 | # -------------------------- 238 | 239 | if(TENSORFLOW_SHARED) 240 | set_target_properties( 241 | tensorflow_cc_shared PROPERTIES EXPORT_NAME Shared 242 | ) 243 | install( 244 | TARGETS tensorflow_cc_shared 245 | EXPORT TensorflowCCSharedTargets 246 | ) 247 | install( 248 | EXPORT TensorflowCCSharedTargets 249 | FILE TensorflowCCSharedTargets.cmake 250 | NAMESPACE TensorflowCC:: 251 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 252 | ) 253 | endif() 254 | if(TENSORFLOW_STATIC) 255 | set_target_properties( 256 | tensorflow_cc_static PROPERTIES EXPORT_NAME Static 257 | ) 258 | install( 259 | TARGETS tensorflow_cc_static 260 | EXPORT TensorflowCCStaticTargets 261 | ) 262 | install( 263 | EXPORT TensorflowCCStaticTargets 264 | FILE TensorflowCCStaticTargets.cmake 265 | NAMESPACE TensorflowCC:: 266 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 267 | ) 268 | endif() 269 | 270 | # install config and version files 271 | install( 272 | FILES 273 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfig.cmake" 274 | "${CMAKE_CURRENT_BINARY_DIR}/TensorflowCCConfigVersion.cmake" 275 | DESTINATION "${CMAKECFG_INSTALL_DIR}" 276 | ) 277 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.9/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2017 Filip Matzner 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.9/cmake/TensorflowBase.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | ExternalProject_Add( 5 | tensorflow_base 6 | GIT_REPOSITORY https://github.com/tensorflow/tensorflow.git 7 | GIT_TAG "${TENSORFLOW_TAG}" 8 | TMP_DIR "/tmp" 9 | STAMP_DIR "tensorflow-stamp" 10 | DOWNLOAD_DIR "tensorflow" 11 | SOURCE_DIR "tensorflow" 12 | BUILD_IN_SOURCE 1 13 | UPDATE_COMMAND "" 14 | CONFIGURE_COMMAND make -f tensorflow/contrib/makefile/Makefile clean 15 | # Fix github.com/tensorflow/tensorflow/issues/19840 16 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/stream.patch" . 17 | COMMAND patch -p1 < stream.patch 18 | 19 | COMMAND tensorflow/contrib/makefile/download_dependencies.sh 20 | BUILD_COMMAND "" 21 | INSTALL_COMMAND "" 22 | ) 23 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.9/cmake/TensorflowCCConfig.cmake.in: -------------------------------------------------------------------------------- 1 | @PACKAGE_INIT@ 2 | 3 | if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/TensorflowCCSharedTargets.cmake") 4 | include("${CMAKE_CURRENT_LIST_DIR}/TensorflowCCSharedTargets.cmake") 5 | set(TensorflowCC_Shared_FOUND ON) 6 | endif() 7 | 8 | if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/TensorflowCCStaticTargets.cmake") 9 | include("${CMAKE_CURRENT_LIST_DIR}/TensorflowCCStaticTargets.cmake") 10 | set(TensorflowCC_Static_FOUND ON) 11 | endif() 12 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.9/cmake/TensorflowShared.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | ExternalProject_Add( 5 | tensorflow_shared 6 | DEPENDS tensorflow_base 7 | TMP_DIR "/tmp" 8 | STAMP_DIR "tensorflow-stamp" 9 | SOURCE_DIR "tensorflow" 10 | BUILD_IN_SOURCE 1 11 | DOWNLOAD_COMMAND "" 12 | UPDATE_COMMAND "" 13 | CONFIGURE_COMMAND tensorflow/contrib/makefile/compile_linux_protobuf.sh 14 | # patch nsync to use g++-7 15 | COMMAND sed -i "s/ g++/ g++-7/g" tensorflow/contrib/makefile/compile_nsync.sh 16 | COMMAND tensorflow/contrib/makefile/compile_nsync.sh 17 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/build_tensorflow.sh" . 18 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/copy_links.sh" . 19 | COMMAND ./build_tensorflow.sh 20 | COMMAND ./copy_links.sh . 21 | # For some reason, Bazel sometimes puts the headers into 22 | # `bazel-genfiles/genfiles` and sometimes just to `bazel-genfiles`. 23 | # So we just create and include both the directories. 24 | COMMAND mkdir -p bazel-genfiles/genfiles 25 | COMMAND touch bazel-genfiles/_placeholder.h 26 | COMMAND touch bazel-genfiles/genfiles/_placeholder.h 27 | BUILD_COMMAND "" 28 | INSTALL_COMMAND "" 29 | ) 30 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.9/cmake/TensorflowStatic.cmake: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | include(ExternalProject) 3 | 4 | ExternalProject_Add( 5 | tensorflow_static 6 | DEPENDS tensorflow_base 7 | TMP_DIR "/tmp" 8 | STAMP_DIR "tensorflow-stamp" 9 | SOURCE_DIR "tensorflow" 10 | BUILD_IN_SOURCE 1 11 | DOWNLOAD_COMMAND "" 12 | UPDATE_COMMAND "" 13 | CONFIGURE_COMMAND tensorflow/contrib/makefile/build_all_linux.sh 14 | COMMAND cp "${CMAKE_CURRENT_SOURCE_DIR}/cmake/copy_links.sh" . 15 | COMMAND ./copy_links.sh . 16 | BUILD_COMMAND "" 17 | INSTALL_COMMAND "" 18 | ) 19 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.9/cmake/build_tensorflow.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | 4 | # Test whether one version ($1) is less than or equal to other ($2). 5 | function version_gt { 6 | test "`printf '%s\n' "$@" | sort -V | head -n 1`" != "$1" 7 | } 8 | 9 | # configure environmental variables 10 | export CC_OPT_FLAGS=${CC_OPT_FLAGS:-"-march=ivybridge"} 11 | export TF_NEED_GCP=${TF_NEED_GCP:-0} 12 | export TF_NEED_HDFS=${TF_NEED_HDFS:-0} 13 | export TF_NEED_OPENCL=${TF_NEED_OPENCL:-0} 14 | export TF_NEED_OPENCL_SYCL=${TF_NEED_OPENCL_SYCL:-0} 15 | export TF_NEED_TENSORRT=${TF_NEED_TENSORRT:-0} 16 | export TF_NEED_JEMALLOC=${TF_NEED_JEMALLOC:-1} 17 | export TF_NEED_VERBS=${TF_NEED_VERBS:-0} 18 | export TF_NEED_MKL=${TF_NEED_MKL:-1} 19 | export TF_DOWNLOAD_MKL=${TF_DOWNLOAD_MKL:-1} 20 | export TF_NEED_MPI=${TF_NEED_MPI:-0} 21 | export TF_ENABLE_XLA=${TF_ENABLE_XLA:-1} 22 | export TF_NEED_S3=${TF_NEED_S3:-0} # TODO: Remove when replaced by the next line. 23 | export TF_NEED_AWS=${TF_NEED_AWS:-0} 24 | export TF_NEED_GDR=${TF_NEED_GDR:-0} 25 | export TF_CUDA_CLANG=${TF_CUDA_CLANG:-0} 26 | export TF_SET_ANDROID_WORKSPACE=${TF_SET_ANDROID_WORKSPACE:-0} 27 | export TF_NEED_KAFKA=${TF_NEED_KAFKA:-0} 28 | export TF_DOWNLOAD_CLANG=${TF_DOWNLOAD_CLANG:-0} 29 | export TF_NCCL_VERSION=${TF_NCCL_VERSION:-1.3} # _DEFAULT_NCCL_VERSION from configure.py 30 | export PYTHON_BIN_PATH=${PYTHON_BIN_PATH:-"$(which python3)"} 31 | export PYTHON_LIB_PATH="$($PYTHON_BIN_PATH -c 'import site; print(site.getsitepackages()[0])')" 32 | 33 | export CUDNN_INSTALL_PATH=$CUDA_TOOLKIT_PATH 34 | 35 | if [ -n "${CUDA_TOOLKIT_PATH}" ]; then 36 | if [[ -z "${CUDNN_INSTALL_PATH}" ]]; then 37 | echo "CUDA found but no cudnn.h found. Please install cuDNN." 38 | exit 1 39 | fi 40 | echo "CUDA support enabled" 41 | cuda_config_opts="--config=cuda" 42 | export TF_NEED_CUDA=1 43 | export TF_CUDA_COMPUTE_CAPABILITIES=${TF_CUDA_COMPUTE_CAPABILITIES:-"3.5,5.2,6.1,6.2"} 44 | export TF_CUDA_VERSION="$($CUDA_TOOLKIT_PATH/bin/nvcc --version | sed -n 's/^.*release \(.*\),.*/\1/p')" 45 | export TF_CUDNN_VERSION="$(sed -n 's/^#define CUDNN_MAJOR\s*\(.*\).*/\1/p' $CUDNN_INSTALL_PATH/include/cudnn.h)" 46 | 47 | # choose the right version of CUDA compiler 48 | if [ -z "$GCC_HOST_COMPILER_PATH" ]; then 49 | if hash gcc-7 2>/dev/null && version_gt 7.4 `gcc-7 -dumpversion`; then 50 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-7"} 51 | elif hash gcc-6 2>/dev/null && version_gt 6.4 `gcc-6 -dumpversion`; then 52 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-6"} 53 | elif hash gcc-5 2>/dev/null && version_gt 5.5 `gcc-5 -dumpversion`; then 54 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-5"} 55 | elif hash gcc-4 2>/dev/null && version_gt 4.9 `gcc-4 -dumpversion`; then 56 | export GCC_HOST_COMPILER_PATH=${GCC_HOST_COMPILER_PATH:-"/usr/bin/gcc-4"} 57 | else 58 | echo "No supported CUDA compiler available. If you are sure your compiler" 59 | echo "version is supported by your CUDA version, please run e.g.:" 60 | echo "export GCC_HOST_COMPILER_PATH=/usr/bin/gcc" 61 | echo "before the build. For the list of supported compilers refer to:" 62 | echo "https://docs.nvidia.com/cuda/cuda-installation-guide-linux/index.html" 63 | exit 1 64 | fi 65 | fi 66 | 67 | export CLANG_CUDA_COMPILER_PATH=${CLANG_CUDA_COMPILER_PATH:-"/usr/bin/clang"} 68 | export TF_CUDA_CLANG=${TF_CUDA_CLANG:-0} 69 | else 70 | echo "CUDA support disabled" 71 | cuda_config_opts="" 72 | export TF_NEED_CUDA=0 73 | fi 74 | 75 | # configure and build 76 | ./configure 77 | 78 | echo "building libtensorflow_cc.so" 79 | bazel build --config=opt \ 80 | --config=monolithic \ 81 | $cuda_config_opts \ 82 | tensorflow:libtensorflow_cc.so 83 | 84 | echo "building libtensorflow.so" 85 | bazel build --config=opt \ 86 | --config=monolithic \ 87 | $cuda_config_opts \ 88 | //tensorflow:libtensorflow.so 89 | 90 | # Python API 91 | echo "building Python pip_package" 92 | bazel build --config=opt \ 93 | --config=monolithic \ 94 | $cuda_config_opts \ 95 | //tensorflow/tools/pip_package:build_pip_package 96 | 97 | bazel shutdown 98 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.9/cmake/copy_links.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | set -e 3 | # This file recursively traverses a directory and replaces each 4 | # link by a copy of its target. 5 | 6 | echo "Replacing links with the copies of their targets." 7 | echo "This may take a while..." 8 | # To properly handle whitespace characters in filenames, we need to use 9 | # an ugly `find` and `read` trick. 10 | find -L "$1" -depth -print0 | 11 | while IFS= read -r -d $'\0' f; do 12 | # We need to check whether the file is still a link. 13 | # It may have happened that we have already replaced it by 14 | # the original when some of its parent directories were copied. 15 | # Also the first check is to detect whether the file (after 16 | # symlink dereference) exists so that `realpath` does not fail. 17 | if [[ -w "$f" ]] && [[ -L "$f" ]]; then 18 | realf="$(realpath "$f")" 19 | rm "$f" 20 | cp -r --link "$realf" "$f" 2>/dev/null || cp -r "$realf" "$f" 21 | fi 22 | done 23 | -------------------------------------------------------------------------------- /assets/share/tensorflow-1.9/stream.patch: -------------------------------------------------------------------------------- 1 | --- ./tensorflow/tf_version_script.lds.old 2018-10-31 12:15:05.127429879 -0600 2 | +++ ./tensorflow/tf_version_script.lds 2018-10-31 12:15:32.347077298 -0600 3 | @@ -6,6 +6,7 @@ 4 | *TFE_*; 5 | *nsync_*; 6 | *pywrap_xla*; 7 | + *stream_executor*; 8 | local: 9 | *; 10 | }; 11 | -------------------------------------------------------------------------------- /assets/share/tensorflow/assets/README.md: -------------------------------------------------------------------------------- 1 | # TensorFlow 2 | 3 | The `include` directory contains the headers needed for the C & C++ APIs. The `lib` directory contains static builds of shared libraries for the C and C++ API, as well as the unpackaged Python wheel for Python 3.6. 4 | 5 | ## C API 6 | 7 | Given the following example.c file: 8 | 9 | ```c 10 | #include 11 | #include 12 | 13 | int main() { 14 | printf("TF version: %s\n", TF_Version()); 15 | return 0; 16 | } 17 | ``` 18 | 19 | You may compile it with the following: 20 | 21 | ```sh 22 | export LD_LIBRARY_PATH="/usr/lib/tensorflow/lib:$LD_LIBRARY_PATH" \ 23 | gcc -I/usr/lib/tensorflow/include/ -L/usr/lib/tensorflow/lib \ 24 | example.c -ltensorflow -o example 25 | ./example 26 | ``` 27 | 28 | ## C++ API 29 | 30 | See the provided C++ example in the `examples/cc` directory. CMake is required to build your TensorFlow C++ project. Bazel is NOT required. 31 | 32 | ## Python API 33 | 34 | Given the following example: 35 | 36 | ```python 37 | import tensorflow as tf 38 | hello = tf.constant('Hello, TensorFlow!') 39 | sess = tf.Session() 40 | print(sess.run(hello)) 41 | ``` 42 | 43 | You may build a project with Python API by setting your PYTHONPATH when building it, like so: 44 | 45 | ```sh 46 | env PYTHONPATH=/usr/lib/tensorflow/lib/python3.6:$PYTHONPATH \ 47 | python3 example.py 48 | ``` 49 | -------------------------------------------------------------------------------- /assets/share/tensorflow/assets/examples/cc/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.3 FATAL_ERROR) 2 | list(APPEND CMAKE_PREFIX_PATH "/usr/lib/tensorflow/lib/cmake") 3 | 4 | find_package(TensorflowCC COMPONENTS Shared) 5 | find_package(CUDA) 6 | 7 | add_executable(example example.cpp) 8 | 9 | target_link_libraries(example TensorflowCC::Shared) 10 | 11 | if(CUDA_FOUND) 12 | target_link_libraries(example ${CUDA_LIBRARIES}) 13 | endif() -------------------------------------------------------------------------------- /assets/share/tensorflow/assets/examples/cc/README.md: -------------------------------------------------------------------------------- 1 | # C++ Example 2 | 3 | To build this project, simply run the following commands: 4 | 5 | ```sh 6 | # cd to $HOME and copy the example to it. 7 | cd $HOME 8 | cp -r /usr/lib/tensorflow/examples/cc $HOME/tf-cc-example 9 | 10 | # cd to the project example in $HOME, build it, and run it. 11 | cd $HOME/tf-cc-example 12 | mkdir build && cd build && cmake .. && make 13 | ./example 14 | ``` 15 | 16 | The CMakeLists.txt file contains the information for linking to the C++ library and locating its header files. 17 | -------------------------------------------------------------------------------- /assets/share/tensorflow/assets/examples/cc/example.cpp: -------------------------------------------------------------------------------- 1 | 2 | #include "tensorflow/cc/client/client_session.h" 3 | #include "tensorflow/cc/ops/standard_ops.h" 4 | #include "tensorflow/core/framework/tensor.h" 5 | 6 | int main() { 7 | using namespace tensorflow; 8 | using namespace tensorflow::ops; 9 | Scope root = Scope::NewRootScope(); 10 | // Matrix A = [3 2; -1 0] 11 | auto A = Const(root, { {3.f, 2.f}, {-1.f, 0.f} }); 12 | // Vector b = [3 5] 13 | auto b = Const(root, { {3.f, 5.f} }); 14 | // v = Ab^T 15 | auto v = MatMul(root.WithOpName("v"), A, b, MatMul::TransposeB(true)); 16 | std::vector outputs; 17 | ClientSession session(root); 18 | // Run and fetch v 19 | TF_CHECK_OK(session.Run({v}, &outputs)); 20 | // Expect outputs[0] == [19; -3] 21 | LOG(INFO) << outputs[0].matrix(); 22 | return 0; 23 | } 24 | -------------------------------------------------------------------------------- /assets/share/tensorflow/copyright: -------------------------------------------------------------------------------- 1 | Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ 2 | Upstream-Name: TensorFlow 3 | Upstream-Contact: Yuan Tang 4 | Source: 5 | https://github.com/tensorflow/tensorflow 6 | 7 | Files: * 8 | Copyright: 2018, The TensorFlow Authors 9 | License: Apache-2.0 10 | 11 | Files: debian/* 12 | Copyright: © 2018 System76 13 | License: GPL-2+ 14 | This package is free software; you can redistribute it and/or modify 15 | it under the terms of the GNU General Public License as published by 16 | the Free Software Foundation; either version 2 of the License, or 17 | (at your option) any later version. 18 | . 19 | This package is distributed in the hope that it will be useful, 20 | but WITHOUT ANY WARRANTY; without even the implied warranty of 21 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 22 | GNU General Public License for more details. 23 | . 24 | You should have received a copy of the GNU General Public License 25 | along with this program. If not, see 26 | . 27 | On Debian systems, the complete text of the GNU General 28 | Public License version 2 can be found in "/usr/share/common-licenses/GPL-2". 29 | -------------------------------------------------------------------------------- /assets/share/tensorflow/deps.sh: -------------------------------------------------------------------------------- 1 | function exists { 2 | ldconfig -p | grep $1 &>/dev/null && echo 0 || echo 1 3 | } 4 | 5 | CUDA=$(exists libcuda.so) 6 | CUDRT=$(exists libcudart.so) 7 | CUDNN=$(exists libcudnn.so) 8 | CUPTI=$(exists libcupti.so) 9 | 10 | if [ $((CUDA + CUDRT + CUDNN + CUPTI)) -ne 0 ]; then 11 | test $CUDA -eq 0 || echo 'libcuda.so was not found: found in `libnvidia-compute-X`' 12 | test $CUDRT -eq 0 || echo 'libcudart.so was not found: provided by `system76-cuda-X.Y`' 13 | test $CUDNN -eq 0 || echo 'libcudnn.so was not found: provided by `system76-cuda-X.Y`' 14 | test $CUPTI -eq 0 || echo 'libcupti.so was not found: provided by `system76-cuda-X.Y`' 15 | exit 1 16 | fi 17 | -------------------------------------------------------------------------------- /debian/README.md: -------------------------------------------------------------------------------- 1 | # Debian Files 2 | 3 | In this directory, you may place your debian packaging configurations. Each 4 | directory should have the same name of the source package which they are to 5 | build. 6 | -------------------------------------------------------------------------------- /debian/focal/bazel/changelog: -------------------------------------------------------------------------------- 1 | bazel (0.21.0~0pop2) focal; urgency=medium 2 | 3 | * Fix for focal 4 | 5 | -- Michael Aaron Murphy Fri, 19 Apr 2019 21:27:58 -0600 6 | 7 | bazel (0.21.0~0pop1) focal; urgency=medium 8 | 9 | * Update bazel to 0.21.0, to build Tensorflow 1.13.1 10 | 11 | -- Michael Aaron Murphy Fri, 08 Mar 2019 14:39:55 -0700 12 | 13 | bazel (0.16.1~0pop1) cosmic; urgency=medium 14 | 15 | * Update bazel to 0.16.1 16 | 17 | -- Michael Murphy Mon, 6 Jul 2018 10:00:00 -0600 18 | 19 | bazel (0.15.0~0pop1) bionic; urgency=medium 20 | 21 | * Initial release. 22 | 23 | -- Michael Murphy Mon, 6 Jul 2018 10:00:00 -0600 24 | -------------------------------------------------------------------------------- /debian/focal/bazel/control: -------------------------------------------------------------------------------- 1 | Source: bazel 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | openjdk-13-jdk, 10 | python, 11 | zip, 12 | unzip, 13 | 14 | Package: bazel 15 | Description: Build and test tool similar to Make, Maven, and Gradle. 16 | Architecture: amd64 17 | Section: devel 18 | Depends: 19 | build-essential, 20 | openjdk-13-jdk, 21 | python, 22 | zip, 23 | unzip, 24 | ${misc:Depends}, 25 | -------------------------------------------------------------------------------- /debian/focal/bazel/install: -------------------------------------------------------------------------------- 1 | /usr/bin 2 | -------------------------------------------------------------------------------- /debian/focal/bazel/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | # Bazel is incompatible with CCACHE, and CC / CXX must be set to override it. 4 | # Issue: https://github.com/bazelbuild/bazel/issues/1164 5 | export CCACHE_DISABLE=1 6 | export CC=/usr/bin/gcc 7 | export CXX=/usr/bin/g++ 8 | 9 | PREFIX=usr/bin/ 10 | 11 | %: 12 | dh $@ 13 | 14 | override_dh_auto_build: 15 | bash compile.sh 16 | 17 | override_dh_auto_install: 18 | install -Dm0744 output/bazel $(PREFIX)/bazel 19 | 20 | override_dh_strip: 21 | 22 | override_dh_shlibdeps: 23 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-10.1/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda-10.1 (0pop0) focal; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Aaron Murphy Thu, 13 Aug 2019 09:35:22 -0700 6 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-10.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda-10.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | g++-7 9 | 10 | Package: system76-cuda-10.1 11 | Description: NVIDIA CUDA 10 Compiler / Libraries / Toolkit 12 | Architecture: amd64 13 | Section: devel 14 | Depends: 15 | system76-cuda, 16 | ${misc:Depends}, 17 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-10.1/postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | update-alternatives --install /usr/lib/cuda cuda /usr/lib/cuda-10.1 100 3 | ldconfig 4 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-10.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | export CUDA_VERSION=10.1 4 | export DESTDIR=$(PWD)/debian/tmp 5 | export CC=/usr/bin/gcc-7 6 | export CXX=/usr/bin/g++-7 7 | 8 | %: 9 | dh $@ 10 | 11 | override_dh_auto_build: 12 | make \ 13 | INSTALLER=cuda_10.1.105_418.39_linux.run \ 14 | INSTALLER_SUM=4be516e493ef9588f455df0722e2e686 15 | 16 | override_dh_auto_install: 17 | dh_auto_install || (cat /tmp/installer.log; cat /tmp/cuda-installer.log; exit 1) 18 | 19 | # CUDA ships its own shared libraries 20 | override_dh_shlibdeps: 21 | 22 | override_dh_strip: 23 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-10.2/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda-10.2 (0pop1) focal; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 10:35:22 -0700 6 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-10.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda-10.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | g++-8 9 | 10 | Package: system76-cuda-10.2 11 | Description: NVIDIA CUDA 10 Compiler / Libraries / Toolkit 12 | Architecture: amd64 13 | Section: devel 14 | Depends: 15 | system76-cuda, 16 | g++-8, 17 | ${misc:Depends}, 18 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-10.2/postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | update-alternatives --install /usr/lib/cuda cuda /usr/lib/cuda-10.2 100 3 | ldconfig 4 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-10.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | export CUDA_VERSION=10.2 4 | export DESTDIR=$(PWD)/debian/tmp 5 | export CC=/usr/bin/gcc-8 6 | export CXX=/usr/bin/g++-8 7 | 8 | %: 9 | dh $@ 10 | 11 | override_dh_auto_build: 12 | make \ 13 | INSTALLER=cuda_10.2.89_440.33.01_linux.run \ 14 | INSTALLER_SUM=3d816c583759efa8567a92c1a2af90db 15 | 16 | override_dh_auto_install: 17 | dh_auto_install || (cat /tmp/installer.log; cat /tmp/cuda-installer.log; exit 1) 18 | 19 | # CUDA ships its own shared libraries 20 | override_dh_shlibdeps: 21 | 22 | override_dh_strip: 23 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-11.1/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda-11.1 (0pop1) focal; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 10:35:22 -0700 6 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-11.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda-11.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | g++-9 9 | 10 | Package: system76-cuda-11.1 11 | Description: NVIDIA CUDA 11.1 Compiler / Libraries / Toolkit 12 | Architecture: amd64 13 | Section: devel 14 | Depends: 15 | system76-cuda, 16 | g++-9, 17 | ${misc:Depends}, 18 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-11.1/postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | update-alternatives --install /usr/lib/cuda cuda /usr/lib/cuda-11.1 100 3 | ldconfig 4 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-11.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | export CUDA_VERSION=11.1 4 | export DESTDIR=$(PWD)/debian/tmp 5 | export CC=/usr/bin/gcc-9 6 | export CXX=/usr/bin/g++-9 7 | 8 | %: 9 | dh $@ 10 | 11 | override_dh_auto_build: 12 | make \ 13 | INSTALLER=cuda_11.1.1_455.32.00_linux.run \ 14 | INSTALLER_SUM=c24e2755e3868692051a38797ce01044 15 | 16 | override_dh_auto_install: 17 | dh_auto_install || (cat /tmp/installer.log; cat /tmp/cuda-installer.log; exit 1) 18 | 19 | # CUDA ships its own shared libraries 20 | override_dh_shlibdeps: 21 | 22 | override_dh_strip: 23 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-11.2/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda-11.2 (0pop1) focal; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 10:35:22 -0700 6 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-11.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda-11.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | g++-9 9 | 10 | Package: system76-cuda-11.2 11 | Description: NVIDIA CUDA 11.2 Compiler / Libraries / Toolkit 12 | Architecture: amd64 13 | Section: devel 14 | Depends: 15 | system76-cuda, 16 | g++-9, 17 | ${misc:Depends}, 18 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-11.2/postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | update-alternatives --install /usr/lib/cuda cuda /usr/lib/cuda-11.2 100 3 | ldconfig 4 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda-11.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | export CUDA_VERSION=11.2 4 | export DESTDIR=$(PWD)/debian/tmp 5 | export CC=/usr/bin/gcc-9 6 | export CXX=/usr/bin/g++-9 7 | 8 | %: 9 | dh $@ 10 | 11 | override_dh_auto_build: 12 | make \ 13 | INSTALLER=cuda_11.2.0_460.27.04_linux.run \ 14 | INSTALLER_SUM=04b39f63c3b97153631ca12ed230be51 15 | 16 | override_dh_auto_install: 17 | dh_auto_install || (cat /tmp/installer.log; cat /tmp/cuda-installer.log; exit 1) 18 | 19 | # CUDA ships its own shared libraries 20 | override_dh_shlibdeps: 21 | 22 | override_dh_strip: 23 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda/assets/fetch-cuda-samples: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -x 4 | 5 | CHECKSUM=0c67bf836eb11033e3c1aeea8d37e889 6 | CUDA_VERSION=9.2 7 | TMP_FILE=/tmp/cuda-samples-${CUDA_VERSION}.tar.gz 8 | 9 | # Fetch 9.2 samples from NVIDIA's GitHub repository. 10 | wget https://github.com/NVIDIA/cuda-samples/archive/v${CUDA_VERSION}.tar.gz \ 11 | -O ${TMP_FILE} 12 | 13 | # Verify that the downloaded file is valid. 14 | if test ${CHECKSUM} = $(md5sum ${TMP_FILE} | cut -d' ' -f1); then 15 | tar -xzvf ${TMP_FILE} 16 | rm ${TMP_FILE} 17 | else 18 | rm ${TMP_FILE} 19 | echo "The downloaded CUDA ${CUDA_VERSION} samples did not have a valid checksum." 20 | exit 1 21 | fi 22 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda/assets/system76-cuda.conf: -------------------------------------------------------------------------------- 1 | /usr/lib/cuda/lib64 2 | /usr/lib/cuda/extras/CUPTI/lib64 3 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda/assets/system76-cuda.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | export PATH=$PATH:/usr/lib/cuda/bin 4 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda (0pop1) focal; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Murphy Mon, 7 Jan 2019 15:05:00 -0600 6 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: metapackages 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cuda 9 | Description: NVIDIA CUDA Compiler / Libraries / Toolkit Metapackage 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | g++, 14 | freeglut3-dev, 15 | build-essential, 16 | libx11-dev, 17 | libxmu-dev, 18 | ${misc:Depends}, 19 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda/install: -------------------------------------------------------------------------------- 1 | /etc/ 2 | -------------------------------------------------------------------------------- /debian/focal/system76-cuda/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | %: 4 | dh $@ 5 | 6 | override_dh_auto_install: 7 | install -Dm0644 debian/assets/system76-cuda.sh debian/tmp/etc/profile.d/system76-cuda.sh 8 | install -Dm0644 debian/assets/system76-cuda.conf debian/tmp/etc/ld.so.conf.d/system76-cuda.conf 9 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-10.1/changelog: -------------------------------------------------------------------------------- 1 | system76-cudnn-10.1 (8.0.4) focal; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Thu, 13 Aug 2019 10:37:25 -0700 6 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-10.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-cudnn-10.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cudnn-10.1 9 | Description: NVIDIA CUDA Deep Neural Network library (cuDNN) for CUDA 10.2 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | system76-cuda-10.1, 14 | ${misc:Depends}, 15 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-10.1/install: -------------------------------------------------------------------------------- 1 | cuda/* /usr/lib/cuda-10.1/ 2 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-10.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_VERSION=10.1 4 | PREFIX=usr/lib/cuda-$(CUDA_VERSION) 5 | 6 | %: 7 | dh $@ 8 | 9 | override_dh_auto_build: 10 | 11 | override_dh_auto_install: 12 | tar xvf cudnn.tgz 13 | 14 | override_dh_shlibdeps: -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-10.2/changelog: -------------------------------------------------------------------------------- 1 | system76-cudnn-10.2 (8.0.4) focal; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Thu, 19 Dec 2019 10:37:25 -0700 6 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-10.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-cudnn-10.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cudnn-10.2 9 | Description: NVIDIA CUDA Deep Neural Network library (cuDNN) for CUDA 10.2 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | system76-cuda-10.2, 14 | ${misc:Depends}, 15 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-10.2/install: -------------------------------------------------------------------------------- 1 | cuda/* /usr/lib/cuda-10.2/ 2 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-10.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_VERSION=10.2 4 | PREFIX=usr/lib/cuda-$(CUDA_VERSION) 5 | 6 | %: 7 | dh $@ 8 | 9 | override_dh_auto_build: 10 | 11 | override_dh_auto_install: 12 | tar xvf cudnn.tgz 13 | 14 | override_dh_shlibdeps: -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-11.1/changelog: -------------------------------------------------------------------------------- 1 | system76-cudnn-11.1 (8.0.4) focal; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Thu, 19 Dec 2019 10:37:25 -0700 6 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-11.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-cudnn-11.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cudnn-11.1 9 | Description: NVIDIA CUDA Deep Neural Network library (cuDNN) for CUDA 11.1 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | system76-cuda-11.1, 14 | ${misc:Depends}, 15 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-11.1/install: -------------------------------------------------------------------------------- 1 | cuda/* /usr/lib/cuda-11.1/ 2 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-11.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_VERSION=11.1 4 | PREFIX=usr/lib/cuda-$(CUDA_VERSION) 5 | 6 | %: 7 | dh $@ 8 | 9 | override_dh_auto_build: 10 | 11 | override_dh_auto_install: 12 | tar xvf cudnn.tgz 13 | 14 | override_dh_shlibdeps: -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-11.2/changelog: -------------------------------------------------------------------------------- 1 | system76-cudnn-11.2 (8.0.4) focal; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Thu, 19 Dec 2019 10:37:25 -0700 6 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-11.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-cudnn-11.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cudnn-11.2 9 | Description: NVIDIA CUDA Deep Neural Network library (cuDNN) for CUDA 11.2 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | system76-cuda-11.2, 14 | ${misc:Depends}, 15 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-11.2/install: -------------------------------------------------------------------------------- 1 | cuda/* /usr/lib/cuda-11.2/ 2 | -------------------------------------------------------------------------------- /debian/focal/system76-cudnn-11.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_VERSION=11.2 4 | PREFIX=usr/lib/cuda-$(CUDA_VERSION) 5 | 6 | %: 7 | dh $@ 8 | 9 | override_dh_auto_build: 10 | 11 | override_dh_auto_install: 12 | tar xvf cudnn.tgz 13 | 14 | override_dh_shlibdeps: -------------------------------------------------------------------------------- /debian/focal/system76-nccl-10.1/changelog: -------------------------------------------------------------------------------- 1 | system76-nccl-10.1 (2.8.3-1) focal; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 18:40:06 -0700 6 | 7 | system76-nccl-10.1 (2.5.6-2) focal; urgency=medium 8 | 9 | * New upstream release 10 | 11 | -- Michael Aaron Murphy Thu, 13 Aug 2019 10:40:06 -0700 12 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-10.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-nccl-10.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | g++-7, 10 | system76-cuda-10.1, 11 | unzip, 12 | 13 | Package: system76-nccl-10.1 14 | Description: Optimized primitives for collective multi-GPU communication. 15 | Architecture: amd64 16 | Section: devel 17 | Depends: 18 | build-essential, 19 | g++-7, 20 | system76-cuda-10.1, 21 | ${misc:Depends}, 22 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-10.1/install: -------------------------------------------------------------------------------- 1 | usr/lib/cuda-10.1/ 2 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-10.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_SDK=usr/lib/cuda-10.1/ 4 | export CC=/usr/bin/gcc-7 5 | export CXX=/usr/bin/g++-7 6 | 7 | %: 8 | dh $@ 9 | 10 | override_dh_auto_build: 11 | make -j src.build CUDA_HOME=/$(CUDA_SDK) 12 | 13 | override_dh_auto_install: 14 | mkdir -p $(CUDA_SDK)/lib64 $(CUDA_SDK)/include 15 | mv build/lib/* $(CUDA_SDK)/lib64 16 | mv build/include/* $(CUDA_SDK)/include/ 17 | 18 | override_dh_strip: 19 | 20 | override_dh_shlibdeps: 21 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-10.2/changelog: -------------------------------------------------------------------------------- 1 | system76-nccl-10.2 (2.8.3-1) focal; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 18:40:06 -0700 6 | 7 | system76-nccl-10.2 (2.5.6-2) focal; urgency=medium 8 | 9 | * New upstream release 10 | 11 | -- Michael Aaron Murphy Thu, 19 Dec 2019 10:40:06 -0700 12 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-10.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-nccl-10.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | g++-8, 10 | system76-cuda-10.2, 11 | unzip, 12 | 13 | Package: system76-nccl-10.2 14 | Description: Optimized primitives for collective multi-GPU communication. 15 | Architecture: amd64 16 | Section: devel 17 | Depends: 18 | build-essential, 19 | g++-8, 20 | system76-cuda-10.2, 21 | ${misc:Depends}, 22 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-10.2/install: -------------------------------------------------------------------------------- 1 | usr/lib/cuda-10.2/ 2 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-10.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_SDK=usr/lib/cuda-10.2/ 4 | export CC=/usr/bin/gcc-8 5 | export CXX=/usr/bin/g++-8 6 | 7 | %: 8 | dh $@ 9 | 10 | override_dh_auto_build: 11 | make -j src.build CUDA_HOME=/$(CUDA_SDK) 12 | 13 | override_dh_auto_install: 14 | mkdir -p $(CUDA_SDK)/lib64 $(CUDA_SDK)/include 15 | mv build/lib/* $(CUDA_SDK)/lib64 16 | mv build/include/* $(CUDA_SDK)/include/ 17 | 18 | override_dh_strip: 19 | 20 | override_dh_shlibdeps: 21 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-11.1/changelog: -------------------------------------------------------------------------------- 1 | system76-nccl-11.1 (2.8.3-1) focal; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 18:40:06 -0700 6 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-11.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-nccl-11.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | g++-9, 10 | system76-cuda-11.1, 11 | unzip, 12 | 13 | Package: system76-nccl-11.1 14 | Description: Optimized primitives for collective multi-GPU communication. 15 | Architecture: amd64 16 | Section: devel 17 | Depends: 18 | build-essential, 19 | g++-9, 20 | system76-cuda-11.1, 21 | ${misc:Depends}, 22 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-11.1/install: -------------------------------------------------------------------------------- 1 | usr/lib/cuda-11.1/ 2 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-11.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_SDK=usr/lib/cuda-11.1/ 4 | export CC=/usr/bin/gcc-9 5 | export CXX=/usr/bin/g++-9 6 | 7 | %: 8 | dh $@ 9 | 10 | override_dh_auto_build: 11 | make -j src.build CUDA_HOME=/$(CUDA_SDK) 12 | 13 | override_dh_auto_install: 14 | mkdir -p $(CUDA_SDK)/lib64 $(CUDA_SDK)/include 15 | mv build/lib/* $(CUDA_SDK)/lib64 16 | mv build/include/* $(CUDA_SDK)/include/ 17 | 18 | override_dh_strip: 19 | 20 | override_dh_shlibdeps: 21 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-11.2/changelog: -------------------------------------------------------------------------------- 1 | system76-nccl-11.2 (2.8.3-1) focal; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 18:40:06 -0700 6 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-11.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-nccl-11.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | g++-9, 10 | system76-cuda-11.2, 11 | unzip, 12 | 13 | Package: system76-nccl-11.2 14 | Description: Optimized primitives for collective multi-GPU communication. 15 | Architecture: amd64 16 | Section: devel 17 | Depends: 18 | build-essential, 19 | g++-9, 20 | system76-cuda-11.2, 21 | ${misc:Depends}, 22 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-11.2/install: -------------------------------------------------------------------------------- 1 | usr/lib/cuda-11.2/ 2 | -------------------------------------------------------------------------------- /debian/focal/system76-nccl-11.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_SDK=usr/lib/cuda-11.2/ 4 | export CC=/usr/bin/gcc-9 5 | export CXX=/usr/bin/g++-9 6 | 7 | %: 8 | dh $@ 9 | 10 | override_dh_auto_build: 11 | make -j src.build CUDA_HOME=/$(CUDA_SDK) 12 | 13 | override_dh_auto_install: 14 | mkdir -p $(CUDA_SDK)/lib64 $(CUDA_SDK)/include 15 | mv build/lib/* $(CUDA_SDK)/lib64 16 | mv build/include/* $(CUDA_SDK)/include/ 17 | 18 | override_dh_strip: 19 | 20 | override_dh_shlibdeps: 21 | -------------------------------------------------------------------------------- /debian/groovy/bazel/changelog: -------------------------------------------------------------------------------- 1 | bazel (0.21.0~0pop2) groovy; urgency=medium 2 | 3 | * Fix for groovy 4 | 5 | -- Michael Aaron Murphy Fri, 19 Apr 2019 21:27:58 -0600 6 | 7 | bazel (0.21.0~0pop1) groovy; urgency=medium 8 | 9 | * Update bazel to 0.21.0, to build Tensorflow 1.13.1 10 | 11 | -- Michael Aaron Murphy Fri, 08 Mar 2019 14:39:55 -0700 12 | 13 | bazel (0.16.1~0pop1) cosmic; urgency=medium 14 | 15 | * Update bazel to 0.16.1 16 | 17 | -- Michael Murphy Mon, 6 Jul 2018 10:00:00 -0600 18 | 19 | bazel (0.15.0~0pop1) bionic; urgency=medium 20 | 21 | * Initial release. 22 | 23 | -- Michael Murphy Mon, 6 Jul 2018 10:00:00 -0600 24 | -------------------------------------------------------------------------------- /debian/groovy/bazel/control: -------------------------------------------------------------------------------- 1 | Source: bazel 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | openjdk-13-jdk, 10 | python, 11 | zip, 12 | unzip, 13 | 14 | Package: bazel 15 | Description: Build and test tool similar to Make, Maven, and Gradle. 16 | Architecture: amd64 17 | Section: devel 18 | Depends: 19 | build-essential, 20 | openjdk-13-jdk, 21 | python, 22 | zip, 23 | unzip, 24 | ${misc:Depends}, 25 | -------------------------------------------------------------------------------- /debian/groovy/bazel/install: -------------------------------------------------------------------------------- 1 | /usr/bin 2 | -------------------------------------------------------------------------------- /debian/groovy/bazel/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | # Bazel is incompatible with CCACHE, and CC / CXX must be set to override it. 4 | # Issue: https://github.com/bazelbuild/bazel/issues/1164 5 | export CCACHE_DISABLE=1 6 | export CC=/usr/bin/gcc 7 | export CXX=/usr/bin/g++ 8 | 9 | PREFIX=usr/bin/ 10 | 11 | %: 12 | dh $@ 13 | 14 | override_dh_auto_build: 15 | bash compile.sh 16 | 17 | override_dh_auto_install: 18 | install -Dm0744 output/bazel $(PREFIX)/bazel 19 | 20 | override_dh_strip: 21 | 22 | override_dh_shlibdeps: 23 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-10.1/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda-10.1 (0pop0) groovy; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Aaron Murphy Thu, 13 Aug 2019 09:35:22 -0700 6 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-10.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda-10.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | g++-7 9 | 10 | Package: system76-cuda-10.1 11 | Description: NVIDIA CUDA 10 Compiler / Libraries / Toolkit 12 | Architecture: amd64 13 | Section: devel 14 | Depends: 15 | system76-cuda, 16 | ${misc:Depends}, 17 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-10.1/postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | update-alternatives --install /usr/lib/cuda cuda /usr/lib/cuda-10.1 100 3 | ldconfig 4 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-10.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | export CUDA_VERSION=10.1 4 | export DESTDIR=$(PWD)/debian/tmp 5 | export CC=/usr/bin/gcc-7 6 | export CXX=/usr/bin/g++-7 7 | 8 | %: 9 | dh $@ 10 | 11 | override_dh_auto_build: 12 | make \ 13 | INSTALLER=cuda_10.1.105_418.39_linux.run \ 14 | INSTALLER_SUM=4be516e493ef9588f455df0722e2e686 15 | 16 | override_dh_auto_install: 17 | dh_auto_install || (cat /tmp/installer.log; cat /tmp/cuda-installer.log; exit 1) 18 | 19 | # CUDA ships its own shared libraries 20 | override_dh_shlibdeps: 21 | 22 | override_dh_strip: 23 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-10.2/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda-10.2 (0pop1) groovy; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 10:35:22 -0700 6 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-10.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda-10.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | g++-8 9 | 10 | Package: system76-cuda-10.2 11 | Description: NVIDIA CUDA 10 Compiler / Libraries / Toolkit 12 | Architecture: amd64 13 | Section: devel 14 | Depends: 15 | system76-cuda, 16 | g++-8, 17 | ${misc:Depends}, 18 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-10.2/postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | update-alternatives --install /usr/lib/cuda cuda /usr/lib/cuda-10.2 100 3 | ldconfig 4 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-10.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | export CUDA_VERSION=10.2 4 | export DESTDIR=$(PWD)/debian/tmp 5 | export CC=/usr/bin/gcc-8 6 | export CXX=/usr/bin/g++-8 7 | 8 | %: 9 | dh $@ 10 | 11 | override_dh_auto_build: 12 | make \ 13 | INSTALLER=cuda_10.2.89_440.33.01_linux.run \ 14 | INSTALLER_SUM=3d816c583759efa8567a92c1a2af90db 15 | 16 | override_dh_auto_install: 17 | dh_auto_install || (cat /tmp/installer.log; cat /tmp/cuda-installer.log; exit 1) 18 | 19 | # CUDA ships its own shared libraries 20 | override_dh_shlibdeps: 21 | 22 | override_dh_strip: 23 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-11.1/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda-11.1 (0pop1) groovy; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 10:35:22 -0700 6 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-11.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda-11.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | g++-9, 8 | debhelper (>= 9) 9 | 10 | Package: system76-cuda-11.1 11 | Description: NVIDIA CUDA 11.1 Compiler / Libraries / Toolkit 12 | Architecture: amd64 13 | Section: devel 14 | Depends: 15 | system76-cuda, 16 | g++-9, 17 | ${misc:Depends}, 18 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-11.1/postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | update-alternatives --install /usr/lib/cuda cuda /usr/lib/cuda-11.1 100 3 | ldconfig 4 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-11.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | export CUDA_VERSION=11.1 4 | export DESTDIR=$(PWD)/debian/tmp 5 | export CC=/usr/bin/gcc-9 6 | export CXX=/usr/bin/g++-9 7 | 8 | %: 9 | dh $@ 10 | 11 | override_dh_auto_build: 12 | make \ 13 | INSTALLER=cuda_11.1.1_455.32.00_linux.run \ 14 | INSTALLER_SUM=c24e2755e3868692051a38797ce01044 15 | 16 | override_dh_auto_install: 17 | dh_auto_install || (cat /tmp/installer.log; cat /tmp/cuda-installer.log; exit 1) 18 | 19 | # CUDA ships its own shared libraries 20 | override_dh_shlibdeps: 21 | 22 | override_dh_strip: 23 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-11.2/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda-11.2 (0pop1) groovy; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 10:35:22 -0700 6 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-11.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda-11.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | g++-9 9 | 10 | Package: system76-cuda-11.2 11 | Description: NVIDIA CUDA 11.2 Compiler / Libraries / Toolkit 12 | Architecture: amd64 13 | Section: devel 14 | Depends: 15 | system76-cuda, 16 | g++-9, 17 | ${misc:Depends}, 18 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-11.2/postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | update-alternatives --install /usr/lib/cuda cuda /usr/lib/cuda-11.2 100 3 | ldconfig 4 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda-11.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | export CUDA_VERSION=11.2 4 | export DESTDIR=$(PWD)/debian/tmp 5 | export CC=/usr/bin/gcc-9 6 | export CXX=/usr/bin/g++-9 7 | 8 | %: 9 | dh $@ 10 | 11 | override_dh_auto_build: 12 | make \ 13 | INSTALLER=cuda_11.2.0_460.27.04_linux.run \ 14 | INSTALLER_SUM=04b39f63c3b97153631ca12ed230be51 15 | 16 | override_dh_auto_install: 17 | dh_auto_install || (cat /tmp/installer.log; cat /tmp/cuda-installer.log; exit 1) 18 | 19 | # CUDA ships its own shared libraries 20 | override_dh_shlibdeps: 21 | 22 | override_dh_strip: 23 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda/assets/fetch-cuda-samples: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -x 4 | 5 | CHECKSUM=0c67bf836eb11033e3c1aeea8d37e889 6 | CUDA_VERSION=9.2 7 | TMP_FILE=/tmp/cuda-samples-${CUDA_VERSION}.tar.gz 8 | 9 | # Fetch 9.2 samples from NVIDIA's GitHub repository. 10 | wget https://github.com/NVIDIA/cuda-samples/archive/v${CUDA_VERSION}.tar.gz \ 11 | -O ${TMP_FILE} 12 | 13 | # Verify that the downloaded file is valid. 14 | if test ${CHECKSUM} = $(md5sum ${TMP_FILE} | cut -d' ' -f1); then 15 | tar -xzvf ${TMP_FILE} 16 | rm ${TMP_FILE} 17 | else 18 | rm ${TMP_FILE} 19 | echo "The downloaded CUDA ${CUDA_VERSION} samples did not have a valid checksum." 20 | exit 1 21 | fi 22 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda/assets/system76-cuda.conf: -------------------------------------------------------------------------------- 1 | /usr/lib/cuda/lib64 2 | /usr/lib/cuda/extras/CUPTI/lib64 3 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda/assets/system76-cuda.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | export PATH=$PATH:/usr/lib/cuda/bin 4 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda (0pop1) groovy; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Murphy Mon, 7 Jan 2019 15:05:00 -0600 6 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: metapackages 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cuda 9 | Description: NVIDIA CUDA Compiler / Libraries / Toolkit Metapackage 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | g++, 14 | freeglut3-dev, 15 | build-essential, 16 | libx11-dev, 17 | libxmu-dev, 18 | ${misc:Depends}, 19 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda/install: -------------------------------------------------------------------------------- 1 | /etc/ 2 | -------------------------------------------------------------------------------- /debian/groovy/system76-cuda/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | %: 4 | dh $@ 5 | 6 | override_dh_auto_install: 7 | install -Dm0644 debian/assets/system76-cuda.sh debian/tmp/etc/profile.d/system76-cuda.sh 8 | install -Dm0644 debian/assets/system76-cuda.conf debian/tmp/etc/ld.so.conf.d/system76-cuda.conf 9 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-10.1/changelog: -------------------------------------------------------------------------------- 1 | system76-cudnn-10.1 (8.0.4) groovy; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Thu, 13 Aug 2019 10:37:25 -0700 6 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-10.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-cudnn-10.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cudnn-10.1 9 | Description: NVIDIA CUDA Deep Neural Network library (cuDNN) for CUDA 10.2 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | system76-cuda-10.1, 14 | ${misc:Depends}, 15 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-10.1/install: -------------------------------------------------------------------------------- 1 | cuda/* /usr/lib/cuda-10.1/ 2 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-10.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_VERSION=10.1 4 | PREFIX=usr/lib/cuda-$(CUDA_VERSION) 5 | 6 | %: 7 | dh $@ 8 | 9 | override_dh_auto_build: 10 | 11 | override_dh_auto_install: 12 | tar xvf cudnn.tgz 13 | 14 | override_dh_shlibdeps: -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-10.2/changelog: -------------------------------------------------------------------------------- 1 | system76-cudnn-10.2 (8.0.4) groovy; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Thu, 19 Dec 2019 10:37:25 -0700 6 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-10.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-cudnn-10.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cudnn-10.2 9 | Description: NVIDIA CUDA Deep Neural Network library (cuDNN) for CUDA 10.2 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | system76-cuda-10.2, 14 | ${misc:Depends}, 15 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-10.2/install: -------------------------------------------------------------------------------- 1 | cuda/* /usr/lib/cuda-10.2/ 2 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-10.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_VERSION=10.2 4 | PREFIX=usr/lib/cuda-$(CUDA_VERSION) 5 | 6 | %: 7 | dh $@ 8 | 9 | override_dh_auto_build: 10 | 11 | override_dh_auto_install: 12 | tar xvf cudnn.tgz 13 | 14 | override_dh_shlibdeps: -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-11.1/changelog: -------------------------------------------------------------------------------- 1 | system76-cudnn-11.1 (8.0.4) groovy; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Thu, 19 Dec 2019 10:37:25 -0700 6 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-11.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-cudnn-11.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cudnn-11.1 9 | Description: NVIDIA CUDA Deep Neural Network library (cuDNN) for CUDA 11.1 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | system76-cuda-11.1, 14 | ${misc:Depends}, 15 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-11.1/install: -------------------------------------------------------------------------------- 1 | cuda/* /usr/lib/cuda-11.1/ 2 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-11.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_VERSION=11.1 4 | PREFIX=usr/lib/cuda-$(CUDA_VERSION) 5 | 6 | %: 7 | dh $@ 8 | 9 | override_dh_auto_build: 10 | 11 | override_dh_auto_install: 12 | tar xvf cudnn.tgz 13 | 14 | override_dh_shlibdeps: -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-11.2/changelog: -------------------------------------------------------------------------------- 1 | system76-cudnn-11.2 (8.0.4) groovy; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Thu, 19 Dec 2019 10:37:25 -0700 6 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-11.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-cudnn-11.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cudnn-11.2 9 | Description: NVIDIA CUDA Deep Neural Network library (cuDNN) for CUDA 11.2 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | system76-cuda-11.2, 14 | ${misc:Depends}, 15 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-11.2/install: -------------------------------------------------------------------------------- 1 | cuda/* /usr/lib/cuda-11.2/ 2 | -------------------------------------------------------------------------------- /debian/groovy/system76-cudnn-11.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_VERSION=11.2 4 | PREFIX=usr/lib/cuda-$(CUDA_VERSION) 5 | 6 | %: 7 | dh $@ 8 | 9 | override_dh_auto_build: 10 | 11 | override_dh_auto_install: 12 | tar xvf cudnn.tgz 13 | 14 | override_dh_shlibdeps: -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-10.1/changelog: -------------------------------------------------------------------------------- 1 | system76-nccl-10.1 (2.8.3-1) groovy; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 18:40:06 -0700 6 | 7 | system76-nccl-10.1 (2.5.6-2) groovy; urgency=medium 8 | 9 | * New upstream release 10 | 11 | -- Michael Aaron Murphy Thu, 13 Aug 2019 10:40:06 -0700 12 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-10.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-nccl-10.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | g++-7, 10 | system76-cuda-10.1, 11 | unzip, 12 | 13 | Package: system76-nccl-10.1 14 | Description: Optimized primitives for collective multi-GPU communication. 15 | Architecture: amd64 16 | Section: devel 17 | Depends: 18 | build-essential, 19 | g++-7, 20 | system76-cuda-10.1, 21 | ${misc:Depends}, 22 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-10.1/install: -------------------------------------------------------------------------------- 1 | usr/lib/cuda-10.1/ 2 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-10.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_SDK=usr/lib/cuda-10.1/ 4 | export CC=/usr/bin/gcc-7 5 | export CXX=/usr/bin/g++-7 6 | 7 | %: 8 | dh $@ 9 | 10 | override_dh_auto_build: 11 | make -j src.build CUDA_HOME=/$(CUDA_SDK) 12 | 13 | override_dh_auto_install: 14 | mkdir -p $(CUDA_SDK)/lib64 $(CUDA_SDK)/include 15 | mv build/lib/* $(CUDA_SDK)/lib64 16 | mv build/include/* $(CUDA_SDK)/include/ 17 | 18 | override_dh_strip: 19 | 20 | override_dh_shlibdeps: 21 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-10.2/changelog: -------------------------------------------------------------------------------- 1 | system76-nccl-10.2 (2.8.3-1) groovy; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 18:40:06 -0700 6 | 7 | system76-nccl-10.2 (2.5.6-2) groovy; urgency=medium 8 | 9 | * New upstream release 10 | 11 | -- Michael Aaron Murphy Thu, 19 Dec 2019 10:40:06 -0700 12 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-10.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-nccl-10.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | g++-8, 10 | system76-cuda-10.2, 11 | unzip, 12 | 13 | Package: system76-nccl-10.2 14 | Description: Optimized primitives for collective multi-GPU communication. 15 | Architecture: amd64 16 | Section: devel 17 | Depends: 18 | build-essential, 19 | g++-8, 20 | system76-cuda-10.2, 21 | ${misc:Depends}, 22 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-10.2/install: -------------------------------------------------------------------------------- 1 | usr/lib/cuda-10.2/ 2 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-10.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_SDK=usr/lib/cuda-10.2/ 4 | export CC=/usr/bin/gcc-8 5 | export CXX=/usr/bin/g++-8 6 | 7 | %: 8 | dh $@ 9 | 10 | override_dh_auto_build: 11 | make -j src.build CUDA_HOME=/$(CUDA_SDK) 12 | 13 | override_dh_auto_install: 14 | mkdir -p $(CUDA_SDK)/lib64 $(CUDA_SDK)/include 15 | mv build/lib/* $(CUDA_SDK)/lib64 16 | mv build/include/* $(CUDA_SDK)/include/ 17 | 18 | override_dh_strip: 19 | 20 | override_dh_shlibdeps: 21 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-11.1/changelog: -------------------------------------------------------------------------------- 1 | system76-nccl-11.1 (2.8.3-1) groovy; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 18:40:06 -0700 6 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-11.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-nccl-11.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | g++-9, 10 | system76-cuda-11.1, 11 | unzip, 12 | 13 | Package: system76-nccl-11.1 14 | Description: Optimized primitives for collective multi-GPU communication. 15 | Architecture: amd64 16 | Section: devel 17 | Depends: 18 | build-essential, 19 | g++-9, 20 | system76-cuda-11.1, 21 | ${misc:Depends}, 22 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-11.1/install: -------------------------------------------------------------------------------- 1 | usr/lib/cuda-11.1/ 2 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-11.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_SDK=usr/lib/cuda-11.1/ 4 | export CC=/usr/bin/gcc-9 5 | export CXX=/usr/bin/g++-9 6 | 7 | %: 8 | dh $@ 9 | 10 | override_dh_auto_build: 11 | make -j src.build CUDA_HOME=/$(CUDA_SDK) 12 | 13 | override_dh_auto_install: 14 | mkdir -p $(CUDA_SDK)/lib64 $(CUDA_SDK)/include 15 | mv build/lib/* $(CUDA_SDK)/lib64 16 | mv build/include/* $(CUDA_SDK)/include/ 17 | 18 | override_dh_strip: 19 | 20 | override_dh_shlibdeps: 21 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-11.2/changelog: -------------------------------------------------------------------------------- 1 | system76-nccl-11.2 (2.8.3-1) groovy; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 18:40:06 -0700 6 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-11.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-nccl-11.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | g++-9, 10 | system76-cuda-11.2, 11 | unzip, 12 | 13 | Package: system76-nccl-11.2 14 | Description: Optimized primitives for collective multi-GPU communication. 15 | Architecture: amd64 16 | Section: devel 17 | Depends: 18 | build-essential, 19 | g++-9, 20 | system76-cuda-11.2, 21 | ${misc:Depends}, 22 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-11.2/install: -------------------------------------------------------------------------------- 1 | usr/lib/cuda-11.2/ 2 | -------------------------------------------------------------------------------- /debian/groovy/system76-nccl-11.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_SDK=usr/lib/cuda-11.2/ 4 | export CC=/usr/bin/gcc-9 5 | export CXX=/usr/bin/g++-9 6 | 7 | %: 8 | dh $@ 9 | 10 | override_dh_auto_build: 11 | make -j src.build CUDA_HOME=/$(CUDA_SDK) 12 | 13 | override_dh_auto_install: 14 | mkdir -p $(CUDA_SDK)/lib64 $(CUDA_SDK)/include 15 | mv build/lib/* $(CUDA_SDK)/lib64 16 | mv build/include/* $(CUDA_SDK)/include/ 17 | 18 | override_dh_strip: 19 | 20 | override_dh_shlibdeps: 21 | -------------------------------------------------------------------------------- /debian/impish/bazel/changelog: -------------------------------------------------------------------------------- 1 | bazel (0.21.0~0pop2) impish; urgency=medium 2 | 3 | * Fix for groovy 4 | 5 | -- Michael Aaron Murphy Fri, 19 Apr 2019 21:27:58 -0600 6 | 7 | bazel (0.21.0~0pop1) hirsute; urgency=medium 8 | 9 | * Update bazel to 0.21.0, to build Tensorflow 1.13.1 10 | 11 | -- Michael Aaron Murphy Fri, 08 Mar 2019 14:39:55 -0700 12 | 13 | bazel (0.16.1~0pop1) cosmic; urgency=medium 14 | 15 | * Update bazel to 0.16.1 16 | 17 | -- Michael Murphy Mon, 6 Jul 2018 10:00:00 -0600 18 | 19 | bazel (0.15.0~0pop1) bionic; urgency=medium 20 | 21 | * Initial release. 22 | 23 | -- Michael Murphy Mon, 6 Jul 2018 10:00:00 -0600 24 | -------------------------------------------------------------------------------- /debian/impish/bazel/control: -------------------------------------------------------------------------------- 1 | Source: bazel 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | openjdk-13-jdk, 10 | python, 11 | zip, 12 | unzip, 13 | 14 | Package: bazel 15 | Description: Build and test tool similar to Make, Maven, and Gradle. 16 | Architecture: amd64 17 | Section: devel 18 | Depends: 19 | build-essential, 20 | openjdk-13-jdk, 21 | python, 22 | zip, 23 | unzip, 24 | ${misc:Depends}, 25 | -------------------------------------------------------------------------------- /debian/impish/bazel/install: -------------------------------------------------------------------------------- 1 | /usr/bin 2 | -------------------------------------------------------------------------------- /debian/impish/bazel/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | # Bazel is incompatible with CCACHE, and CC / CXX must be set to override it. 4 | # Issue: https://github.com/bazelbuild/bazel/issues/1164 5 | export CCACHE_DISABLE=1 6 | export CC=/usr/bin/gcc 7 | export CXX=/usr/bin/g++ 8 | 9 | PREFIX=usr/bin/ 10 | 11 | %: 12 | dh $@ 13 | 14 | override_dh_auto_build: 15 | bash compile.sh 16 | 17 | override_dh_auto_install: 18 | install -Dm0744 output/bazel $(PREFIX)/bazel 19 | 20 | override_dh_strip: 21 | 22 | override_dh_shlibdeps: 23 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda-11.1/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda-11.1 (0pop1) impish; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 10:35:22 -0700 6 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda-11.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda-11.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | g++-9, 8 | debhelper (>= 9) 9 | 10 | Package: system76-cuda-11.1 11 | Description: NVIDIA CUDA 11.1 Compiler / Libraries / Toolkit 12 | Architecture: amd64 13 | Section: devel 14 | Depends: 15 | system76-cuda, 16 | g++-9, 17 | ${misc:Depends}, 18 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda-11.1/postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | update-alternatives --install /usr/lib/cuda cuda /usr/lib/cuda-11.1 100 3 | ldconfig 4 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda-11.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | export CUDA_VERSION=11.1 4 | export DESTDIR=$(PWD)/debian/tmp 5 | export CC=/usr/bin/gcc-9 6 | export CXX=/usr/bin/g++-9 7 | 8 | %: 9 | dh $@ 10 | 11 | override_dh_auto_build: 12 | make \ 13 | INSTALLER=cuda_11.1.1_455.32.00_linux.run \ 14 | INSTALLER_SUM=c24e2755e3868692051a38797ce01044 15 | 16 | override_dh_auto_install: 17 | dh_auto_install || (cat /tmp/installer.log; cat /tmp/cuda-installer.log; exit 1) 18 | 19 | # CUDA ships its own shared libraries 20 | override_dh_shlibdeps: 21 | 22 | override_dh_strip: 23 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda-11.2/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda-11.2 (0pop1) impish; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 10:35:22 -0700 6 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda-11.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda-11.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | g++-9 9 | 10 | Package: system76-cuda-11.2 11 | Description: NVIDIA CUDA 11.2 Compiler / Libraries / Toolkit 12 | Architecture: amd64 13 | Section: devel 14 | Depends: 15 | system76-cuda, 16 | g++-9, 17 | ${misc:Depends}, 18 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda-11.2/postinst: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | update-alternatives --install /usr/lib/cuda cuda /usr/lib/cuda-11.2 100 3 | ldconfig 4 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda-11.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | export CUDA_VERSION=11.2 4 | export DESTDIR=$(PWD)/debian/tmp 5 | export CC=/usr/bin/gcc-9 6 | export CXX=/usr/bin/g++-9 7 | 8 | %: 9 | dh $@ 10 | 11 | override_dh_auto_build: 12 | make \ 13 | INSTALLER=cuda_11.2.0_460.27.04_linux.run \ 14 | INSTALLER_SUM=04b39f63c3b97153631ca12ed230be51 15 | 16 | override_dh_auto_install: 17 | dh_auto_install || (cat /tmp/installer.log; cat /tmp/cuda-installer.log; exit 1) 18 | 19 | # CUDA ships its own shared libraries 20 | override_dh_shlibdeps: 21 | 22 | override_dh_strip: 23 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda/assets/fetch-cuda-samples: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | set -x 4 | 5 | CHECKSUM=0c67bf836eb11033e3c1aeea8d37e889 6 | CUDA_VERSION=9.2 7 | TMP_FILE=/tmp/cuda-samples-${CUDA_VERSION}.tar.gz 8 | 9 | # Fetch 9.2 samples from NVIDIA's GitHub repository. 10 | wget https://github.com/NVIDIA/cuda-samples/archive/v${CUDA_VERSION}.tar.gz \ 11 | -O ${TMP_FILE} 12 | 13 | # Verify that the downloaded file is valid. 14 | if test ${CHECKSUM} = $(md5sum ${TMP_FILE} | cut -d' ' -f1); then 15 | tar -xzvf ${TMP_FILE} 16 | rm ${TMP_FILE} 17 | else 18 | rm ${TMP_FILE} 19 | echo "The downloaded CUDA ${CUDA_VERSION} samples did not have a valid checksum." 20 | exit 1 21 | fi 22 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda/assets/system76-cuda.conf: -------------------------------------------------------------------------------- 1 | /usr/lib/cuda/lib64 2 | /usr/lib/cuda/extras/CUPTI/lib64 3 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda/assets/system76-cuda.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | export PATH=$PATH:/usr/lib/cuda/bin 4 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda/changelog: -------------------------------------------------------------------------------- 1 | system76-cuda (0pop1) impish; urgency=medium 2 | 3 | * Initial release. 4 | 5 | -- Michael Murphy Mon, 7 Jan 2019 15:05:00 -0600 6 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda/control: -------------------------------------------------------------------------------- 1 | Source: system76-cuda 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: metapackages 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cuda 9 | Description: NVIDIA CUDA Compiler / Libraries / Toolkit Metapackage 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | g++, 14 | freeglut3-dev, 15 | build-essential, 16 | libx11-dev, 17 | libxmu-dev, 18 | ${misc:Depends}, 19 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda/install: -------------------------------------------------------------------------------- 1 | /etc/ 2 | -------------------------------------------------------------------------------- /debian/impish/system76-cuda/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | %: 4 | dh $@ 5 | 6 | override_dh_auto_install: 7 | install -Dm0644 debian/assets/system76-cuda.sh debian/tmp/etc/profile.d/system76-cuda.sh 8 | install -Dm0644 debian/assets/system76-cuda.conf debian/tmp/etc/ld.so.conf.d/system76-cuda.conf 9 | -------------------------------------------------------------------------------- /debian/impish/system76-cudnn-11.1/changelog: -------------------------------------------------------------------------------- 1 | system76-cudnn-11.1 (8.0.4) impish; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Thu, 19 Dec 2019 10:37:25 -0700 6 | -------------------------------------------------------------------------------- /debian/impish/system76-cudnn-11.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-cudnn-11.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cudnn-11.1 9 | Description: NVIDIA CUDA Deep Neural Network library (cuDNN) for CUDA 11.1 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | system76-cuda-11.1, 14 | ${misc:Depends}, 15 | -------------------------------------------------------------------------------- /debian/impish/system76-cudnn-11.1/install: -------------------------------------------------------------------------------- 1 | cuda/* /usr/lib/cuda-11.1/ 2 | -------------------------------------------------------------------------------- /debian/impish/system76-cudnn-11.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_VERSION=11.1 4 | PREFIX=usr/lib/cuda-$(CUDA_VERSION) 5 | 6 | %: 7 | dh $@ 8 | 9 | override_dh_auto_build: 10 | 11 | override_dh_auto_install: 12 | tar xvf cudnn.tgz 13 | 14 | override_dh_shlibdeps: -------------------------------------------------------------------------------- /debian/impish/system76-cudnn-11.2/changelog: -------------------------------------------------------------------------------- 1 | system76-cudnn-11.2 (8.0.4) impish; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Thu, 19 Dec 2019 10:37:25 -0700 6 | -------------------------------------------------------------------------------- /debian/impish/system76-cudnn-11.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-cudnn-11.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: debhelper (>= 9) 7 | 8 | Package: system76-cudnn-11.2 9 | Description: NVIDIA CUDA Deep Neural Network library (cuDNN) for CUDA 11.2 10 | Architecture: amd64 11 | Section: devel 12 | Depends: 13 | system76-cuda-11.2, 14 | ${misc:Depends}, 15 | -------------------------------------------------------------------------------- /debian/impish/system76-cudnn-11.2/install: -------------------------------------------------------------------------------- 1 | cuda/* /usr/lib/cuda-11.2/ 2 | -------------------------------------------------------------------------------- /debian/impish/system76-cudnn-11.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_VERSION=11.2 4 | PREFIX=usr/lib/cuda-$(CUDA_VERSION) 5 | 6 | %: 7 | dh $@ 8 | 9 | override_dh_auto_build: 10 | 11 | override_dh_auto_install: 12 | tar xvf cudnn.tgz 13 | 14 | override_dh_shlibdeps: -------------------------------------------------------------------------------- /debian/impish/system76-nccl-11.1/changelog: -------------------------------------------------------------------------------- 1 | system76-nccl-11.1 (2.8.3-1) impish; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 18:40:06 -0700 6 | -------------------------------------------------------------------------------- /debian/impish/system76-nccl-11.1/control: -------------------------------------------------------------------------------- 1 | Source: system76-nccl-11.1 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | g++-9, 10 | system76-cuda-11.1, 11 | unzip, 12 | 13 | Package: system76-nccl-11.1 14 | Description: Optimized primitives for collective multi-GPU communication. 15 | Architecture: amd64 16 | Section: devel 17 | Depends: 18 | build-essential, 19 | g++-9, 20 | system76-cuda-11.1, 21 | ${misc:Depends}, 22 | -------------------------------------------------------------------------------- /debian/impish/system76-nccl-11.1/install: -------------------------------------------------------------------------------- 1 | usr/lib/cuda-11.1/ 2 | -------------------------------------------------------------------------------- /debian/impish/system76-nccl-11.1/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_SDK=usr/lib/cuda-11.1/ 4 | export CC=/usr/bin/gcc-9 5 | export CXX=/usr/bin/g++-9 6 | 7 | %: 8 | dh $@ 9 | 10 | override_dh_auto_build: 11 | make -j src.build CUDA_HOME=/$(CUDA_SDK) 12 | 13 | override_dh_auto_install: 14 | mkdir -p $(CUDA_SDK)/lib64 $(CUDA_SDK)/include 15 | mv build/lib/* $(CUDA_SDK)/lib64 16 | mv build/include/* $(CUDA_SDK)/include/ 17 | 18 | override_dh_strip: 19 | 20 | override_dh_shlibdeps: 21 | -------------------------------------------------------------------------------- /debian/impish/system76-nccl-11.2/changelog: -------------------------------------------------------------------------------- 1 | system76-nccl-11.2 (2.8.3-1) impish; urgency=medium 2 | 3 | * New upstream release 4 | 5 | -- Michael Aaron Murphy Fri, 14 Aug 2020 18:40:06 -0700 6 | -------------------------------------------------------------------------------- /debian/impish/system76-nccl-11.2/control: -------------------------------------------------------------------------------- 1 | Source: system76-nccl-11.2 2 | Maintainer: Michael Aaron Murphy 3 | Standards-Version: 4.1.1 4 | Priority: optional 5 | Section: devel 6 | Build-Depends: 7 | debhelper (>= 9), 8 | build-essential, 9 | g++-9, 10 | system76-cuda-11.2, 11 | unzip, 12 | 13 | Package: system76-nccl-11.2 14 | Description: Optimized primitives for collective multi-GPU communication. 15 | Architecture: amd64 16 | Section: devel 17 | Depends: 18 | build-essential, 19 | g++-9, 20 | system76-cuda-11.2, 21 | ${misc:Depends}, 22 | -------------------------------------------------------------------------------- /debian/impish/system76-nccl-11.2/install: -------------------------------------------------------------------------------- 1 | usr/lib/cuda-11.2/ 2 | -------------------------------------------------------------------------------- /debian/impish/system76-nccl-11.2/rules: -------------------------------------------------------------------------------- 1 | #!/usr/bin/make -f 2 | 3 | CUDA_SDK=usr/lib/cuda-11.2/ 4 | export CC=/usr/bin/gcc-9 5 | export CXX=/usr/bin/g++-9 6 | 7 | %: 8 | dh $@ 9 | 10 | override_dh_auto_build: 11 | make -j src.build CUDA_HOME=/$(CUDA_SDK) 12 | 13 | override_dh_auto_install: 14 | mkdir -p $(CUDA_SDK)/lib64 $(CUDA_SDK)/include 15 | mv build/lib/* $(CUDA_SDK)/lib64 16 | mv build/include/* $(CUDA_SDK)/include/ 17 | 18 | override_dh_strip: 19 | 20 | override_dh_shlibdeps: 21 | -------------------------------------------------------------------------------- /keys/system76-pop.asc: -------------------------------------------------------------------------------- 1 | -----BEGIN PGP PUBLIC KEY BLOCK----- 2 | 3 | mQINBFlIFeIBEAC4gT9OkQ2QYWw/FTsqWLuXGz63P5YrYvdYYulC9ZSRKcMqLIIh 4 | F/BuBCVQ5EYDUW/XKZ7/vn3aTUxY0cWHtjyGk11X0UayWQ0xT5qSkG/UnhdHMrtF 5 | 59zTkcecqDFKCX3TGRCkY7bkkd4c6HeZt2TcOzibHRpZNOCD23HvyBJ3aFNcGKUv 6 | qcpCibiydUI1TTpzFLMxkMxpJOC1D3kLbF/u/DZslZ5i9EddUd70KzxUKVMzgdNs 7 | 4/hBNcL1nyOGDXO7o1+3avTd7AqR+wmgk0CRNyBvi7ugFPsDbhtcrE8OozEDryXE 8 | YkV6Whv2bLtYaGJYEv+MX+q/swFpYYujK5aW+r+pmXwkcrC0JyNdqmFDuJXkzS6d 9 | m44z/qGcjRPzxKj8ppx8okpVE5tU08FjHBGTe3ek0pD5OSQDyLtk2eYUyb8mC3rJ 10 | ySFVXfN1s/KQ5/VXGg7AoH3x5YOVh9HhRz5Dy7tpkL2POMYoWxC6CKTSiuEV+fcG 11 | GHX4F0qVLQyisG2lOdO1zBfEzTunWbDq9mGwhtjbz/IsmWhdicPqSlu7iPY9hDLn 12 | 6eb0cNosh0li2dROsaEeK37pYCsCoKJnzwnvm/589P8HhrMq7oso+QH8TuJGQzvn 13 | Tvp0neCSiAhbdAvgeKVJsCjCeyrLDHTzdmgxI3ssj/lt0d2TUNOTCLmQNQARAQAB 14 | tBpMYXVuY2hwYWQgUFBBIGZvciBTeXN0ZW03NokCOAQTAQIAIgUCWUgV4gIbAwYL 15 | CQgHAwIGFQgCCQoLBBYCAwECHgECF4AACgkQHl+LvFvrEK453w//awggX43Drb/J 16 | sIzW3Ys5v8C2LCPKk0c7O/zv54douUmHckXMtNYsVjZ7c4OaXQGrFkh8nx9KVO9p 17 | vT5UDN2ntrJ2aMkk6gh8ydBqws/ccBG2JNtSoZUe6cjj9ZxzTg7Q8IY1QceuZyo+ 18 | /tYJ7ki8IY+Acz6WHC9wlr1bLxzKz0eO/goUrPzChh0FpazFtaXMQQRX5h/7UonE 19 | qM6DrwZyx3P3piQXNFFEtsU77VnTVmxsQKPFlyPFyeX5dHLg4CFzNNOrT/jkLKRh 20 | HmofaoRaVkV143ZDubA7xDDNiUpgOo2x0iNam1sH+CLlA1AfTAWIW+GGZjms1bVT 21 | TR/ZM8uNE5wEGlcA6vqAoRM5ZdB7OZrU/hQ0S/SVHjOwSzmClj7XIZNzq88GjVCd 22 | mV/k4XFMGvgG3/V5BPBRse9EjvMdDG/IHTLGiU+8hdYeT3FBzXSz4MIWxgAcUyHT 23 | oE4gxRGN7nRLaC/UhGjextkNYj1UBZvWaG61i0o2eLk280uG4rvmicvaPZHZUffi 24 | ihIZJUv1dQtf8aruEeMf8u2u8PDYn8R2URBLYX7PjqeBfThU7osJFyQtVKVTVCtU 25 | 543RnudoudPiAd/FdILtriOoW6PsF+aQ4If4bTnxK17YE3oEKr9BCTDCgKpZAt1M 26 | Q2byrEiug61eOZwjW1jyTOaIle0ED5A= 27 | =LIbw 28 | -----END PGP PUBLIC KEY BLOCK----- 29 | -------------------------------------------------------------------------------- /metapackages/focal/system76-cuda-latest.cfg: -------------------------------------------------------------------------------- 1 | Section: metapackages 2 | Priority: optional 3 | Homepage: https://developer.nvidia.com/cuda-downloads 4 | Standards-Version: 3.9.2 5 | Package: system76-cuda-latest 6 | Version: 11.2~20.04 7 | Maintainer: Michael Aaron Murphy 8 | Depends: system76-cuda-11.2 9 | Description: Metapackage for the latest version of the CUDA Toolkit 10 | -------------------------------------------------------------------------------- /metapackages/focal/system76-cudnn-latest.cfg: -------------------------------------------------------------------------------- 1 | Section: metapackages 2 | Priority: optional 3 | Homepage: https://developer.nvidia.com/cudnn 4 | Standards-Version: 3.9.2 5 | Package: system76-cuda-latest 6 | Version: 11.1~20.04 7 | Maintainer: Michael Aaron Murphy 8 | Depends: system76-cudnn-11.2 9 | Description: Metapackage for the latest version of the cuDNN Library 10 | -------------------------------------------------------------------------------- /metapackages/groovy/system76-cuda-latest.cfg: -------------------------------------------------------------------------------- 1 | Section: metapackages 2 | Priority: optional 3 | Homepage: https://developer.nvidia.com/cuda-downloads 4 | Standards-Version: 3.9.2 5 | Package: system76-cuda-latest 6 | Version: 11.2~20.10 7 | Maintainer: Michael Aaron Murphy 8 | Depends: system76-cuda-11.2 9 | Description: Metapackage for the latest version of the CUDA Toolkit 10 | -------------------------------------------------------------------------------- /metapackages/groovy/system76-cudnn-latest.cfg: -------------------------------------------------------------------------------- 1 | Section: metapackages 2 | Priority: optional 3 | Homepage: https://developer.nvidia.com/cudnn 4 | Standards-Version: 3.9.2 5 | Package: system76-cuda-latest 6 | Version: 11.1~20.10 7 | Maintainer: Michael Aaron Murphy 8 | Depends: system76-cudnn-11.2 9 | Description: Metapackage for the latest version of the cuDNN Library 10 | -------------------------------------------------------------------------------- /metapackages/impish/system76-cuda-latest.cfg: -------------------------------------------------------------------------------- 1 | Section: metapackages 2 | Priority: optional 3 | Homepage: https://developer.nvidia.com/cuda-downloads 4 | Standards-Version: 3.9.2 5 | Package: system76-cuda-latest 6 | Version: 11.2~20.10 7 | Maintainer: Michael Aaron Murphy 8 | Depends: system76-cuda-11.2 9 | Description: Metapackage for the latest version of the CUDA Toolkit 10 | -------------------------------------------------------------------------------- /suites/focal.toml: -------------------------------------------------------------------------------- 1 | archive = "focal" 2 | version = "20.04" 3 | origin = "system76" 4 | label = "System76" 5 | email = "info@system76.com" 6 | 7 | extra_repos = [ "deb http://ppa.launchpad.net/system76/pop/ubuntu focal main" ] 8 | 9 | [[source]] 10 | name = "system76-cuda" 11 | build_on = "changelog" 12 | assets = [ 13 | { src = "nvidia_cuda/*", dst = "debian"} 14 | ] 15 | 16 | [[source]] 17 | name = "system76-cuda-10.1" 18 | build_on = "changelog" 19 | keep_source = false 20 | retain = 1 21 | assets = [ 22 | { src = "cuda_makefile_v2", dst = "Makefile" }, 23 | ] 24 | 25 | [[source]] 26 | name = "system76-cudnn-10.1" 27 | build_on = "changelog" 28 | assets = [ 29 | { src = "nvidia_cuda/*", dst = "debian"} 30 | ] 31 | retain = 1 32 | keep_source = false 33 | 34 | [[source]] 35 | name = "system76-nccl-10.1" 36 | build_on = "changelog" 37 | depends = [ 38 | "system76-cuda", 39 | "system76-cuda-10.1", 40 | ] 41 | 42 | [source.location] 43 | url = "https://github.com/NVIDIA/nccl/archive/v2.7.8-1.tar.gz" 44 | checksum = "fa2bec307270f30fcf6280a85f24ea8801e0ce3b3027937c7325260a890b07e0" 45 | 46 | [[source]] 47 | name = "system76-cuda-10.2" 48 | build_on = "changelog" 49 | keep_source = false 50 | retain = 1 51 | assets = [ 52 | { src = "cuda_makefile_v2", dst = "Makefile" }, 53 | ] 54 | 55 | [[source]] 56 | name = "system76-cudnn-10.2" 57 | build_on = "changelog" 58 | assets = [ 59 | { src = "nvidia_cuda/*", dst = "debian"} 60 | ] 61 | retain = 1 62 | keep_source = false 63 | 64 | [[source]] 65 | name = "system76-nccl-10.2" 66 | build_on = "changelog" 67 | depends = [ 68 | "system76-cuda", 69 | "system76-cuda-10.2", 70 | ] 71 | 72 | [source.location] 73 | url = "https://github.com/NVIDIA/nccl/archive/v2.7.8-1.tar.gz" 74 | checksum = "fa2bec307270f30fcf6280a85f24ea8801e0ce3b3027937c7325260a890b07e0" 75 | 76 | [[source]] 77 | name = "system76-cuda-11.1" 78 | build_on = "changelog" 79 | keep_source = false 80 | retain = 1 81 | assets = [ 82 | { src = "cuda_makefile_v3", dst = "Makefile" }, 83 | ] 84 | 85 | [[source]] 86 | name = "system76-cudnn-11.1" 87 | build_on = "changelog" 88 | assets = [ 89 | { src = "nvidia_cuda/*", dst = "debian"} 90 | ] 91 | retain = 1 92 | keep_source = false 93 | 94 | [[source]] 95 | name = "system76-cudnn-11.2" 96 | build_on = "changelog" 97 | assets = [ 98 | { src = "nvidia_cuda/*", dst = "debian"} 99 | ] 100 | retain = 1 101 | keep_source = false 102 | 103 | [[source]] 104 | name = "system76-nccl-11.1" 105 | build_on = "changelog" 106 | depends = [ 107 | "system76-cuda", 108 | "system76-cuda-11.1", 109 | ] 110 | 111 | [source.location] 112 | url = "https://github.com/NVIDIA/nccl/archive/v2.8.3-1.tar.gz" 113 | checksum = "3ae89ddb2956fff081e406a94ff54ae5e52359f5d645ce977c7eba09b3b782e6" 114 | 115 | [[source]] 116 | name = "system76-cuda-11.2" 117 | build_on = "changelog" 118 | keep_source = false 119 | retain = 1 120 | assets = [ 121 | { src = "cuda_makefile_v3", dst = "Makefile" }, 122 | ] 123 | 124 | [[source]] 125 | name = "system76-nccl-11.2" 126 | build_on = "changelog" 127 | depends = [ 128 | "system76-cuda", 129 | "system76-cuda-11.2", 130 | ] 131 | 132 | [source.location] 133 | url = "https://github.com/NVIDIA/nccl/archive/v2.8.3-1.tar.gz" 134 | checksum = "3ae89ddb2956fff081e406a94ff54ae5e52359f5d645ce977c7eba09b3b782e6" -------------------------------------------------------------------------------- /suites/groovy.toml: -------------------------------------------------------------------------------- 1 | archive = "groovy" 2 | version = "20.10" 3 | origin = "system76" 4 | label = "System76" 5 | email = "info@system76.com" 6 | 7 | [[source]] 8 | name = "system76-cuda" 9 | build_on = "changelog" 10 | assets = [ 11 | { src = "nvidia_cuda/*", dst = "debian"} 12 | ] 13 | 14 | [[source]] 15 | name = "system76-cuda-10.1" 16 | build_on = "changelog" 17 | keep_source = false 18 | retain = 1 19 | assets = [ 20 | { src = "cuda_makefile_v2", dst = "Makefile" }, 21 | ] 22 | 23 | [[source]] 24 | name = "system76-cudnn-10.1" 25 | build_on = "changelog" 26 | assets = [ 27 | { src = "nvidia_cuda/*", dst = "debian"} 28 | ] 29 | retain = 1 30 | keep_source = false 31 | 32 | [[source]] 33 | name = "system76-nccl-10.1" 34 | build_on = "changelog" 35 | depends = [ 36 | "system76-cuda", 37 | "system76-cuda-10.1", 38 | ] 39 | 40 | [source.location] 41 | url = "https://github.com/NVIDIA/nccl/archive/v2.7.8-1.tar.gz" 42 | checksum = "fa2bec307270f30fcf6280a85f24ea8801e0ce3b3027937c7325260a890b07e0" 43 | 44 | [[source]] 45 | name = "system76-cuda-10.2" 46 | build_on = "changelog" 47 | keep_source = false 48 | retain = 1 49 | assets = [ 50 | { src = "cuda_makefile_v2", dst = "Makefile" }, 51 | { src = "nvidia_cuda/*", dst = "debian"} 52 | ] 53 | 54 | [[source]] 55 | name = "system76-cudnn-10.2" 56 | build_on = "changelog" 57 | assets = [ 58 | { src = "nvidia_cuda/*", dst = "debian"} 59 | ] 60 | retain = 1 61 | keep_source = false 62 | 63 | [[source]] 64 | name = "system76-nccl-10.2" 65 | build_on = "changelog" 66 | depends = [ 67 | "system76-cuda", 68 | "system76-cuda-10.2", 69 | ] 70 | 71 | [source.location] 72 | url = "https://github.com/NVIDIA/nccl/archive/v2.7.8-1.tar.gz" 73 | checksum = "fa2bec307270f30fcf6280a85f24ea8801e0ce3b3027937c7325260a890b07e0" 74 | 75 | [[source]] 76 | name = "system76-cuda-11.1" 77 | build_on = "changelog" 78 | keep_source = false 79 | retain = 1 80 | assets = [ 81 | { src = "cuda_makefile_v3", dst = "Makefile" }, 82 | ] 83 | 84 | [[source]] 85 | name = "system76-cudnn-11.1" 86 | build_on = "changelog" 87 | assets = [ 88 | { src = "nvidia_cuda/*", dst = "debian"} 89 | ] 90 | retain = 1 91 | keep_source = false 92 | 93 | [[source]] 94 | name = "system76-cudnn-11.2" 95 | build_on = "changelog" 96 | assets = [ 97 | { src = "nvidia_cuda/*", dst = "debian"} 98 | ] 99 | retain = 1 100 | keep_source = false 101 | 102 | [[source]] 103 | name = "system76-nccl-11.1" 104 | build_on = "changelog" 105 | depends = [ 106 | "system76-cuda", 107 | "system76-cuda-11.1", 108 | ] 109 | 110 | [source.location] 111 | url = "https://github.com/NVIDIA/nccl/archive/v2.8.3-1.tar.gz" 112 | checksum = "3ae89ddb2956fff081e406a94ff54ae5e52359f5d645ce977c7eba09b3b782e6" 113 | 114 | 115 | [[source]] 116 | name = "system76-cuda-11.2" 117 | build_on = "changelog" 118 | keep_source = false 119 | retain = 1 120 | assets = [ 121 | { src = "cuda_makefile_v3", dst = "Makefile" }, 122 | ] 123 | 124 | 125 | [[source]] 126 | name = "system76-nccl-11.2" 127 | build_on = "changelog" 128 | depends = [ 129 | "system76-cuda", 130 | "system76-cuda-11.2", 131 | ] 132 | 133 | [source.location] 134 | url = "https://github.com/NVIDIA/nccl/archive/v2.8.3-1.tar.gz" 135 | checksum = "3ae89ddb2956fff081e406a94ff54ae5e52359f5d645ce977c7eba09b3b782e6" 136 | -------------------------------------------------------------------------------- /suites/impish.toml: -------------------------------------------------------------------------------- 1 | archive = "impish" 2 | version = "21.10" 3 | origin = "system76" 4 | label = "System76" 5 | email = "info@system76.com" 6 | 7 | [[source]] 8 | name = "system76-cuda" 9 | build_on = "changelog" 10 | assets = [ 11 | { src = "nvidia_cuda/*", dst = "debian"} 12 | ] 13 | 14 | [[source]] 15 | name = "system76-cuda-11.1" 16 | build_on = "changelog" 17 | keep_source = false 18 | retain = 1 19 | assets = [ 20 | { src = "cuda_makefile_v3", dst = "Makefile" }, 21 | ] 22 | 23 | [[source]] 24 | name = "system76-cudnn-11.1" 25 | build_on = "changelog" 26 | assets = [ 27 | { src = "nvidia_cuda/*", dst = "debian"} 28 | ] 29 | retain = 1 30 | keep_source = false 31 | 32 | [[source]] 33 | name = "system76-cudnn-11.2" 34 | build_on = "changelog" 35 | assets = [ 36 | { src = "nvidia_cuda/*", dst = "debian"} 37 | ] 38 | retain = 1 39 | keep_source = false 40 | 41 | [[source]] 42 | name = "system76-nccl-11.1" 43 | build_on = "changelog" 44 | depends = [ 45 | "system76-cuda", 46 | "system76-cuda-11.1", 47 | ] 48 | 49 | [source.location] 50 | url = "https://github.com/NVIDIA/nccl/archive/v2.8.3-1.tar.gz" 51 | checksum = "3ae89ddb2956fff081e406a94ff54ae5e52359f5d645ce977c7eba09b3b782e6" 52 | 53 | 54 | [[source]] 55 | name = "system76-cuda-11.2" 56 | build_on = "changelog" 57 | keep_source = false 58 | retain = 1 59 | assets = [ 60 | { src = "cuda_makefile_v3", dst = "Makefile" }, 61 | ] 62 | 63 | 64 | [[source]] 65 | name = "system76-nccl-11.2" 66 | build_on = "changelog" 67 | depends = [ 68 | "system76-cuda", 69 | "system76-cuda-11.2", 70 | ] 71 | 72 | [source.location] 73 | url = "https://github.com/NVIDIA/nccl/archive/v2.8.3-1.tar.gz" 74 | checksum = "3ae89ddb2956fff081e406a94ff54ae5e52359f5d645ce977c7eba09b3b782e6" 75 | --------------------------------------------------------------------------------