Skip to content
Commits on Source (3)
......@@ -5,20 +5,14 @@ set -ev
export Python=${Python:?}
export WORKSPACE=${WORKSPACE:?}
PYTHON_EXECUTABLE="/usr/local/bin/python${Python}"
PYTHON_PREFIX=$(${PYTHON_EXECUTABLE} -c 'import sys;print(sys.prefix)')
PYTHON_VERSION="$(${PYTHON_EXECUTABLE} -c 'import sys;print(sys.version[:3])')"
PYTHON_VERSION_NO_DOT=$(echo ${PYTHON_VERSION} | sed 's/\.//')
PYTHON_INCLUDE_DIR=$(${PYTHON_EXECUTABLE} -c 'from distutils import sysconfig;print(sysconfig.get_python_inc(True))')
PYTHON_LIBRARY=${PYTHON_PREFIX}/lib/libpython${PYTHON_VERSION}.dylib
if [ "${Python}" = "2" ]
then
Boost_PYTHON_LIBRARY=/usr/local/lib/libboost_python.dylib
PYTHON_EXECUTABLE="/usr/local/opt/python@2/bin/python2.7"
else
Boost_PYTHON_LIBRARY=/usr/local/lib/libboost_python${PYTHON_VERSION_NO_DOT}.dylib
PYTHON_EXECUTABLE="/usr/local/bin/python3"
fi
mkdir build
mkdir install
cd build
......@@ -28,10 +22,6 @@ export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig:/usr/local/opt/icu4c/lib/pkgconf
cmake \
-D CMAKE_INSTALL_PREFIX="${WORKSPACE}/install" \
-D PYTHON_EXECUTABLE=${PYTHON_EXECUTABLE} \
-D PYTHON_INCLUDE_DIR=${PYTHON_INCLUDE_DIR} \
-D PYTHON_LIBRARY=${PYTHON_LIBRARY} \
-D Boost_PYTHON_LIBRARY_DEBUG=${Boost_PYTHON_LIBRARY} \
-D Boost_PYTHON_LIBRARY_RELEASE=${Boost_PYTHON_LIBRARY} \
${CMAKE_OPTIONS} \
..
make ${MAKE_OPTIONS} install
......@@ -9,43 +9,47 @@ import sys
brew_conflicting = ["json-c"]
brew_required = [
"boost", "boost-python", "boost-python3", "cmake", "cppcheck", "dcmtk",
"icu4c", "jsoncpp", "lcov", "log4cpp", "pkg-config", "python", "python@2"
"boost", "cmake", "dcmtk", "icu4c", "jsoncpp", "pkg-config", "pybind11"
]
brew_required.append(
"python{}".format("@2" if os.environ["Python"] == 2 else ""))
pip_required = ["cpp-coveralls", "nose"]
pip_required = ["nose"]
for formula in brew_conflicting:
def get_formula_info(formula):
try:
info = json.loads(
subprocess.check_output(["brew", "info", "--json=v1", formula]))
except subprocess.CalledProcessError:
return None
if len(info) > 1:
print("Too many formulas matching {}".format(formula))
sys.exit(1)
elif len(info) == 0:
continue
installed = (len(info[0]["installed"]) != 0)
if installed:
return None
else:
return info[0]
for formula in brew_conflicting:
info = get_formula_info(formula)
if info is not None and info["installed"]:
print("Removing conflicting formula: {}".format(formula))
subprocess.check_call(["brew", "unlink", formula])
for formula in brew_required:
info = json.loads(
subprocess.check_output(["brew", "info", "--json=v1", formula]))
if len(info) > 1:
print("Too many formulas matching {}".format(formula))
sys.exit(1)
elif len(info) == 0:
print("No formula matching {}".format(formula))
sys.exit(1)
info = get_formula_info(formula)
if info is None:
raise Exception("No such formula: {}".format(formula))
action = None
if len(info[0]["installed"]) == 0:
if not info["installed"]:
action = "install"
elif info[0]["installed"][-1]["version"] != info[0]["versions"]["stable"]:
elif not info["installed"][-1]["version"].startswith(info["versions"]["stable"]):
action = "upgrade"
if action is not None:
subprocess.check_call(["brew", action, formula])
subprocess.check_call(
["pip"+os.environ["Python"], "install", "--user", "-U"]+pip_required)
["pip"+os.environ["Python"], "install", "-U"]+pip_required)
......@@ -5,12 +5,8 @@ set -ev
export Python=${Python:?}
export WORKSPACE=${WORKSPACE:?}
cd build
export LD_LIBRARY_PATH=${WORKSPACE}/install/lib
export PYTHONPATH=${WORKSPACE}/install/$(python${Python} -c "from distutils.sysconfig import *; print(get_python_lib(True, prefix=''))")
PYTHON_EXECUTABLE="/usr/local/bin/python${Python}"
PYTHON_VERSION="$(${PYTHON_EXECUTABLE} -c 'import sys;print(sys.version[:3])')"
LOCAL_PYTHON_PREFIX="$(${PYTHON_EXECUTABLE} -c 'from distutils.sysconfig import *; print(get_python_lib(True, prefix=str()))')"
export PYTHONPATH=${WORKSPACE}/install/${LOCAL_PYTHON_PREFIX}
export PATH=~/Library/Python/${PYTHON_VERSION}/bin:${PATH}
../tests/run --no-network --nose nosetests-${PYTHON_VERSION}
cd ${WORKSPACE}/build
"${WORKSPACE}/tests/run"
......@@ -2,8 +2,6 @@
set -ev
export Architecture=${Architecture:?}
export Distribution=${Distribution:?}
export Python=${Python:?}
export WORKSPACE=${WORKSPACE:?}
......@@ -17,16 +15,6 @@ else
PYTHON_VERSION="UNKOWN"
fi
PYTHON_VERSION_NO_DOT=$(echo $PYTHON_VERSION | sed 's|\.||')
if [ "${Distribution}" != "ubuntu/precise" -a "${Distribution}" != "debian/wheezy" ]; then
TRIPLET="$(dpkg-architecture -qDEB_HOST_MULTIARCH)"
else
TRIPLET=""
fi
BOOST_PYTHON_LIBRARY=/usr/lib/${TRIPLET}/libboost_python-py${PYTHON_VERSION_NO_DOT}.so
cd ${WORKSPACE}
mkdir -p build
......@@ -34,10 +22,7 @@ mkdir -p install
cd build
cmake \
-D CMAKE_INSTALL_PREFIX="${WORKSPACE}/install" \
-D Python_ADDITIONAL_VERSIONS=${PYTHON_VERSION} \
-D PYTHON_EXECUTABLE=/usr/bin/python${PYTHON_VERSION} \
-D Boost_PYTHON_LIBRARY_DEBUG=${BOOST_PYTHON_LIBRARY} \
-D Boost_PYTHON_LIBRARY_RELEASE=${BOOST_PYTHON_LIBRARY} \
${CMAKE_OPTIONS} \
..
make ${MAKE_OPTIONS} install
......@@ -2,10 +2,12 @@
set -ev
export Architecture=${Architecture:?}
export Distribution=${Distribution:?}
export Python=${Python:?}
export WORKSPACE=${WORKSPACE:?}
apt-get -y update
apt-get -y --no-install-recommends install gnupg software-properties-common wget
wget -O - http://dl.bintray.com/lamyj/generic/gpg.key | apt-key add -
add-apt-repository "deb http://dl.bintray.com/lamyj/generic/apt $(lsb_release -cs) main"
if [ "${Python}" = "2" ]
then
......@@ -16,21 +18,17 @@ then
fi
# Compilation toolchain
PACKAGES="build-essential cmake pkg-config python-minimal"
# WARNING: we need a full Python for tests runner (argparse may be missing from
# python-minimal)
PACKAGES="build-essential cmake pkg-config python"
# Dependencies of main lib
PACKAGES="${PACKAGES} libboost-dev libboost-date-time-dev libboost-filesystem-dev"
PACKAGES="${PACKAGES} libdcmtk2-dev libicu-dev libjsoncpp-dev liblog4cpp5-dev zlib1g-dev"
PACKAGES="${PACKAGES} libboost-dev libboost-date-time-dev "
PACKAGES="${PACKAGES} libboost-log-dev libboost-filesystem-dev"
PACKAGES="${PACKAGES} libdcmtk2-dev libicu-dev libjsoncpp-dev zlib1g-dev"
# Dependencies of Python wrappers
PACKAGES="${PACKAGES} libboost-python-dev ${PYTHON_PREFIX}-dev"
PACKAGES="${PACKAGES} pybind11-dev ${PYTHON_PREFIX}-pybind11 ${PYTHON_PREFIX}-dev"
# Dependencies of unit tests
PACKAGES="${PACKAGES} dcmtk libboost-test-dev ${PYTHON_PREFIX}-pip ${PYTHON_PREFIX}-nose"
# Coverage and static analysis
PACKAGES="${PACKAGES} cppcheck lcov wget"
if [ "${Distribution}" = "ubuntu/precise" ]
then
PACKAGES="${PACKAGES} libwrap0-dev"
fi
PACKAGES="${PACKAGES} dcmtk libboost-test-dev ${PYTHON_PREFIX} ${PYTHON_PREFIX}-nose"
apt-get -y update
apt-get -y install ${PACKAGES}
apt-get -y --no-install-recommends install ${PACKAGES}
......@@ -2,24 +2,9 @@
set -ev
export Architecture=${Architecture:?}
export Distribution=${Distribution:?}
export Python=${Python:?}
export WORKSPACE=${WORKSPACE:?}
cd ${WORKSPACE}
rm -rf generatedJUnitFiles/CTest/*
cd build
rm -rf Testing/*
if [ ! -d "${WORKSPACE}/generatedJUnitFiles" ]; then
mkdir "${WORKSPACE}/generatedJUnitFiles"
fi
wget -O lcov_cobertura https://raw.github.com/eriwen/lcov-to-cobertura-xml/master/lcov_cobertura/lcov_cobertura.py
chmod a+x lcov_cobertura
if [ "${Python}" = "2" ]
then
NOSE="nosetests-2.7"
......@@ -28,39 +13,8 @@ then
NOSE="nosetests3"
fi
if [ "${Python}" = "3" -a "${Distribution}" = "ubuntu/precise" -o "${Distribution}" = "debian/wheezy" ]
then
# Python 3.2 does not include PEP0414
2to3 -w ../tests/wrappers/test_vr.py
fi
if [ "${Python}" = "2" ]
then
PYTHON_VERSION="$(pyversions -dv)"
elif [ "${Python}" = "3" ]
then
PYTHON_VERSION="$(py3versions -dv)"
else
PYTHON_VERSION="UNKOWN"
fi
export LD_LIBRARY_PATH=${WORKSPACE}/install/lib
export PYTHONPATH=${WORKSPACE}/install/$(python${Python} -c "from distutils.sysconfig import *; print(get_python_lib(True, prefix=''))")
"${WORKSPACE}/tests/run" --no-network --nose ${NOSE}
DIRECTORY=`mktemp -d`
if [ "${Distribution}" != "ubuntu/precise" -a "${Distribution}" != "debian/wheezy" ]; then
lcov --quiet --capture --directory "${WORKSPACE}" --output-file ${DIRECTORY}/test.info
lcov --quiet --remove ${DIRECTORY}/test.info -o ${DIRECTORY}/filtered.info \
'/usr/*' '*/src/appli/*' '*/tests/*' '*/build/*'
else
touch ${DIRECTORY}/filtered.info
fi
cp ${DIRECTORY}/filtered.info "${WORKSPACE}/build/coverage.info"
./lcov_cobertura ${DIRECTORY}/filtered.info -b "${WORKSPACE}"
rm -rf ${DIRECTORY}
#cppcheck -q --xml --xml-version=2 --enable=all \
# -i "${WORKSPACE}/tests/tools" \
# "${WORKSPACE}/src/" "${WORKSPACE}/tests/" "${WORKSPACE}/wrappers/" \
# 2> ${WORKSPACE}/build/cppcheck.xml
cd ${WORKSPACE}/build
"${WORKSPACE}/tests/run" --nose ${NOSE}
language: cpp
language: minimal
sudo: required
services:
- docker
matrix:
include:
- os: linux
sudo: required
dist: trusty
compiler: gcc
env: Architecture=amd64 Distribution=ubuntu/trusty Python=3 WORKSPACE=${TRAVIS_BUILD_DIR} CMAKE_OPTIONS="-D CMAKE_CXX_FLAGS=--coverage" MAKE_OPTIONS="-j$(nproc)"
- os: osx
compiler: clang
env: Python=3 WORKSPACE=${TRAVIS_BUILD_DIR} MAKE_OPTIONS="-j$(sysctl -n hw.ncpu)"
# Debian
- name: "Debian Stretch, Python 3"
env:
vendor: debian
version: stretch
python: 3
CMAKE_OPTIONS: "'-D CMAKE_CXX_FLAGS=--coverage'"
- name: "Debian Stretch, Python 2"
env: { vendor: debian, version: stretch, python: 2 }
- name: "Debian Jessie, Python 3"
env: { vendor: debian, version: jessie, python: 3 }
- name: "Debian Jessie, Python 2"
env: { vendor: debian, version: jessie, python: 2 }
# Ubuntu
- name: "Ubuntu Bionic, Python 3"
env: { vendor: ubuntu, version: bionic, python: 3 }
- name: "Ubuntu Bionic, Python 2"
env: { vendor: ubuntu, version: bionic, python: 2 }
- name: "Ubuntu Xenial, Python 3"
env: { vendor: ubuntu, version: xenial, python: 3 }
- name: "Ubuntu Xenial, Python 2"
env: { vendor: ubuntu, version: xenial, python: 2 }
- name: "Ubuntu Trusty, Python 3"
env: { vendor: ubuntu, version: trusty, python: 3 }
- name: "Ubuntu Trusty, Python 2"
env: { vendor: ubuntu, version: trusty, python: 2 }
before_install:
- |
docker run -di \
-e Python=${python} -e WORKSPACE=${TRAVIS_BUILD_DIR} \
-e MAKE_OPTIONS="-j$(nproc)" \
-e CMAKE_OPTIONS="${CMAKE_OPTIONS}" \
-v ${TRAVIS_BUILD_DIR}:${TRAVIS_BUILD_DIR} \
--name odil --rm \
${vendor}:${version}
install:
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then sudo -E sh ./.ci/deb/install; fi
- if [ "$TRAVIS_OS_NAME" = "osx" ]; then ./.ci/brew/install; fi
- if [ "${CC}" = "gcc" ]; then /usr/bin/pip${Python} install -U --user cpp-coveralls; fi
- if [ "${CC}" = "gcc" ]; then export PATH=$(python -c 'import site; print(site.getuserbase())')/bin:${PATH}; fi
- docker exec odil ${TRAVIS_BUILD_DIR}/.ci/deb/install
#- docker exec odil pip${python} install -U --user cpp-coveralls
# TODO: export PATH=$(python -c 'import site; print(site.getuserbase())')/bin:${PATH}
script:
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then ./.ci/deb/build; fi
- if [ "$TRAVIS_OS_NAME" = "osx" ]; then ./.ci/brew/build; fi
- docker exec odil ${TRAVIS_BUILD_DIR}/.ci/deb/build
after_success:
- if [ "$TRAVIS_OS_NAME" = "linux" ]; then ./.ci/deb/post_build; fi
- if [ "$TRAVIS_OS_NAME" = "osx" ]; then ./.ci/brew/post_build; fi
- if [ "${CC}" = "gcc" ]; then coveralls -n -l build/coverage.info; fi
- docker exec odil ${TRAVIS_BUILD_DIR}/.ci/deb/post_build
#- docker exec odil coveralls -n -l build/coverage.info
......@@ -2,8 +2,8 @@ cmake_minimum_required(VERSION 2.8)
project("odil")
set(odil_MAJOR_VERSION 0)
set(odil_MINOR_VERSION 9)
set(odil_PATCH_VERSION 2)
set(odil_MINOR_VERSION 10)
set(odil_PATCH_VERSION 0)
set(odil_VERSION
${odil_MAJOR_VERSION}.${odil_MINOR_VERSION}.${odil_PATCH_VERSION})
......
# - Try to find Log4Cpp
# Once done this will define
# Log4Cpp_FOUND - System has Log4Cpp
# Log4Cpp_INCLUDE_DIRS - The Log4Cpp include directories
# Log4Cpp_LIBRARIES - The libraries needed to use Log4Cpp
# Log4Cpp_DEFINITIONS - Compiler switches required for using Log4Cpp
find_package(PkgConfig)
pkg_check_modules(PC_Log4Cpp QUIET log4cpp)
set(Log4Cpp_DEFINITIONS ${PC_Log4Cpp_CFLAGS_OTHER})
find_path(Log4Cpp_INCLUDE_DIR "log4cpp/Category.hh" HINTS ${PC_Log4Cpp_INCLUDE_DIRS})
find_library(Log4Cpp_LIBRARY NAMES log4cpp log4cppD HINTS ${PC_Log4Cpp_LIBRARY_DIRS} )
set(Log4Cpp_LIBRARIES ${Log4Cpp_LIBRARY} )
set(Log4Cpp_INCLUDE_DIRS ${Log4Cpp_INCLUDE_DIR} )
include(FindPackageHandleStandardArgs)
# handle the QUIETLY and REQUIRED arguments and set Log4Cpp_FOUND to TRUE
# if all listed variables are TRUE
find_package_handle_standard_args(
Log4Cpp DEFAULT_MSG Log4Cpp_LIBRARY Log4Cpp_INCLUDE_DIR)
mark_as_advanced(Log4Cpp_INCLUDE_DIR Log4Cpp_LIBRARY)
......@@ -12,7 +12,7 @@ parts of the DICOM standard. Included in Odil are:
Odil builds and run on:
- Linux (Debian 7, 8 and 9; Ubuntu 14.04, and 16.04). Official packages are available ([Debian](https://packages.debian.org/search?keywords=odil&searchon=sourcenames&suite=all&section=all), [Ubuntu](http://packages.ubuntu.com/search?keywords=odil&searchon=sourcenames&suite=all&section=all)), as well as [unofficial backports](https://github.com/lamyj/packages).
- Linux (Debian 8 and 9; Ubuntu 14.04, 16.04 and 18.04). Official packages are available ([Debian](https://packages.debian.org/search?keywords=odil&searchon=sourcenames&suite=all&section=all), [Ubuntu](http://packages.ubuntu.com/search?keywords=odil&searchon=sourcenames&suite=all&section=all)), as well as [unofficial backports](https://github.com/lamyj/packages).
- macOS
- Windows
......
......@@ -79,7 +79,7 @@ def find(host, port, calling_ae_title, called_ae_title, level, keys, decode_uids
max_length = max(max_length, find_max_name_length(data_set))
for data_set in data_sets:
print_data_set(data_set, decode_uids, "", max_length)
print_data_set(data_set, decode_uids, "", max_length, odil.Value.Strings())
print()
association.release()
......
from __future__ import print_function
from __future__ import print_function, unicode_literals
import argparse
import logging
import os
......@@ -6,7 +6,7 @@ import re
import odil
from .print_ import find_max_name_length, print_data_set
from .print_ import find_max_name_length
from .dicomdir import create_dicomdir
def add_subparser(subparsers):
......@@ -129,6 +129,12 @@ def get(
self._series_ids = {}
def store(self, data_set):
specific_character_set = odil.Value.Strings()
if "SpecificCharacterSet" in data_set:
specific_character_set = data_set.as_string(
"SpecificCharacterSet")
as_unicode = lambda x: odil.as_unicode(x, specific_character_set)
if layout == "flat":
directory = ""
elif layout == "tree":
......@@ -137,8 +143,8 @@ def get(
if "PatientName" in data_set and data_set.as_string("PatientName"):
patient_directory = data_set.as_string("PatientName")[0]
else:
patient_directory = data_set.as_string("PatientID")[0]
patient_directory = as_unicode(patient_directory)
# Study directory: <StudyID>_<StudyDescription>, both parts are
# optional. If both tags are missing or empty, default to a
......@@ -157,7 +163,7 @@ def get(
self._study_ids.setdefault(
study_instance_uid, 1+len(self._study_ids)))
study_directory = "_".join(study_directory)
study_directory = "_".join(as_unicode(x) for x in study_directory)
# Study directory: <SeriesNumber>_<SeriesDescription>, both
# parts are optional. If both tags are missing or empty, default
......@@ -176,7 +182,7 @@ def get(
self._series_ids.setdefault(
series_instance_uid, 1+len(self._series_ids)))
series_directory = "_".join(series_directory)
series_directory = "_".join(as_unicode(x) for x in series_directory)
if iso_9660:
patient_directory = to_iso_9660(patient_directory)
......@@ -194,10 +200,10 @@ def get(
if iso_9660:
filename = "IM{:06d}".format(1+self.stored[directory])
else:
filename = data_set.as_string("SOPInstanceUID")[0]
filename = as_unicode(data_set.as_string("SOPInstanceUID")[0])
odil.write(
data_set, os.path.join(self.directory, directory, filename))
with odil.open(os.path.join(self.directory, directory, filename), "wb") as fd:
odil.Writer.write_file(data_set, fd)
self.stored[directory] += 1
self.files.append(os.path.join(directory, filename))
......
......@@ -47,7 +47,8 @@ def transcode(input, output, format, transfer_syntax, pretty_print):
def as_binary(input, output, transfer_syntax):
with odil.open(input) as stream:
_, data_set = odil.Reader.read_file(stream)
odil.write(data_set, output, transfer_syntax=transfer_syntax)
with odil.open(output, "wb") as fd:
odil.Writer.write_file(data_set, fd, transfer_syntax=transfer_syntax)
def as_json(input, output, pretty_print):
with odil.open(input) as stream:
......
<?xml version="1.0" encoding="UTF-8"?>
<!--
The MIT License (MIT)
Copyright (c) 2014, Gregory Boissinot
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
-->
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output method="xml" indent="yes"/>
<xsl:template match="/">
<testsuites>
<xsl:variable name="buildName" select="//Site/@BuildName"/>
<xsl:variable name="numberOfTests" select="count(//Site/Testing/Test)"/>
<xsl:variable name="numberOfFailures" select="count(//Site/Testing/Test[@Status!='passed'])"/>
<testsuite name="CTest"
tests="{$numberOfTests}" time="0"
failures="{$numberOfFailures}" errors="0"
skipped="0">
<xsl:for-each select="//Site/Testing/Test">
<xsl:variable name="testName" select="translate(Name, '-', '_')"/>
<xsl:variable name="duration" select="Results/NamedMeasurement[@name='Execution Time']/Value"/>
<xsl:variable name="status" select="@Status"/>
<xsl:variable name="output" select="Results/Measurement/Value"/>
<xsl:variable name="className" select="translate(Path, '/.', '.')"/>
<testcase classname="projectroot{$className}"
name="{$testName}"
time="{$duration}">
<xsl:choose>
<xsl:when test="@Status='passed'"/>
<xsl:when test="@Status='notrun'">
<skipped/>
</xsl:when>
<xsl:otherwise>
<failure>
<xsl:value-of select="$output"/>
</failure>
</xsl:otherwise>
</xsl:choose>
<system-out>
<xsl:value-of select="$output"/>
</system-out>
</testcase>
</xsl:for-each>
</testsuite>
</testsuites>
</xsl:template>
</xsl:stylesheet>
\ No newline at end of file
......@@ -17,8 +17,11 @@ Build-Depends: debhelper (>= 10),
libboost-dev,
libboost-date-time-dev,
libboost-filesystem-dev,
libboost-log-dev,
libboost-python-dev,
liblog4cpp5-dev,
pybind11-dev,
python-pybind11,
python3-pybind11,
libboost-test-dev (>= 1.46.1),
chrpath,
dcmtk (>= 3.6.0),
......
.\" DO NOT MODIFY THIS FILE! It was generated by help2man 1.44.1.
.TH ODIL "1" "May 2018" "odil 0.9.2" "User Commands"
.TH ODIL "1" "November 2018" "odil 0.10.0" "User Commands"
.SH NAME
odil \- Command-line DICOM tool
.SH DESCRIPTION
......
......@@ -8,9 +8,6 @@ PYTHON2=$(shell pyversions -vrd)
PYTHON3=$(shell py3versions -vrd)
ALLPY=$(PYTHON2) $(PYTHON3)
# Required to get the full path to the boost.python library
TRIPLET=$(shell dpkg-architecture -qDEB_HOST_MULTIARCH)
%:
dh $@ --builddirectory=build --with python2,python3
......@@ -29,15 +26,11 @@ override_dh_auto_build-nopy:
# same build directory
override_dh_auto_build-py: override_dh_auto_build-nopy
for Python in $(ALLPY); do \
PythonNoDot=$$(echo $${Python} | sed 's|\.||'); \
cp -a build-nopy build; \
dh_auto_configure -- \
-DBUILD_EXAMPLES=OFF \
-DBUILD_PYTHON_WRAPPERS=ON -DBUILD_JAVASCRIPT_WRAPPERS=OFF \
-DPython_ADDITIONAL_VERSIONS=$${Python} \
-DPYTHON_EXECUTABLE=/usr/bin/python$${Python} \
-DBoost_PYTHON_LIBRARY_DEBUG=/usr/lib/$(TRIPLET)/libboost_python-py$${PythonNoDot}.so \
-DBoost_PYTHON_LIBRARY_RELEASE=/usr/lib/$(TRIPLET)/libboost_python-py$${PythonNoDot}.so; \
dh_auto_build; \
mv build build-py$${Python}; \
done
......@@ -109,9 +102,9 @@ override_dh_install-arch:
--devunversioned \
--commit --multiarch --exclude-a --exclude-la \
--movedev debian/tmp/usr/include/* usr/include \
--override s/libboost_log.*-dev/libboost-log-dev/ \
debian/tmp/usr/lib/*.so
override_dh_clean:
dh_clean
find tests -name "*pyc" -delete
......
......@@ -74,9 +74,9 @@ author = 'Julien Lamy'
# built documents.
#
# The short X.Y version.
version = '0.9.2'
version = '0.10.0'
# The full version, including alpha/beta/rc tags.
release = '0.9.2'
release = '0.10.0'
# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
......
......@@ -19,8 +19,8 @@ parts of the DICOM standard. Included in Odil are:
Odil builds and run on:
- Linux (Debian 7, 8 and 9; Ubuntu 14.04, and 16.04). Official packages are available in `Debian`_ and `Ubuntu`_, as well as `unofficial backports`_.
- macOS
- Linux (Debian 8 and 9; Ubuntu 14.04, 16.04 and 18.04). Official packages are available in `Debian`_ and `Ubuntu`_, as well as `unofficial backports`_.
- macOS (a `Homebrew tap`_ is available)
- Windows
Odil is free software: you can redistribute and/or modify it under the terms of the `CeCILL-B license`_.
......@@ -40,5 +40,6 @@ Table of contents
.. _DCMTK: http://dicom.offis.de/dcmtk.php.en
.. _Debian: https://packages.debian.org/search?keywords=odil&searchon=sourcenames&suite=all&section=all
.. _DICOM: http://dicom.nema.org/
.. _Homebrew tap: https://github.com/lamyj/homebrew-odil
.. _Ubuntu: http://packages.ubuntu.com/search?keywords=odil&searchon=sourcenames&suite=all&section=all
.. _unofficial backports: https://github.com/lamyj/packages/
......@@ -14,10 +14,9 @@ The core of Odil depends on:
- C++ 11 (GCC >= 4.7, Clang)
- `CMake`_ (>= 2.8.9)
- `Boost`_ (>= 1.49, uses `Asio`_, `Date Time`_, `Filesystem`_, `Fusion`_, `Preprocessor`_, `Property Tree`_, `Spirit`_, `Uuid`_)
- `Boost`_ (>= 1.54, uses `Asio`_, `Date Time`_, `Filesystem`_, `Fusion`_, `Log`, `Preprocessor`_, `Property Tree`_, `Spirit`_, `Uuid`_)
- `ICU4C`_ (>= 4.8.1.1)
- `JsonCpp`_ (>= 0.6.0)
- `log4cpp`_ (>= 1.0)
Earlier versions of these dependencies might work but are unsupported.
......@@ -40,9 +39,9 @@ The system-specific instructions will detail how to install using pre-compiled p
.. code-block:: bash
wget https://github.com/lamyj/odil/archive/v0.9.2.tar.gz
tar -x -f v0.9.2.tar.gz
cd odil-0.9.2
wget https://github.com/lamyj/odil/archive/v0.10.0.tar.gz
tar -x -f v0.10.0.tar.gz
cd odil-0.10.0
You can also clone the `Git repository`_. Note that the latest Git version may not always compile; should it happen, you can keep your clone but check out the latest tagged version:
......@@ -50,7 +49,7 @@ You can also clone the `Git repository`_. Note that the latest Git version may n
git clone https://github.com/lamyj/odil
cd odil
git checkout v0.9.2
git checkout v0.10.0
Building the Python wrappers
----------------------------
......@@ -76,7 +75,6 @@ When building the Python wrappers, the Python interpreter and libraries default
.. _Git repository: https://github.com/lamyj/odil
.. _ICU4C: https://ssl.icu-project.org/apiref/icu4c/
.. _JsonCpp: https://github.com/open-source-parsers/jsoncpp
.. _log4cpp: http://log4cpp.sourceforge.net/
.. _nose: https://nose.readthedocs.io/en/latest/testing.html
.. _Preprocessor: http://www.boost.org/doc/libs/release/libs/preprocessor/
.. _Property Tree: http://www.boost.org/doc/libs/release/libs/property_tree/
......