]>
Commit | Line | Data |
---|---|---|
080a6f77 | 1 | %define _name fltk |
2 | %define _snap r6671 | |
3 | %define _version 2.0 | |
8b9f0de0 | 4 | # Conditional build: |
5 | %bcond_with cairo # without cairo support | |
6 | # | |
080a6f77 | 7 | Summary: Fast Light Tool Kit 2.x |
8 | Summary(pl.UTF-8): FLTK - "lekki" X11 toolkit wersja 2.x | |
11cd401e | 9 | Summary(pt_BR.UTF-8): Interface gráfica em C++ para X, OpenGL e Windows |
080a6f77 | 10 | Name: fltk2 |
11 | Version: 2.0.%{_snap} | |
f01d17cc | 12 | Release: 0.1 |
080a6f77 | 13 | License: LGPL with amendments (see COPYING) |
14 | Group: X11/Libraries | |
11cd401e | 15 | Source0: http://ftp.easysw.com/pub/fltk/snapshots/%{_name}-%{_version}.x-%{_snap}.tar.bz2 |
080a6f77 | 16 | # Source0-md5: 6bcef5fd51eb3bc4dd0702f3ae6da6ba |
ec5cf292 | 17 | Patch0: %{name}-rpath.patch |
18 | Patch1: %{name}-soname.patch | |
080a6f77 | 19 | URL: http://www.fltk.org/ |
20 | BuildRequires: autoconf | |
8b9f0de0 | 21 | # don't build with cairo support if you're planning to use fltk2 with |
22 | # dillo 2.x | |
d21c2632 | 23 | BuildRequires: Mesa-libGLU-devel |
8b9f0de0 | 24 | %{?with_cairo:BuildRequires: cairo-devel} |
080a6f77 | 25 | BuildRequires: libstdc++-devel |
26 | BuildRequires: rpmbuild(macros) >= 1.315 | |
27 | BuildRequires: xorg-lib-libX11-devel | |
28 | BuildRequires: xorg-lib-libXext-devel | |
29 | BuildRequires: xorg-lib-libXinerama-devel | |
30 | BuildRequires: xorg-util-makedepend | |
31 | Obsoletes: fltk | |
32 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
883114b6 | 33 | |
080a6f77 | 34 | %description |
35 | The Fast Light Tool Kit ("FLTK", pronounced "fulltick") is a LGPL'd | |
36 | C++ graphical user interface toolkit for X (UNIX(r)), OpenGL(r), and | |
37 | Microsoft(r) Windows(r) NT 4.0, 95, or 98. It was originally developed | |
38 | by Mr. Bill Spitzak and is currently maintained by a small group of | |
39 | developers across the world with a central repository in the US. This | |
40 | is a development version of incoming 2.x release. | |
41 | ||
42 | %description -l pl.UTF-8 | |
43 | Fast Light Tool Kit ("FLTK", wymawiane "fultik"), jest rozprowadzanym | |
44 | na licencji LGPL narzędziem do tworzenia graficznych interfejsów | |
45 | użytkownika w C++ dla X (UNIX(r)), OpenGL(r), i Microsoft(r) | |
46 | Windows(r) NT 4.0, 95, oraz 98. Jego pierwotnym autorem jest pan Bill | |
47 | Spitzak; obecnie pakiet jest rozwijany przez niewielką grupę | |
48 | deweloperów z różnych stron świata (centralne repozytorium znajduje | |
49 | się w USA). To jest rozwojowa wersja FLTK nadchodzącej wersji 2.x. | |
50 | ||
51 | %description -l pt_BR.UTF-8 | |
52 | A Fast Light Tool Kit ("FLTK", pronuncia-se "fulltick") é uma | |
53 | ferramenta e interface gráfica feita em C++ para desenvolver | |
54 | aplicativos para o X, OpenGL e Windows. | |
55 | ||
56 | %package devel | |
57 | Summary: FLTK2 development files | |
58 | Summary(pl.UTF-8): Narzędzia programistyczne dla FLTK2 | |
59 | Summary(pt_BR.UTF-8): Arquivos de inclusão para o FLTK2 | |
60 | Group: X11/Development/Libraries | |
61 | Requires: %{name} = %{version}-%{release} | |
62 | Requires: libstdc++-devel | |
63 | Obsoletes: fltk-devel | |
64 | ||
65 | %description devel | |
66 | FLTK 2.x development files. | |
67 | ||
68 | %description devel -l pl.UTF-8 | |
69 | Narzędzia programistyczne dla FLTK 2.x. | |
70 | ||
71 | %description devel -l pt_BR.UTF-8 | |
72 | Arquivos de inclusão para o FLTK 2.x. | |
73 | ||
74 | %package static | |
75 | Summary: FLTK2 static library | |
76 | Summary(pl.UTF-8): Biblioteka FLTK2 konsolidowana statycznie | |
77 | Summary(pt_BR.UTF-8): Bibliotecas estáticas para o FLTK2 | |
78 | Group: X11/Development/Libraries | |
79 | Requires: %{name}-devel = %{version}-%{release} | |
80 | ||
81 | %description static | |
82 | FLTK2 static library. | |
83 | ||
84 | %description static -l pl.UTF-8 | |
85 | Biblioteka FLTK2 konsolidowana statycznie. | |
86 | ||
87 | %description static -l pt_BR.UTF-8 | |
88 | Bibliotecas estáticas para o FLTK2. | |
89 | ||
90 | %prep | |
91 | %setup -q -n %{_name}-%{_version}.x-%{_snap} | |
ec5cf292 | 92 | %patch0 -p0 |
93 | %patch1 -p0 | |
080a6f77 | 94 | |
95 | %build | |
96 | %{__sed} -i -e '/fltk2-config/s/^\t/\t$(DESTDIR)/' fluid/Makefile | |
97 | %{__autoconf} | |
98 | %configure \ | |
8b9f0de0 | 99 | --%{?with_cairo:en}%{!?with_cairo:dis}able-cairo \ |
080a6f77 | 100 | --enable-shared \ |
101 | --enable-threads \ | |
102 | --enable-xinerama \ | |
103 | --with-x \ | |
104 | --enable-xft \ | |
105 | --with-optim="%{rpmcxxflags}" | |
106 | ||
107 | %{__make} | |
108 | ||
109 | %install | |
110 | rm -rf $RPM_BUILD_ROOT | |
11cd401e | 111 | |
080a6f77 | 112 | install -d $RPM_BUILD_ROOT%{_mandir}/man{1,3} |
113 | ||
114 | %{__make} install \ | |
115 | prefix=$RPM_BUILD_ROOT%{_prefix} \ | |
116 | DESTDIR=$RPM_BUILD_ROOT | |
117 | ||
118 | # install man by hand | |
11cd401e | 119 | %{__mv} documentation/fltk2-config.man $RPM_BUILD_ROOT%{_mandir}/man1/fltk2-config.1 |
080a6f77 | 120 | %{__mv} documentation/fluid.man $RPM_BUILD_ROOT%{_mandir}/man1/fluid.1 |
121 | %{__mv} documentation/fltk.man $RPM_BUILD_ROOT%{_mandir}/man3/fltk.3 | |
122 | ||
f01d17cc | 123 | # broken so linking, the idea stolen from |
124 | # https://bugzilla.redhat.com/show_bug.cgi?id=477683 | |
125 | ln -fs libfltk2.so.2.0 $RPM_BUILD_ROOT%{_libdir}/libfltk2.so | |
126 | ln -fs libfltk2_gl.so.2.0 $RPM_BUILD_ROOT%{_libdir}/libfltk2_gl.so | |
127 | ln -fs libfltk2_glut.so.2.0 $RPM_BUILD_ROOT%{_libdir}/libfltk2_glut.so | |
128 | ln -fs libfltk2_images.so.2.0 $RPM_BUILD_ROOT%{_libdir}/libfltk2_images.so | |
129 | ||
080a6f77 | 130 | %clean |
131 | rm -rf $RPM_BUILD_ROOT | |
132 | ||
133 | %post -p /sbin/ldconfig | |
134 | %postun -p /sbin/ldconfig | |
135 | ||
136 | %files | |
137 | %defattr(644,root,root,755) | |
138 | %doc CHANGES COPYING CREDITS README | |
139 | %attr(755,root,root) %{_libdir}/libfltk2.so.*.* | |
140 | %attr(755,root,root) %{_libdir}/libfltk2_gl.so.*.* | |
141 | %attr(755,root,root) %{_libdir}/libfltk2_glut.so.*.* | |
142 | %attr(755,root,root) %{_libdir}/libfltk2_images.so.*.* | |
143 | ||
144 | %files devel | |
145 | %defattr(644,root,root,755) | |
146 | %doc documentation/*.{html,gif,jpg} | |
147 | %attr(755,root,root) %{_bindir}/fltk2-config | |
148 | %attr(755,root,root) %{_bindir}/fluid2 | |
f01d17cc | 149 | %attr(755,root,root) %ghost %{_libdir}/libfltk2.so |
150 | %attr(755,root,root) %ghost %{_libdir}/libfltk2_gl.so | |
151 | %attr(755,root,root) %ghost %{_libdir}/libfltk2_glut.so | |
152 | %attr(755,root,root) %ghost %{_libdir}/libfltk2_images.so | |
080a6f77 | 153 | %dir %{_includedir}/fltk |
154 | %dir %{_includedir}/fltk/compat | |
155 | %dir %{_includedir}/fltk/compat/FL | |
156 | %{_includedir}/fltk/*.[hr] | |
157 | %{_includedir}/fltk/compat/FL/*.[hH] | |
158 | %{_mandir}/man1/fltk2-config.1* | |
159 | %{_mandir}/man1/fluid.1* | |
160 | %{_mandir}/man3/fltk.3* | |
161 | ||
162 | %files static | |
163 | %defattr(644,root,root,755) | |
164 | %{_libdir}/libfltk2.a | |
165 | %{_libdir}/libfltk2_gl.a | |
166 | %{_libdir}/libfltk2_glut.a | |
167 | %{_libdir}/libfltk2_images.a |