1 # NOTE: probably doesn't work with kernel address space randomization(?)
4 %bcond_without static_libs # static library
5 %bcond_without kernel # kernel modules
6 %bcond_without userspace # userspace library and utilities
7 %bcond_with verbose # verbose build (V=1) of kernel modules
9 %if %{without userspace}
10 # nothing to be placed to debuginfo package
11 %define _enable_debug_packages 0
16 Summary: Berkeley Lab Checkpoint/Restart for Linux
17 Summary(pl.UTF-8): Berkeley Lab Checkpoint/Restart dla Linuksa
18 Name: %{pname}%{?_pld_builder:%{?with_kernel:-kernel}}%{_alt_kernel}
20 Release: %{rel}%{?_pld_builder:%{?with_kernel:@%{_kernel_ver_str}}}
21 License: LGPL v2+ (library), GPL v2+ (utilities and modules)
23 #Source0Download: http://crd.lbl.gov/departments/computer-science/CLaSS/research/BLCR/berkeley-lab-checkpoint-restart-for-linux-blcr-downloads/
24 Source0: http://crd.lbl.gov/assets/Uploads/FTG/Projects/CheckpointRestart/downloads/%{pname}-%{version}.tar.gz
25 # Source0-md5: e0e6d3f6c117d820eaafabf2599ad37b
26 # extract from diff against https://upc-bugs.lbl.gov/blcr-dist/blcr-0.8.6_b4.tar.gz
27 Patch0: %{pname}-update.patch
28 Patch1: %{pname}-am.patch
29 URL: http://crd.lbl.gov/departments/computer-science/CLaSS/research/BLCR/
30 BuildRequires: autoconf >= 2.50
31 BuildRequires: automake
32 BuildRequires: libtool
33 BuildRequires: perl-base
35 BuildRequires: ftb-devel
36 BuildRequires: glibc-devel >= 5:2.4
39 BuildRequires: rpmbuild(macros) >= 1.701
40 # for System.map symbol lookups
41 %{expand:%buildrequires_kernel kernel%%{_alt_kernel} = %%{kernel_version}}
42 %{expand:%buildrequires_kernel kernel%%{_alt_kernel}-module-build = %%{kernel_version}}
43 %{expand:%buildrequires_kernel kernel%%{_alt_kernel}-module-build >= 3:2.6}
45 ExclusiveArch: %{ix86} %{x8664} arm ppc ppc64 sparc sparcv9 sparc64
47 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
50 Berkeley Lab Checkpoint/Restart (BLCR) for Linux is a project of
51 Future Technologies Group researchers to develop a hybrid kernel/user
52 implementation of checkpoint/restart. Their goal is to provide a
53 robust, production quality implementation that checkpoints a wide
54 range of applications, without requiring changes to be made to
55 application code. This work focuses on checkpointing parallel
56 applications that communicate through MPI, and on compatibility with
57 the software suite produced by the SciDAC Scalable Systems Software
60 %description -l pl.UTF-8
61 Berkeley Lab Checkpoint/Restart (BLCR) dla Linuksa to projekt badaczy
62 Future Technologies Group polegający na stworzeniu hybrydowej
63 (działającej w jądrze i przestrzeni użytkownika) implementacji
64 mechanizmu checkpoint/restart (punktów kontrolnych i restartów
65 programów). Celem jest dostarczenie bogatej, mającej produkcyjną
66 jakość implementacji potrafiącej wykonać migawki stanu szerokiej gamy
67 aplikacji bez potrzeby wykonywania zmian w ich kodzie. Praca skupia
68 się na aplikacjach równoległych komunikujących się poprzez MPI oraz
69 zgodności z oprogramowaniem tworzonym przez SciDAC Scalable Systems
73 Summary: Header files for BLCR library
74 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki BLCR
76 Group: Development/Libraries
77 Requires: %{pname} = %{version}-%{release}
80 Header files for BLCR library.
82 %description devel -l pl.UTF-8
83 Pliki nagłówkowe biblioteki BLCR.
86 Summary: Static BLCR library
87 Summary(pl.UTF-8): Statyczna biblioteka BLCR
89 Group: Development/Libraries
90 Requires: %{pname}-devel = %{version}-%{release}
95 %description static -l pl.UTF-8
96 Statyczna biblioteka BLCR.
99 %package -n kernel%{_alt_kernel}-misc-blcr\
100 Summary: BLCR modules for Linux kernel\
101 Summary(pl.UTF-8): Moduły BLCR dla jądra Linuksa\
102 Release: %{rel}@%{_kernel_ver_str}\
105 Requires(post,postun): /sbin/depmod\
106 %requires_releq_kernel\
107 Requires(postun): %releq_kernel\
109 %description -n kernel%{_alt_kernel}-misc-blcr\
110 BLCR modules for Linux kernel.\
112 %description -n kernel%{_alt_kernel}-misc-blcr -l pl.UTF-8\
113 Moduły BLCR dla jądra Linuksa.\
115 %files -n kernel%{_alt_kernel}-misc-blcr\
116 %defattr(644,root,root,755)\
117 /lib/modules/%{_kernel_ver}/misc/blcr.ko*\
118 /lib/modules/%{_kernel_ver}/misc/blcr_imports.ko*\
120 %post -n kernel%{_alt_kernel}-misc-blcr\
121 %depmod %{_kernel_ver}\
123 %postun -n kernel%{_alt_kernel}-misc-blcr\
124 %depmod %{_kernel_ver}\
127 %define build_kernel_pkg()\
129 %{?with_verbose:--enable-kbuild-verbose} \\\
130 --with-linux=%{_kernel_ver} \\\
131 --with-linux-src=%{_kernelsrcdir} \\\
132 --with-kmod-dir=/lib/modules/%{_kernel_ver}/misc \\\
133 --with-system-map=/boot/System.map-%{_kernel_ver} \\\
134 --with-components="%{?with_kernel:modules}"\
139 %{__make} install DESTDIR=$p/installed\
142 %{?with_kernel:%{expand:%create_kernel_packages}}
145 %setup -q -n %{pname}-%{version}
156 %{?with_kernel:%{expand:%build_kernel_packages}}
158 %if %{with userspace}
160 %{?with_static_libs:--enable-static} \
161 --with-components="%{?with_userspace:util libcr include tests examples contrib}"
168 rm -rf $RPM_BUILD_ROOT
171 install -d $RPM_BUILD_ROOT
172 cp -a installed/* $RPM_BUILD_ROOT
176 DESTDIR=$RPM_BUILD_ROOT
179 rm -rf $RPM_BUILD_ROOT
181 %post -p /sbin/ldconfig
182 %postun -p /sbin/ldconfig
184 %if %{with userspace}
186 %defattr(644,root,root,755)
187 %doc LICENSE.txt NEWS README.FTB doc/{README,html}
188 %attr(755,root,root) %{_bindir}/cr_checkpoint
189 %attr(755,root,root) %{_bindir}/cr_restart
190 %attr(755,root,root) %{_bindir}/cr_run
191 %attr(755,root,root) %{_libdir}/libcr.so.*.*.*
192 %attr(755,root,root) %ghost %{_libdir}/libcr.so.0
193 %attr(755,root,root) %{_libdir}/libcr_omit.so.*.*.*
194 %attr(755,root,root) %ghost %{_libdir}/libcr_omit.so.0
195 %attr(755,root,root) %{_libdir}/libcr_run.so.*.*.*
196 %attr(755,root,root) %ghost %{_libdir}/libcr_run.so.0
197 %{_mandir}/man1/cr_checkpoint.1*
198 %{_mandir}/man1/cr_restart.1*
199 %{_mandir}/man1/cr_run.1*
202 %defattr(644,root,root,755)
204 %attr(755,root,root) %{_libdir}/libcr.so
205 %attr(755,root,root) %{_libdir}/libcr_omit.so
206 %attr(755,root,root) %{_libdir}/libcr_run.so
208 %{_libdir}/libcr_omit.la
209 %{_libdir}/libcr_run.la
210 %{_includedir}/blcr_*.h
211 %{_includedir}/libcr.h
213 %if %{with static_libs}
215 %defattr(644,root,root,755)
217 %{_libdir}/libcr_omit.a
218 %{_libdir}/libcr_run.a