]> git.pld-linux.org Git - SPECS.git/blob - floppy.spec
SPECS updated Wed 28 Jul 14:48:01 CEST 2021
[SPECS.git] / floppy.spec
1 #
2 # Conditional build:
3 %bcond_without  gtk     # GTK+ 2 GUI
4 #
5 Summary:        Floppy formatting utility
6 Summary(pl.UTF-8):      Narzędzie do formatowania dyskietek
7 Name:           floppy
8 Version:        0.18
9 Release:        1
10 License:        GPL v3
11 Group:          Applications/System
12 Source0:        http://downloads.sourceforge.net/floppyutil/%{name}-%{version}.tar.bz2
13 # Source0-md5:  a02aac97c74259ca1b24972c89147ca4
14 Source1:        floppygtk.desktop
15 URL:            http://floppyutil.sourceforge.net/
16 BuildRequires:  gtk+2-devel >= 2.0
17 BuildRequires:  pkgconfig
18 BuildRequires:  popt-devel
19 Requires:       uname(release) >= 2.4.10
20 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
21
22 %description
23 The floppy utility does low-level formatting of floppy disks. This
24 utility supports formatting of disks in LS-120 drives.
25
26 %description -l pl.UTF-8
27 Narzędzie floppy wykonuje niskopoziomowe formatowanie dyskietek. To
28 narzędzie obsługuje także formatowanie dyskietek w napędach LS-120.
29
30 %package gtk
31 Summary:        GTK+ floppy formatting utility
32 Summary(pl.UTF-8):      Narzędzie GTK+ do formatowania dyskietek
33 Group:          X11/Applications
34 Requires:       %{name} = %{version}-%{release}
35
36 %description gtk
37 This package contains a GTK+ interface to the floppy formatting
38 utility.
39
40 %description gtk -l pl.UTF-8
41 Ten pakiet zawiera graficzny interfejs GTK+ do narzędzia floppy
42 służącego do formatowania dyskietek.
43
44 %prep
45 %setup -q
46
47 %build
48 %configure \
49         %{!?with_gtk:--disable-gtk2}
50 %{__make}
51
52 %install
53 rm -rf $RPM_BUILD_ROOT
54
55 %{__make} install \
56         DESTDIR=$RPM_BUILD_ROOT
57
58 install -d $RPM_BUILD_ROOT%{_sysconfdir}
59 : >$RPM_BUILD_ROOT%{_sysconfdir}/floppy
60
61 %if %{with gtk}
62 install -d $RPM_BUILD_ROOT%{_desktopdir}
63 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_desktopdir}
64 %endif
65
66 %clean
67 rm -rf $RPM_BUILD_ROOT
68
69 %post
70 if [ ! -f %{_sysconfdir}/floppy ]; then
71         umask 022
72         %{_bindir}/floppy --createrc >%{_sysconfdir}/floppy 2>/dev/null || rm -f %{_sysconfdir}/floppy
73 fi
74
75 %files
76 %defattr(644,root,root,755)
77 %doc AUTHORS ChangeLog NEWS README 
78 %attr(755,root,root) %{_bindir}/floppy
79 %ghost %{_sysconfdir}/floppy
80 %{_mandir}/man8/floppy.8*
81
82 %if %{with gtk}
83 %files gtk
84 %defattr(644,root,root,755)
85 %attr(755,root,root) %{_bindir}/floppygtk
86 %{_desktopdir}/floppygtk.desktop
87 %endif
This page took 0.359277 seconds and 3 git commands to generate.