diff --git a/debian_pkg_dirs b/debian_pkg_dirs index 18dcce09..6e9e109d 100644 --- a/debian_pkg_dirs +++ b/debian_pkg_dirs @@ -3,6 +3,9 @@ ceph/python-cephclient tools/debian-integration tools/collector tools/engtools/hostdata-collectors +tools/opae/opae-sdk +tools/opae/python3-opae.admin +tools/opae/python3-opae.pacsign tools/pcm utilities/build-info utilities/k8s-coredump diff --git a/tools/base-images/stx-debian-dev/debian/docker/Dockerfile b/tools/base-images/stx-debian-dev/debian/docker/Dockerfile index 027ecd1d..b4c42321 100644 --- a/tools/base-images/stx-debian-dev/debian/docker/Dockerfile +++ b/tools/base-images/stx-debian-dev/debian/docker/Dockerfile @@ -33,21 +33,20 @@ RUN set -ex && \ cp -f /etc/apt/sources.list.d/stx.list.disabled /etc/apt/sources.list.d/stx.list && \ apt-get update -y && \ apt-get install -y \ + autoconf-archive \ + autogen \ + cmake \ + doxygen \ + dwarves \ git \ git-review \ - unzip \ - autogen \ - autoconf-archive \ - linux-perf-5.10 \ libcap-dev \ - uuid-dev \ - ncurses-dev \ - dwarves \ - cmake \ - libhwloc-dev \ libjson-c-dev \ - doxygen \ + linux-perf-5.10 \ + ncurses-dev \ sphinx-doc \ + unzip \ + uuid-dev \ && \ rm -f /etc/apt/sources.list.d/debian.list && \ rm -f /etc/apt/sources.list.d/stx.list && \ @@ -64,29 +63,30 @@ RUN set -ex && \ apt-get update -y && \ apt-get upgrade -y && \ apt-get install -y \ - sudo \ - bash \ - python3-yaml \ - curl \ - wget \ - make \ automake \ + bash \ bc \ bison \ - isomd5sum \ - gettext \ - mkisofs \ - gcc \ - g++ \ - rsync \ - vim \ - linux-headers-5.10.0-6 \ + curl \ fakeroot \ flex \ + gcc \ + g++ \ + gettext \ + isomd5sum \ libelf-dev \ + libhwloc-dev=1.11.12-3 \ libssl-dev \ - xz-utils \ + linux-headers-5.10.0-6 \ + make \ + mkisofs \ + python3-yaml \ + rsync \ sphinx-common \ + sudo \ + vim \ + wget \ + xz-utils \ && \ apt-get clean && \ rm -rf /var/lib/apt/lists/* diff --git a/tools/base-images/stx-debian-dev/debian/docker/stx-dev.list b/tools/base-images/stx-debian-dev/debian/docker/stx-dev.list index 6acea0c2..7b757769 100644 --- a/tools/base-images/stx-debian-dev/debian/docker/stx-dev.list +++ b/tools/base-images/stx-debian-dev/debian/docker/stx-dev.list @@ -1,3 +1,2 @@ deb [trusted=yes check-valid-until=0] http://mirror.starlingx.cengn.ca/mirror/starlingx/master/debian/monolithic/latest_build/inputs/packages ./ deb [trusted=yes check-valid-until=0] http://mirror.starlingx.cengn.ca/mirror/starlingx/master/debian/monolithic/latest_build/outputs/std/packages ./ -deb [trusted=yes check-valid-until=0] http://mirror.starlingx.cengn.ca/mirror/starlingx/master/debian/monolithic/latest_build/outputs/rt/packages ./ diff --git a/tools/opae/opae-sdk/debian/deb_folder/changelog b/tools/opae/opae-sdk/debian/deb_folder/changelog new file mode 100644 index 00000000..0c0696cd --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/changelog @@ -0,0 +1,5 @@ +opae-sdk (1.3.7-5) unstable; urgency=medium + + * Initial release. + + -- Rogerio Ferraz Tue, 25 Oct 2022 20:43:00 +0000 diff --git a/tools/opae/opae-sdk/debian/deb_folder/compat b/tools/opae/opae-sdk/debian/deb_folder/compat new file mode 100644 index 00000000..f599e28b --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/compat @@ -0,0 +1 @@ +10 diff --git a/tools/opae/opae-sdk/debian/deb_folder/control b/tools/opae/opae-sdk/debian/deb_folder/control new file mode 100644 index 00000000..d05b39f3 --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/control @@ -0,0 +1,59 @@ +Source: opae-sdk +Section: devel +Priority: optional +Standards-Version: 4.5.1 +Maintainer: StarlingX Developers +Homepage: https://www.starlingx.io +Build-Depends: + cmake, + debhelper (>= 13), + doxygen, + gcc, + g++, + libc6-dev, + libhwloc-dev (<< 2), + libjson-c-dev, + make, + pandoc, + pkg-config, + python3-dev, + uuid-dev + +Package: opae-libs +Architecture: amd64 +Description: OPAE runtime +Depends: + libhwloc5 (<< 2), + libjson-c5, + uuid-dev, + ${shlibs:Depends}, + ${misc:Depends} + +Package: opae-devel +Architecture: amd64 +Description: OPAE documentation and sample source code +Depends: + opae-libs (= ${binary:Version}), + ${misc:Depends}, + ${python3:Depends}, + ${shlibs:Depends} + +Package: opae-tools +Architecture: amd64 +Description: OPAE base tool binaries +Depends: + opae-devel (= ${binary:Version}), + opae-libs (= ${binary:Version}), + ${shlibs:Depends}, + ${misc:Depends} + +Package: opae-tools-extra +Architecture: amd64 +Description: OPAE extra tool binaries +Depends: + opae-devel (= ${binary:Version}), + opae-libs (= ${binary:Version}), + opae-tools (= ${binary:Version}), + ${misc:Depends}, + ${python3:Depends}, + ${shlibs:Depends} diff --git a/tools/opae/opae-sdk/debian/deb_folder/copyright b/tools/opae/opae-sdk/debian/deb_folder/copyright new file mode 100644 index 00000000..141e1875 --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/copyright @@ -0,0 +1,30 @@ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: opae +Source: https://github.com/OPAE/opae-sdk + +Files: * +Copyright: 2019-2022, Intel Corporation +License: BSD-3-clause + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions are met: + + * Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. + * Neither the name of Intel Corporation nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" + AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE + LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + POSSIBILITY OF SUCH DAMAGE. diff --git a/tools/opae/opae-sdk/debian/deb_folder/opae-devel.install b/tools/opae/opae-sdk/debian/deb_folder/opae-devel.install new file mode 100644 index 00000000..e57bfca4 --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/opae-devel.install @@ -0,0 +1,10 @@ +usr/bin/afu_platform_config usr/sbin +usr/bin/afu_platform_info usr/sbin +usr/bin/afu_synth_setup usr/sbin +usr/bin/rtl_src_config usr/sbin +usr/include/opae/* +usr/include/safe_string/* +usr/lib/libsafestr.a +usr/share/opae/* +usr/src/opae/* +LICENSE usr/share/doc/opae-devel diff --git a/tools/opae/opae-sdk/debian/deb_folder/opae-libs.install b/tools/opae/opae-sdk/debian/deb_folder/opae-libs.install new file mode 100644 index 00000000..155751fc --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/opae-libs.install @@ -0,0 +1,7 @@ +usr/lib/libbitstream.so* +usr/lib/libbmc.so* +usr/lib/libmodbmc.so* +usr/lib/libopae-c.so* +usr/lib/libopae-cxx-core.so* +usr/lib/libxfpga.so* +LICENSE usr/share/doc/opae-libs diff --git a/tools/opae/opae-sdk/debian/deb_folder/opae-tools-extra.install b/tools/opae/opae-sdk/debian/deb_folder/opae-tools-extra.install new file mode 100644 index 00000000..50beb9ae --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/opae-tools-extra.install @@ -0,0 +1,31 @@ +usr/bin/bmc_test usr/sbin +usr/bin/bist usr/sbin +usr/bin/bist_app usr/sbin +usr/bin/bist_app.py usr/sbin +usr/bin/bist_common.py usr/sbin +usr/bin/bist_def.py usr/sbin +usr/bin/bist_dma.py usr/sbin +usr/bin/bist_nlb0.py usr/sbin +usr/bin/bist_nlb3.py usr/sbin +usr/bin/coreidle usr/sbin +usr/bin/fecmode usr/sbin +usr/bin/fpga_dma_test usr/sbin +usr/bin/fpgabist usr/sbin +usr/bin/fpgadiag usr/sbin +usr/bin/fpgalpbk usr/sbin +usr/bin/fpgamac usr/sbin +usr/bin/fpgametrics usr/sbin +usr/bin/fpgastats usr/sbin +usr/bin/fvlbypass usr/sbin +usr/bin/hssi_config usr/sbin +usr/bin/hssi_loopback usr/sbin +usr/bin/mactest usr/sbin +usr/bin/mmlink usr/sbin +usr/bin/nlb0 usr/sbin +usr/bin/nlb3 usr/sbin +usr/bin/nlb7 usr/sbin +usr/bin/userclk usr/sbin +usr/lib/libhssi-io.so* +usr/lib/libopae-c++-nlb.so* +usr/lib/libopae-c++-utils.so* +LICENSE usr/share/doc/opae-tools-extra diff --git a/tools/opae/opae-sdk/debian/deb_folder/opae-tools.install b/tools/opae/opae-sdk/debian/deb_folder/opae-tools.install new file mode 100644 index 00000000..c6f8a6b6 --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/opae-tools.install @@ -0,0 +1,10 @@ +etc/opae/fpgad.cfg +etc/sysconfig/fpgad.conf +usr/bin/fpgaconf usr/sbin +usr/bin/fpgad usr/sbin +usr/bin/fpgainfo usr/sbin +usr/lib/libfpgad-api.so* +usr/lib/libfpgad-vc.so* +usr/lib/libfpgad-xfpga.so* +usr/lib/systemd/system/fpgad.service etc/systemd/system +LICENSE usr/share/doc/opae-tools diff --git a/tools/opae/opae-sdk/debian/deb_folder/postinst b/tools/opae/opae-sdk/debian/deb_folder/postinst new file mode 100755 index 00000000..a98a3a38 --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/postinst @@ -0,0 +1,9 @@ +#!/bin/sh + +set -e + +mkdir -p /etc/ld.so.conf.d +echo "/usr/lib" > /etc/ld.so.conf.d/opae-c.conf +ldconfig + +#DEBHELPER# diff --git a/tools/opae/opae-sdk/debian/deb_folder/prerm b/tools/opae/opae-sdk/debian/deb_folder/prerm new file mode 100755 index 00000000..6213a82f --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/prerm @@ -0,0 +1,8 @@ +#!/bin/sh + +set -e + +rm -f -- /etc/ld.so.conf.d/opae-c.conf +ldconfig + +#DEBHELPER# diff --git a/tools/opae/opae-sdk/debian/deb_folder/rules b/tools/opae/opae-sdk/debian/deb_folder/rules new file mode 100755 index 00000000..6d3121d2 --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/rules @@ -0,0 +1,27 @@ +#!/usr/bin/make -f +# See debhelper(7) (uncomment to enable) +# output every command that modifies files on the build system. +#export DH_VERBOSE = 1 + + +# see FEATURE AREAS in dpkg-buildflags(1) +#export DEB_BUILD_MAINT_OPTIONS = hardening=+all + +# see ENVIRONMENT in dpkg-buildflags(1) +# package maintainers to append CFLAGS +#export DEB_CFLAGS_MAINT_APPEND = -Wall -pedantic +# package maintainers to append LDFLAGS +#export DEB_LDFLAGS_MAINT_APPEND = -Wl,--as-needed + + +%: + dh $@ + + +# dh_make generated override targets +# This is example for Cmake (See https://bugs.debian.org/641051 ) +#override_dh_auto_configure: +# dh_auto_configure -- # -DCMAKE_LIBRARY_PATH=$(DEB_HOST_MULTIARCH) + +override_dh_auto_configure: + dh_auto_configure -- -DCMAKE_INSTALL_PREFIX=/usr -DBUILD_ASE=ON diff --git a/tools/opae/opae-sdk/debian/deb_folder/source/format b/tools/opae/opae-sdk/debian/deb_folder/source/format new file mode 100644 index 00000000..163aaf8d --- /dev/null +++ b/tools/opae/opae-sdk/debian/deb_folder/source/format @@ -0,0 +1 @@ +3.0 (quilt) diff --git a/tools/opae/opae-sdk/debian/dl_hook b/tools/opae/opae-sdk/debian/dl_hook new file mode 100755 index 00000000..abb29832 --- /dev/null +++ b/tools/opae/opae-sdk/debian/dl_hook @@ -0,0 +1,36 @@ +#!/bin/bash +set -x + +# $1: Name of directory where the source code is extracted to. +# It corresponds to the build name taken from changelog.OPAE_ZIP + +PKG_BUILD_NAME=$1 +PKG_BUILD_DIR=$(realpath `pwd`/"${PKG_BUILD_NAME}") + +OPAE_SDK_VERSION=1.3.7-5 +OPAE_SDK_SOURCE=opae-"${OPAE_SDK_VERSION}".tar.gz + +# The OPAE zip file includes opae-sdk, opae.admin and opae.pac_sign source code +OPAE_ZIP=OPAE_1.3.7-5_el7.zip + +unzip ./"${OPAE_ZIP}" +if [ $? -ne 0 ] +then + echo "Failed unzip of source code: ${OPAE_ZIP}" + exit 1 +fi + +mv OPAE/source_code/"${OPAE_SDK_SOURCE}" ./ +mkdir -p "${PKG_BUILD_DIR}" + +# Unpack source code +tar xzf $(basename "${OPAE_SDK_SOURCE}") -C "${PKG_BUILD_DIR}" --strip-components 2 + +# Patches +sed -i 's|libjson0|libjson-c5|' "${PKG_BUILD_DIR}"/CMakeLists.txt +sed -i 's| -Werror||' "${PKG_BUILD_DIR}"/cmake/modules/compiler_config.cmake +sed -i 's|libjson0-dev|libjson-c-dev|' "${PKG_BUILD_DIR}"/cmake/modules/dependency_notifier.cmake + +# Clean-up +rm -rf *.tar.gz +rm -rf "${OPAE_ZIP}" OPAE diff --git a/tools/opae/opae-sdk/debian/meta_data.yaml b/tools/opae/opae-sdk/debian/meta_data.yaml new file mode 100644 index 00000000..df25c131 --- /dev/null +++ b/tools/opae/opae-sdk/debian/meta_data.yaml @@ -0,0 +1,15 @@ +--- +debname: opae-sdk +debver: 1.3.7-5 +dl_hook: dl_hook +dl_files: + OPAE_1.3.7-5_el7.zip: + topdir: null + url: + "https://github.com/OPAE/opae-sdk/releases/download/1.3.7-5/\ + OPAE_1.3.7-5_el7.zip" + md5sum: 389888f2bb3e8cfb002a1ba880fc6823 + sha256sum: 7b1a21ccce0727bd6b5ceea37209c14fcf15cec3c33bb094057c354ffc869e1b +revision: + dist: $STX_DIST + PKG_GITREVCOUNT: true diff --git a/tools/opae/python3-opae.admin/debian/deb_folder/changelog b/tools/opae/python3-opae.admin/debian/deb_folder/changelog new file mode 100644 index 00000000..a8ed86e7 --- /dev/null +++ b/tools/opae/python3-opae.admin/debian/deb_folder/changelog @@ -0,0 +1,5 @@ +python3-opae.admin (1.0.3) unstable; urgency=medium + + * Initial release. + + -- Rogerio Ferraz Tue, 25 Oct 2022 20:43:00 +0000 diff --git a/tools/opae/python3-opae.admin/debian/deb_folder/compat b/tools/opae/python3-opae.admin/debian/deb_folder/compat new file mode 100644 index 00000000..f599e28b --- /dev/null +++ b/tools/opae/python3-opae.admin/debian/deb_folder/compat @@ -0,0 +1 @@ +10 diff --git a/tools/opae/python3-opae.admin/debian/deb_folder/control b/tools/opae/python3-opae.admin/debian/deb_folder/control new file mode 100644 index 00000000..2849d9cb --- /dev/null +++ b/tools/opae/python3-opae.admin/debian/deb_folder/control @@ -0,0 +1,23 @@ +Source: python3-opae.admin +Section: python +Priority: optional +Standards-Version: 4.5.1 +Maintainer: StarlingX Developers +Homepage: https://www.starlingx.io +Build-Depends: + debhelper (>= 13), + dh-python, + python3, + python3-all, + python3-setuptools + +Package: python3-opae.admin +Architecture: all +Description: Provides administration capability for Intel FPGA PAC devices. +Depends: + opae-devel (<< 2), + opae-libs (<< 2), + sysvinit-utils, + pciutils, + ${misc:Depends}, + ${python3:Depends} diff --git a/tools/opae/python3-opae.admin/debian/deb_folder/copyright b/tools/opae/python3-opae.admin/debian/deb_folder/copyright new file mode 100644 index 00000000..79d0d17e --- /dev/null +++ b/tools/opae/python3-opae.admin/debian/deb_folder/copyright @@ -0,0 +1,25 @@ +Copyright(c) 2019-2020, Intel Corporation + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. +* Neither the name of Intel Corporation nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. diff --git a/tools/opae/python3-opae.admin/debian/deb_folder/rules b/tools/opae/python3-opae.admin/debian/deb_folder/rules new file mode 100755 index 00000000..10e0ff04 --- /dev/null +++ b/tools/opae/python3-opae.admin/debian/deb_folder/rules @@ -0,0 +1,17 @@ +#!/usr/bin/make -f + +export DH_VERBOSE=1 +export PYBUILD_NAME=python3-opae.admin + +DEBPATH=$(CURDIR)/debian/python3-opae.admin + +%: + dh $@ --with python3 --buildsystem=pybuild + +override_dh_auto_test: + # do not run tests + +override_dh_install: + python3 setup.py install -f --install-layout=deb --root=${PATH_TO} + mv ${DEBPATH}/usr/bin ${DEBPATH}/usr/sbin + dh_install diff --git a/tools/opae/python3-opae.admin/debian/deb_folder/source/format b/tools/opae/python3-opae.admin/debian/deb_folder/source/format new file mode 100644 index 00000000..89ae9db8 --- /dev/null +++ b/tools/opae/python3-opae.admin/debian/deb_folder/source/format @@ -0,0 +1 @@ +3.0 (native) diff --git a/tools/opae/python3-opae.admin/debian/dl_hook b/tools/opae/python3-opae.admin/debian/dl_hook new file mode 100755 index 00000000..e0b3ae6d --- /dev/null +++ b/tools/opae/python3-opae.admin/debian/dl_hook @@ -0,0 +1,43 @@ +#!/bin/bash +set -x + +# $1: Name of directory where the source code is extracted to. +# It corresponds to the build name taken from changelog.OPAE_ZIP + +PKG_BUILD_NAME=$1 +PKG_BUILD_DIR=$(realpath `pwd`/"${PKG_BUILD_NAME}") + +OPAE_ADM_VERSION=1.0.3 +OPAE_ADM_RPM_VER="${OPAE_ADM_VERSION}"-2 + +OPAE_ADM_SOURCE=opae.admin-"${OPAE_ADM_VERSION}".tar.gz +OPAE_ADM_RPMBIN=opae.admin-"${OPAE_ADM_RPM_VER}".el7.noarch.rpm + +# The OPAE zip file includes opae-sdk, opae.admin and opae.pac_sign source code +OPAE_ZIP=OPAE_1.3.7-5_el7.zip + +unzip ./${OPAE_ZIP} +if [ $? -ne 0 ] +then + echo "Failed unzip of source code: ${OPAE_ZIP}" + exit 1 +fi + +mv OPAE/source_code/"${OPAE_ADM_SOURCE}" ./ +mv OPAE/installation_packages/"${OPAE_ADM_RPMBIN}" ./ +mkdir -p "${PKG_BUILD_DIR}" + +# Unpack source code +tar xzf $(basename "${OPAE_ADM_SOURCE}") -C "${PKG_BUILD_DIR}" --strip-components 1 +rpm2cpio ./"${OPAE_ADM_RPMBIN}" | cpio -i --to-stdout ./usr/share/doc/opae.admin/LICENSE > ./LICENSE +mv ./LICENSE "${PKG_BUILD_DIR}"/ + +# Patches +sed -i 's|/home/lab/sys_aalsdk/Security-Tools/python/opae.admin/LICENSE|LICENSE|' "${PKG_BUILD_DIR}"/setup.py +sed -i 's|/home/lab/sys_aalsdk/Security-Tools/python/opae.admin/LICENSE|LICENSE|' \ + "${PKG_BUILD_DIR}"/opae.admin.egg-info/SOURCES.txt + +# Clean-up +rm -rf *.tar.gz +rm -rf *.rpm +rm -rf "${OPAE_ZIP}" OPAE diff --git a/tools/opae/python3-opae.admin/debian/meta_data.yaml b/tools/opae/python3-opae.admin/debian/meta_data.yaml new file mode 100644 index 00000000..10144b96 --- /dev/null +++ b/tools/opae/python3-opae.admin/debian/meta_data.yaml @@ -0,0 +1,15 @@ +--- +debname: python3-opae.admin +debver: 1.0.3 +dl_hook: dl_hook +dl_files: + OPAE_1.3.7-5_el7.zip: + topdir: null + url: + "https://github.com/OPAE/opae-sdk/releases/download/1.3.7-5/\ + OPAE_1.3.7-5_el7.zip" + md5sum: 389888f2bb3e8cfb002a1ba880fc6823 + sha256sum: 7b1a21ccce0727bd6b5ceea37209c14fcf15cec3c33bb094057c354ffc869e1b +revision: + dist: $STX_DIST + PKG_GITREVCOUNT: true diff --git a/tools/opae/python3-opae.pacsign/debian/deb_folder/changelog b/tools/opae/python3-opae.pacsign/debian/deb_folder/changelog new file mode 100644 index 00000000..2ad89d8d --- /dev/null +++ b/tools/opae/python3-opae.pacsign/debian/deb_folder/changelog @@ -0,0 +1,5 @@ +python3-opae.pacsign (1.0.4) unstable; urgency=medium + + * Initial release. + + -- Rogerio Ferraz Tue, 25 Oct 2022 20:43:00 +0000 diff --git a/tools/opae/python3-opae.pacsign/debian/deb_folder/compat b/tools/opae/python3-opae.pacsign/debian/deb_folder/compat new file mode 100644 index 00000000..f599e28b --- /dev/null +++ b/tools/opae/python3-opae.pacsign/debian/deb_folder/compat @@ -0,0 +1 @@ +10 diff --git a/tools/opae/python3-opae.pacsign/debian/deb_folder/control b/tools/opae/python3-opae.pacsign/debian/deb_folder/control new file mode 100644 index 00000000..e1ea81d6 --- /dev/null +++ b/tools/opae/python3-opae.pacsign/debian/deb_folder/control @@ -0,0 +1,21 @@ +Source: python3-opae.pacsign +Section: python +Priority: optional +Standards-Version: 4.5.1 +Maintainer: StarlingX Developers +Homepage: https://www.starlingx.io +Build-Depends: + debhelper (>= 13), + dh-python, + python3, + python3-all, + python3-setuptools + +Package: python3-opae.pacsign +Architecture: any +Description: Signing utility for Intel FPGA PAC devices. +Depends: + opae-devel (<< 2), + opae-libs (<< 2), + ${misc:Depends}, + ${python3:Depends} diff --git a/tools/opae/python3-opae.pacsign/debian/deb_folder/copyright b/tools/opae/python3-opae.pacsign/debian/deb_folder/copyright new file mode 100644 index 00000000..f2c65e9d --- /dev/null +++ b/tools/opae/python3-opae.pacsign/debian/deb_folder/copyright @@ -0,0 +1,25 @@ +Copyright(c) 2019-2022, Intel Corporation + +Redistribution and use in source and binary forms, with or without +modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, + this list of conditions and the following disclaimer. +* Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. +* Neither the name of Intel Corporation nor the names of its contributors + may be used to endorse or promote products derived from this software + without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE +LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF +SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS +INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN +CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) +ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE +POSSIBILITY OF SUCH DAMAGE. diff --git a/tools/opae/python3-opae.pacsign/debian/deb_folder/rules b/tools/opae/python3-opae.pacsign/debian/deb_folder/rules new file mode 100755 index 00000000..a027b402 --- /dev/null +++ b/tools/opae/python3-opae.pacsign/debian/deb_folder/rules @@ -0,0 +1,10 @@ +#!/usr/bin/make -f + +export DH_VERBOSE=1 +export PYBUILD_NAME=python3-opae.pacsign + +%: + dh $@ --with python3 --buildsystem=pybuild + +override_dh_auto_test: + # do not run tests diff --git a/tools/opae/python3-opae.pacsign/debian/deb_folder/source/format b/tools/opae/python3-opae.pacsign/debian/deb_folder/source/format new file mode 100644 index 00000000..89ae9db8 --- /dev/null +++ b/tools/opae/python3-opae.pacsign/debian/deb_folder/source/format @@ -0,0 +1 @@ +3.0 (native) diff --git a/tools/opae/python3-opae.pacsign/debian/dl_hook b/tools/opae/python3-opae.pacsign/debian/dl_hook new file mode 100755 index 00000000..3b002775 --- /dev/null +++ b/tools/opae/python3-opae.pacsign/debian/dl_hook @@ -0,0 +1,31 @@ +#!/bin/bash +set -x + +# $1: Name of directory where the source code is extracted to. +# It corresponds to the build name taken from changelog.OPAE_ZIP + +PKG_BUILD_NAME=$1 +PKG_BUILD_DIR=$(realpath `pwd`/"${PKG_BUILD_NAME}") + +OPAE_PACSIGN_VERSION=1.0.4 +OPAE_PACSIGN_SOURCE=opae.pac_sign-"${OPAE_PACSIGN_VERSION}".tar.gz + +# The OPAE zip file includes opae-sdk, opae.admin and opae.pac_sign source code +OPAE_ZIP=OPAE_1.3.7-5_el7.zip + +unzip ./"${OPAE_ZIP}" +if [ $? -ne 0 ] +then + echo "Failed unzip of source code: ${OPAE_ZIP}" + exit 1 +fi + +mv OPAE/source_code/"${OPAE_PACSIGN_SOURCE}" ./ +mkdir -p "${PKG_BUILD_DIR}" + +# Unpack source code +tar xzf $(basename "${OPAE_PACSIGN_SOURCE}") -C "${PKG_BUILD_DIR}" --strip-components 1 + +# Clean-up +rm -rf *.tar.gz +rm -rf "${OPAE_ZIP}" OPAE diff --git a/tools/opae/python3-opae.pacsign/debian/meta_data.yaml b/tools/opae/python3-opae.pacsign/debian/meta_data.yaml new file mode 100644 index 00000000..eae91cd5 --- /dev/null +++ b/tools/opae/python3-opae.pacsign/debian/meta_data.yaml @@ -0,0 +1,15 @@ +--- +debname: python3-opae.pacsign +debver: 1.0.4 +dl_hook: dl_hook +dl_files: + OPAE_1.3.7-5_el7.zip: + topdir: null + url: + "https://github.com/OPAE/opae-sdk/releases/download/1.3.7-5/\ + OPAE_1.3.7-5_el7.zip" + md5sum: 389888f2bb3e8cfb002a1ba880fc6823 + sha256sum: 7b1a21ccce0727bd6b5ceea37209c14fcf15cec3c33bb094057c354ffc869e1b +revision: + dist: $STX_DIST + PKG_GITREVCOUNT: true diff --git a/tools/vran-tools/stx-debian-tools-dev/debian/docker/Dockerfile b/tools/vran-tools/stx-debian-tools-dev/debian/docker/Dockerfile index c8566623..f0786d44 100644 --- a/tools/vran-tools/stx-debian-tools-dev/debian/docker/Dockerfile +++ b/tools/vran-tools/stx-debian-tools-dev/debian/docker/Dockerfile @@ -33,23 +33,20 @@ RUN set -ex && \ cp -f /etc/apt/sources.list.d/stx.list.disabled /etc/apt/sources.list.d/stx.list && \ apt-get update -y && \ apt-get install -y \ + autoconf-archive \ + autogen \ + cmake \ + doxygen \ + dwarves \ git \ git-review \ - unzip \ - autogen \ - autoconf-archive \ - linux-perf-5.10 \ libcap-dev \ - uuid-dev \ - ncurses-dev \ - dwarves \ - cmake \ - libhwloc-dev \ libjson-c-dev \ - doxygen \ + linux-perf-5.10 \ + ncurses-dev \ sphinx-doc \ - acpica-tools \ - trace-cmd \ + unzip \ + uuid-dev \ && \ rm -f /etc/apt/sources.list.d/debian.list && \ rm -f /etc/apt/sources.list.d/stx.list && \ @@ -66,29 +63,36 @@ RUN set -ex && \ apt-get update -y && \ apt-get upgrade -y && \ apt-get install -y \ - sudo \ - bash \ - python3-yaml \ - curl \ - wget \ - make \ automake \ + bash \ bc \ bison \ - isomd5sum \ - gettext \ - mkisofs \ - gcc \ - g++ \ - rsync \ - vim \ - linux-headers-5.10.0-6 \ + curl \ fakeroot \ flex \ + gcc \ + g++ \ + gettext \ + isomd5sum \ libelf-dev \ + libhwloc-dev=1.11.12-3 \ libssl-dev \ - xz-utils \ + linux-headers-5.10.0-6 \ + make \ + mkisofs \ + pciutils \ + python-is-python3 \ + python3-intelhex \ + python3-pip \ + python3-pybind11 \ + python3-yaml \ + rsync \ sphinx-common \ + sudo \ + sysvinit-utils \ + vim \ + wget \ + xz-utils \ && \ apt-get clean && \ rm -rf /var/lib/apt/lists/* @@ -98,20 +102,17 @@ RUN set -ex && \ apt-get update -y && \ apt-get upgrade -y && \ apt-get install -y \ - net-tools \ - iproute2 \ - ethtool \ - tcpdump \ - linux-cpupower \ - pciutils \ - pcm \ - sysvinit-utils \ + acpica-tools \ dmidecode \ - python-is-python3 \ - python3-pip \ - && \ - python -m pip install \ - intelhex \ + ethtool \ + iproute2 \ + linux-cpupower \ + net-tools \ + opae-libs opae-tools opae-tools-extra opae-devel \ + pcm \ + python3-opae.admin python3-opae.pacsign \ + tcpdump \ + trace-cmd \ && \ apt-get clean && \ rm -rf /var/lib/apt/lists/* diff --git a/tools/vran-tools/stx-debian-tools-dev/debian/docker/stx-tools-dev.list b/tools/vran-tools/stx-debian-tools-dev/debian/docker/stx-tools-dev.list index 6acea0c2..7b757769 100644 --- a/tools/vran-tools/stx-debian-tools-dev/debian/docker/stx-tools-dev.list +++ b/tools/vran-tools/stx-debian-tools-dev/debian/docker/stx-tools-dev.list @@ -1,3 +1,2 @@ deb [trusted=yes check-valid-until=0] http://mirror.starlingx.cengn.ca/mirror/starlingx/master/debian/monolithic/latest_build/inputs/packages ./ deb [trusted=yes check-valid-until=0] http://mirror.starlingx.cengn.ca/mirror/starlingx/master/debian/monolithic/latest_build/outputs/std/packages ./ -deb [trusted=yes check-valid-until=0] http://mirror.starlingx.cengn.ca/mirror/starlingx/master/debian/monolithic/latest_build/outputs/rt/packages ./