# --------------------------------------------------------------------- # # Copyright (c) CREATIS (Centre de Recherche en Acquisition et Traitement de l'Image # pour la SantÈ) # Authors : Eduardo Davila, Frederic Cervenansky, Claire Mouton # Previous Authors : Laurent Guigues, Jean-Pierre Roux # CreaTools website : www.creatis.insa-lyon.fr/site/fr/creatools_accueil # # This software is governed by the CeCILL-B license under French law and # abiding by the rules of distribution of free software. You can use, # modify and/ or redistribute the software under the terms of the CeCILL-B # license as circulated by CEA, CNRS and INRIA at the following URL # http://www.cecill.info/licences/Licence_CeCILL-B_V1-en.html # or in the file LICENSE.txt. # # As a counterpart to the access to the source code and rights to copy, # modify and redistribute granted by the license, users are provided only # with a limited warranty and the software's author, the holder of the # economic rights, and the successive licensors have only limited # liability. # # The fact that you are presently reading this means that you have had # knowledge of the CeCILL-B license and that you accept its terms. # ------------------------------------------------------------------------ */ # Note that this is NOT a relocatable package %define prefix /usr Summary: BBTK Name: BBTK Version: 1.0.0 Release: 1.0.0 # 1.0.0. License: CeCILL-B Group: Development/Libraries Source: bbtk.tgz BuildRoot: /tmp/bbtk-%{version}-root Prereq: /sbin/install-info Docdir: %{prefix}/doc #Requires: vtk = 4.5.0-0.cvs.2.fc4 #Requires: vtk-python = 4.5.0-0.cvs.2.fc4 #BuildPrereq: vtk-devel = 4.5.0-0.cvs.2.fc4 #BuildRequires: cmake >= 2 %description The Black Box ToolKit %changelog * Wed Jul 23 2008 Laurent Guigues 1.0.0 - initial packaging with cmake %prep %setup -q -n bbtk export CC='gcc' export CXX='g++' export MAKE='make %{?_smp_mflags}' export CFLAGS="$RPM_OPT_FLAGS" export CXXFLAGS="$RPM_OPT_FLAGS -Wno-deprecated" cd .. if [ -d bbtkbin ] then rm -rf bbtkbin fi mkdir bbtkbin cd bbtkbin cmake ../bbtk \ -DCMAKE_INSTALL_PREFIX:STRING="%{_prefix}" \ -DCMAKE_SKIP_RPATH:BOOL=ON \ -DCMAKE_CXX_COMPILER:FILEPATH=$CXX \ -DCMAKE_C_COMPILER:FILEPATH=$CC \ -D--BUILD_ALL=ON cmake ../bbtk \ -DCMAKE_INSTALL_PREFIX:STRING="%{_prefix}" \ -DCMAKE_SKIP_RPATH:BOOL=ON \ -DCMAKE_CXX_COMPILER:FILEPATH=$CXX \ -DCMAKE_C_COMPILER:FILEPATH=$CC \ -D--BUILD_ALL=ON cmake ../bbtk \ -DCMAKE_INSTALL_PREFIX:STRING="%{_prefix}" \ -DCMAKE_SKIP_RPATH:BOOL=ON \ -DCMAKE_CXX_COMPILER:FILEPATH=$CXX \ -DCMAKE_C_COMPILER:FILEPATH=$CC \ -D--BUILD_ALL=ON cmake ../bbtk \ -DCMAKE_INSTALL_PREFIX:STRING="%{_prefix}" \ -DCMAKE_SKIP_RPATH:BOOL=ON \ -DCMAKE_CXX_COMPILER:FILEPATH=$CXX \ -DCMAKE_C_COMPILER:FILEPATH=$CC \ -D--BUILD_ALL=ON %build cd ../bbtkbin export DISPLAY=:0.0 make # TO USE MULTIPLE PROCESSORS : # %{?_smp_mflags} %install cd ../bbtkbin rm -rf $RPM_BUILD_ROOT export DISPLAY=:0.0 make DESTDIR=$RPM_BUILD_ROOT install # %{?_smp_mflags} # creating file bbtk.conf in /etc/ld.so.conf.d # which contains the path to BBTK dynamic libs #install -d $RPM_BUILD_ROOT/%{_sysconfdir}/ld.so.conf.d #echo "%{_libdir}/bbtk" > $RPM_BUILD_ROOT/%{_sysconfdir}/ld.so.conf.d/bbtk.conf %clean rm -rf $RPM_BUILD_ROOT %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files %defattr(-, root, root) #%doc AUTHORS ChangeLog README TODO DEVELOPPER INSTALL PACKAGER #%doc ChangeLog README TODO #%doc Doc %{_libdir}/* %{_includedir}/* %{_datadir}/* %{_bindir}/* #%{_sysconfdir}/ld.so.conf.d/BBTK.conf