From 936db1b345e31c8b5f5c88b4306f81ae2c3bdf7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ole-Andr=C3=A9=20Rodlie?= Date: Sun, 8 Oct 2023 00:31:44 +0200 Subject: [PATCH] Update builds scripts --- src/scripts/Dockerfile.vfxplatform | 15 ++++++--- src/scripts/build_vfxplatform_friction.sh | 2 +- src/scripts/build_vfxplatform_package_tar.sh | 6 ++-- src/scripts/vfxplatform.spec | 35 ++++++++++++++++++++ 4 files changed, 51 insertions(+), 7 deletions(-) create mode 100644 src/scripts/vfxplatform.spec diff --git a/src/scripts/Dockerfile.vfxplatform b/src/scripts/Dockerfile.vfxplatform index 80f197063..17e4d9f6e 100644 --- a/src/scripts/Dockerfile.vfxplatform +++ b/src/scripts/Dockerfile.vfxplatform @@ -1,13 +1,20 @@ -# VFX Reference Platform +# VFX Reference Platform for Friction FROM centos:centos7.9.2009 RUN yum -y update RUN yum -y install centos-release-scl RUN yum -y group install "Development Tools" RUN yum -y install pulseaudio-libs-devel wget git yasm python3 fontconfig-devel zlib-devel autoconf automake xz devtoolset-7 llvm-toolset-7.0 tree curl libICE-devel libSM-devel libX11-devel libXau-devel libXdamage-devel libXext-devel libXfixes-devel libXi-devel libXxf86vm-devel libdrm-devel libxcb-devel mesa-libGL-devel xorg-x11-proto-devel +RUN yum -y install epel-release +RUN yum -y install fakeroot dpkg dpkg-dev rpmdevtools RUN ln -sf /usr/bin/python3 /usr/bin/python +RUN rm -f /usr/lib64/pkgconfig/libpng.pc +RUN rm -f /usr/lib64/pkgconfig/libpng15.pc +RUN rm -f /usr/include/png.h +RUN rm -f /usr/include/pngconf.h +RUN rm -f /usr/include/pnglibconf.h RUN echo "source scl_source enable devtoolset-7" >> /root/.bashrc -# WIP -# COPY build_vfx.sh / -# CMD [ "bash", "./build_vfx.sh" ] +# COPY build_vfxplatform*.sh / +# COPY vfxplatform.spec / +# CMD [ "bash", "./build_vfxplatform.sh" ] diff --git a/src/scripts/build_vfxplatform_friction.sh b/src/scripts/build_vfxplatform_friction.sh index c2600df74..b52180cba 100644 --- a/src/scripts/build_vfxplatform_friction.sh +++ b/src/scripts/build_vfxplatform_friction.sh @@ -77,7 +77,7 @@ cmake -GNinja \ FRICTION_VERSION=`cat version.txt` cmake --build . -FRICTION_INSTALL_DIR=friction-${FRICTION_VERSION}-Linux-x86_64-X11 +FRICTION_INSTALL_DIR=friction-${FRICTION_VERSION} mkdir -p ${CWD}/${FRICTION_INSTALL_DIR}/opt/friction/{bin,lib,share} || true mkdir -p ${CWD}/${FRICTION_INSTALL_DIR}/opt/friction/plugins/{audio,generic,imageformats,platforminputcontexts,platforms,xcbglintegrations} || true DESTDIR=${CWD}/${FRICTION_INSTALL_DIR} cmake --build . --target install diff --git a/src/scripts/build_vfxplatform_package_tar.sh b/src/scripts/build_vfxplatform_package_tar.sh index 1c0709a51..ae213948d 100644 --- a/src/scripts/build_vfxplatform_package_tar.sh +++ b/src/scripts/build_vfxplatform_package_tar.sh @@ -22,7 +22,7 @@ set -e -x CWD=`pwd` SDK=${SDK:-"/opt/friction"} -FRICTION_PKG=${FRICTION_PKG:-friction-0.9.5-Linux-x86_64-X11} +FRICTION_PKG=${FRICTION_PKG:-friction-0.9.5} if [ ! -d "${CWD}/${FRICTION_PKG}" ]; then echo "Missing Friction build" @@ -97,9 +97,11 @@ scalable mkdir -p ${CWD}/${FRICTION_PKG}/usr/bin mkdir -p ${CWD}/${FRICTION_PKG}/usr/share/mime/packages +mkdir -p ${CWD}/${FRICTION_PKG}/usr/share/applications (cd ${CWD}/${FRICTION_PKG}/usr/bin; ln -sf ../../opt/friction/bin/friction .) (cd ${CWD}/${FRICTION_PKG}/usr/share/mime/packages ; ln -sf ../../../../opt/friction/share/mime/packages/friction.xml .) +(cd ${CWD}/${FRICTION_PKG}/usr/share/applications; ln -sf ../../../opt/friction/share/applications/friction.desktop .) for icon in ${HICOLOR}; do ICON_SUFFIX=png @@ -114,6 +116,6 @@ for icon in ${HICOLOR}; do done cd ${CWD} -tar cvvf ${FRICTION_PKG}.tar ${FRICTION_PKG} +tar cvf ${FRICTION_PKG}.tar ${FRICTION_PKG} echo "PKG TAR DONE" diff --git a/src/scripts/vfxplatform.spec b/src/scripts/vfxplatform.spec new file mode 100644 index 000000000..f129c820b --- /dev/null +++ b/src/scripts/vfxplatform.spec @@ -0,0 +1,35 @@ +Name: friction +Version: __FRICTION_VERSION__ +Release: 1 +Summary: Friction Motion Graphics +Group: System Environment/Base +License: GPL3 +Source0: friction-%{version}.tar + +AutoReq: no +%global debug_package %{nil} + +%description +Friction is an open-source, vector-based application designed for creating web animations and videos. + +%prep +%setup -q #unpack tarball + +%build + +%install + +cp -rfa opt %{buildroot}/ +cp -rfa usr %{buildroot}/ +rm -rf %{buildroot}/opt/friction/share/doc + +%files +%defattr(-,root,root,-) +/opt/friction +/usr/bin/friction +/usr/share/applications/friction.desktop +/usr/share/mime/packages/friction.xml +/usr/share/icons/hicolor + +%changelog +