Priprava za prevajanje plugina za LSB

This commit is contained in:
Janez Zibert 2025-02-21 08:44:34 +01:00
parent 3e63ff2a37
commit fe08ec25be
7 changed files with 91 additions and 3 deletions

View File

@ -0,0 +1,37 @@
#!/bin/bash
##
## This script compiles cross-distribution Linux binaries thanks to
## Holy Build Box: https://github.com/phusion/holy-build-box
##
## The ideal solution would be to use Linux Standard Base
## (LSB). Unfortunately, the LSB C++ compiler is a pre-4.8 gcc that
## does not feature full C++11 capabilities, which prevents compiling
## GDCM >= 3.0.
##
set -ex
if [ "$1" != "Debug" -a "$1" != "Release" ]; then
echo "Please provide build type: Debug or Release"
exit -1
fi
if [ -t 1 ]; then
# TTY is available => use interactive mode
DOCKER_FLAGS='-i'
fi
ROOT_DIR=`dirname $(readlink -f $0)`/..
mkdir -p ${ROOT_DIR}/holy-build-box
docker run -t ${DOCKER_FLAGS} --rm \
--user $(id -u):$(id -g) \
-v ${ROOT_DIR}:/source:ro \
-v ${ROOT_DIR}/holy-build-box:/target:rw \
phusion/holy-build-box-64:3.0.5 \
bash /source/Resources/holy-build-box-internal.sh $1
ls -lR ${ROOT_DIR}/holy-build-box/

View File

@ -0,0 +1,50 @@
#!/bin/bash
set -e
# Activate Holy Build Box environment.
source /hbb_exe/activate
set -x
# Download Mercurial to use the mainline of Orthanc framework
MERCURIAL_VERSION=5.3
curl https://www.mercurial-scm.org/release/mercurial-${MERCURIAL_VERSION}.tar.gz > /tmp/mercurial.tar.gz
cd /tmp
tar xvf mercurial.tar.gz
export PATH=$PATH:/tmp/mercurial-${MERCURIAL_VERSION}
mkdir /tmp/build
cd /tmp/build
# Holy Build Box defines LDFLAGS as "-L/hbb_exe/lib
# -static-libstdc++". The "-L/hbb_exe/lib" option results in linking
# errors "undefined reference" to `std::__once_callable',
# 'std::__once_call' and '__once_proxy'.
export LDFLAGS=-static-libstdc++
unset LDPATHFLAGS
unset SHLIB_LDFLAGS
unset LD_LIBRARY_PATH
unset LIBRARY_PATH
mkdir /tmp/source-writeable
cp -r /source/CMakeLists.txt /tmp/source-writeable/
cp -r /source/Plugin /tmp/source-writeable/
cp -r /source/Resources /tmp/source-writeable/
#cp -r /source/UnitTestsSources /tmp/source-writeable/
cp -r /source/WebApplication /tmp/source-writeable/
cmake /tmp/source-writeable \
-DCMAKE_BUILD_TYPE=$1 -DSTATIC_BUILD=ON \
-DCMAKE_INSTALL_PREFIX=/target
make -j`nproc`
# if [ "$1" == "Release" ]; then
# strip ./libOrthancDicomWeb.so
# fi
make install

View File

@ -4,7 +4,7 @@
<meta charset="UTF-8" />
<link rel="icon" href="/favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>...</title>
<title>AI PACS</title>
<script>
// Custom bit of code to redirect to /app/ if the uri is /app
// The reason for this is that the path to assets is relative

Binary file not shown.

After

Width:  |  Height:  |  Size: 155 KiB

View File

@ -161,7 +161,7 @@ export default {
<div class="nav-side-menu">
<div class="nav-side-content">
<div v-if="!hasCustomLogo">
<img class="orthanc-logo" src="../assets/images/orthanc.png"/>
<img class="orthanc-logo" src="../assets/images/orthanc-stata.png"/>
</div>
<div v-if="hasCustomLogo">
<img class="custom-logo" :src="customLogoUrl" />
@ -169,7 +169,7 @@ export default {
<div v-if="hasCustomLogo">
<p class="powered-by-orthanc">
powered by
<img src="../assets/images/orthanc.png" />
<img src="../assets/images/orthanc-stata.png" />
</p>
</div>
<div v-if="uiOptions.ShowOrthancName" class="orthanc-name">

View File

@ -0,0 +1 @@
libOrthancExplorer2.so.mainline