1 %{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
4 Summary: Image Creator for Linux Distributions
10 URL: http://www.tizen.org
11 Source0: %{name}_%{version}.tar.gz
15 Requires: python >= 2.5
17 Requires: dosfstools >= 2.11-8
18 Requires: syslinux >= 3.82
21 Requires: device-mapper
22 Requires: /usr/bin/genisoimage
27 Requires: python-urlgrabber
28 Requires: yum >= 3.2.24
29 %if ! 0%{?centos_version}
38 Requires: squashfs >= 4.0
40 Requires: squashfs-tools >= 4.0
43 %if 0%{?fedora_version} || 0%{?centos_version}
44 Requires: syslinux-extlinux
47 %if 0%{?tizen_version:1}
48 Requires: qemu-linux-user
50 Requires: qemu-arm-static
55 BuildRequires: python-devel
56 %if 0%{?tizen_version:1}
57 BuildRequires: python-docutils
62 BuildRoot: %{_tmppath}/%{name}_%{version}-build
65 The tool mic is used to create and manipulate images for Linux distributions.
66 It is composed of three subcommand\: create, convert, chroot. Subcommand create
67 is used to create images with different types; subcommand convert is used to
68 convert an image to a specified type; subcommand chroot is used to chroot into
72 %setup -q -n %{name}-%{version}
75 CFLAGS="$RPM_OPT_FLAGS" %{__python} setup.py build
76 %if 0%{?tizen_version:1}
81 rm -rf $RPM_BUILD_ROOT
83 %{__python} setup.py install --root=$RPM_BUILD_ROOT --prefix=%{_prefix}
85 %{__python} setup.py install --root=$RPM_BUILD_ROOT -O1
89 mkdir -p %{buildroot}/%{_prefix}/share/man/man1
90 %if 0%{?tizen_version:1}
91 install -m644 doc/mic.1 %{buildroot}/%{_prefix}/share/man/man1
95 %defattr(-,root,root,-)
97 %doc README.rst AUTHORS COPYING ChangeLog
98 %if 0%{?tizen_version:1}
101 %dir %{_sysconfdir}/%{name}
102 %config(noreplace) %{_sysconfdir}/%{name}/%{name}.conf
104 %dir %{_prefix}/lib/%{name}
105 %{_prefix}/lib/%{name}/*