diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000000..7260eae708 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,45 @@ +sudo: false + +language: cpp + +matrix: + include: + - os: linux + env: CONDA_PY=3.6 + +dist: trusty + +install: + - sudo apt-get update + - ldd --version + - wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh; + - bash miniconda.sh -b -p $HOME/miniconda + - export PATH="$HOME/miniconda/bin:$PATH" + - rm -f miniconda.sh + - hash -r + - conda config --set always_yes yes --set changeps1 no + - conda config --add channels conda-forge + - conda config --add channels slsdetectorgroup + - conda update conda + - conda update --all + - conda install conda-build anaconda-client + + # Useful for debugging any issues with conda + - conda info -a + + + # Replace dep1 dep2 ... with your dependencies + - conda create -q -n test-environment python=$CONDA_PY + - source activate test-environment + - conda-build . + +script: + - echo "No test scripts to be run!" + + +deploy: + provider: script + script: find $HOME/miniconda/conda-bld/${TRAVIS_OS_NAME}-64 -name "*.tar.bz2" -exec anaconda -t $CONDA_TOKEN upload --force {} \; + on: + branch: 4.0.0 + diff --git a/recipe/build.sh b/recipe/build.sh new file mode 100644 index 0000000000..ccaa0f3d12 --- /dev/null +++ b/recipe/build.sh @@ -0,0 +1,15 @@ +mkdir build +mkdir install +cd build +cmake .. \ + -DCMAKE_PREFIX_PATH=$CONDA_PREFIX \ + -DCMAKE_INSTALL_PREFIX=install \ + -DUSE_TEXTCLIENT=ON \ + -DUSE_RECEIVER=ON \ + -DUSE_GUI=ON \ + -DCMAKE_BUILD_TYPE=Release \ + -DUSE_HDF5=OFF\ + + +cmake --build . -- -j10 +cmake --build . --target install \ No newline at end of file diff --git a/recipe/copy_gui.sh b/recipe/copy_gui.sh new file mode 100644 index 0000000000..26ce29890a --- /dev/null +++ b/recipe/copy_gui.sh @@ -0,0 +1,15 @@ + +mkdir $PREFIX/lib +mkdir $PREFIX/bin +mkdir $PREFIX/include + +#No libs for gui? + +#Binaries +cp build/bin/gui_client $PREFIX/bin/. +cp build/bin/slsDetectorGui $PREFIX/bin/. + + +#Which headers do we need for development?? + +# cp include/some_lib.h $PREFIX/include/. \ No newline at end of file diff --git a/recipe/copy_lib.sh b/recipe/copy_lib.sh new file mode 100644 index 0000000000..4c427ee927 --- /dev/null +++ b/recipe/copy_lib.sh @@ -0,0 +1,23 @@ + +mkdir $PREFIX/lib +mkdir $PREFIX/bin +mkdir $PREFIX/include +mkdir $PREFIX/include/slsDetectorPackage + +#Shared and static libraries +cp build/bin/libSlsDetector.so $PREFIX/lib/. +cp build/bin/libSlsDetector.a $PREFIX/lib/. +cp build/bin/libSlsReceiver.so $PREFIX/lib/. +cp build/bin/libSlsReceiver.a $PREFIX/lib/. + +#Binaries +cp build/bin/sls_detector_acquire $PREFIX/bin/. +cp build/bin/sls_detector_get $PREFIX/bin/. +cp build/bin/sls_detector_put $PREFIX/bin/. +cp build/bin/sls_detector_help $PREFIX/bin/. +cp build/bin/slsReceiver $PREFIX/bin/. +cp build/bin/slsMultiReceiver $PREFIX/bin/. + +#Which headers do we need for development?? +cp build/install/include/* $PREFIX/include/slsDetectorPackage/ +# cp include/some_lib.h $PREFIX/include/. \ No newline at end of file diff --git a/recipe/meta.yaml b/recipe/meta.yaml new file mode 100644 index 0000000000..a42f74d051 --- /dev/null +++ b/recipe/meta.yaml @@ -0,0 +1,89 @@ + +package: + name: sls_detector_software + version: 4.0.0 + +source: + - path: .. + +build: + number: 0 + rpaths: + - lib/ + +requirements: + build: + - {{ compiler('c') }} + - {{compiler('cxx')}} + - cmake + - qwt 6.* + - qt=4.8.7=7 + - zeromq=4.2.5=hfc679d8_5 + - pyzmq + - xorg-libx11 + - xorg-libice + - xorg-libxext + - xorg-libsm + - xorg-libxau + - xorg-libxrender + - xorg-libxfixes + - {{ cdt('mesa-libgl-devel') }} # [linux] + - {{ cdt('mesa-libegl-devel') }} # [linux] + - {{ cdt('mesa-dri-drivers') }} # [linux] + - {{ cdt('libselinux') }} # [linux] + - {{ cdt('libxdamage') }} # [linux] + - {{ cdt('libxxf86vm') }} # [linux] + + host: + - libstdcxx-ng + - libgcc-ng + - libpng >=1.6.32,<1.6.35 + - xorg-libx11 + - xorg-libice + - xorg-libxext + - xorg-libsm + - xorg-libxau + - xorg-libxrender + - xorg-libxfixes + + run: + - libstdcxx-ng + - libgcc-ng + +outputs: + - name: sls_detector_lib + version: 4.0.0 + script: copy_lib.sh + requirements: + build: + - {{ compiler('c') }} + - {{compiler('cxx')}} + - name: sls_detector_gui + version: 4.0.0 + script: copy_gui.sh + requirements: + build: + - {{ compiler('c') }} + - {{compiler('cxx')}} + - cmake + - qwt 6.* + - qt=4.8.7=7 + - zeromq=4.2.5=hfc679d8_5 + - pyzmq + - xorg-libx11 + - xorg-libice + - xorg-libxext + - xorg-libsm + - xorg-libxau + - xorg-libxrender + - xorg-libxfixes + - {{ cdt('mesa-libgl-devel') }} # [linux] + - {{ cdt('mesa-libegl-devel') }} # [linux] + - {{ cdt('mesa-dri-drivers') }} # [linux] + - {{ cdt('libselinux') }} # [linux] + - {{ cdt('libxdamage') }} # [linux] + - {{ cdt('libxxf86vm') }} # [linux] + run: + - sls_detector_lib=4.0.0 + - qwt 6.* + - qt=4.8.7=7