c2f1df3e6e3a9c452fcd41596fdb210518eb1b12
[fedora-mingw.git] / mingw64-filesystem / mingw64-filesystem.spec
1 %define debug_package %{nil}
2
3 Name:           mingw64-filesystem
4 Version:        2
5 Release:        1%{?dist}
6 Summary:        MinGW base filesystem and environment
7
8 Group:          Development/Libraries
9 License:        GPLv2+
10 URL:            http://hg.et.redhat.com/misc/fedora-mingw--devel/
11 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
12 BuildArch:      noarch
13
14 Source0:        COPYING
15 Source1:        macros.mingw64
16 Source2:        mingw64.sh
17 #Source3:        mingw64.csh
18 Source4:        mingw64-find-requires.sh
19 Source5:        mingw64-find-provides.sh
20 Source6:        mingw64-scripts.sh
21 Source7:        mingw64-rpmlint.config
22
23 Requires:       setup
24 Requires:       rpm
25 Requires:       rpmlint >= 0.85-2
26
27 BuildRequires:  rpmlint >= 0.85-2
28
29 # Note about 'Provides: mingw64(foo.dll)'
30 # ------------------------------------------------------------
31 #
32 # We want to be able to build & install mingw64 libraries without
33 # necessarily needing to install wine.  (And certainly not needing to
34 # install Windows!)  There is no requirement to have wine installed in
35 # order to use the mingw toolchain to develop software (ie. to
36 # compile more stuff on top of it), so why require that?
37 #
38 # So for expediency, this base package provides the "missing" DLLs
39 # from Windows.  Another way to do it would be to exclude these
40 # proprietary DLLs in our find-requires checking script - essentially
41 # it comes out the same either way.
42 #
43 #Provides:       mingw64(gdi32.dll)
44
45
46 %description
47 This package contains the base filesystem layout, RPM macros and
48 environment for all Fedora MinGW packages.
49
50 This environment is maintained by the Fedora MinGW SIG at:
51
52   http://fedoraproject.org/wiki/SIGs/MinGW
53
54
55 %prep
56 %setup -q -c -T
57 cp %{SOURCE0} COPYING
58 sed 's/@VERSION@/%{version}/' < %{SOURCE4} > mingw64-find-requires.sh
59
60
61 %build
62 # nothing
63
64
65 %install
66 rm -rf $RPM_BUILD_ROOT
67
68 mkdir -p $RPM_BUILD_ROOT
69
70 mkdir -p $RPM_BUILD_ROOT%{_libexecdir}
71 install -m 755 %{SOURCE6} $RPM_BUILD_ROOT%{_libexecdir}/mingw64-scripts
72
73 mkdir -p $RPM_BUILD_ROOT%{_bindir}
74 pushd $RPM_BUILD_ROOT%{_bindir}
75 for i in mingw64-configure mingw64-make; do
76   ln -s %{_libexecdir}/mingw64-scripts $i
77 done
78 popd
79
80 mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/profile.d
81 install -m 644 %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/profile.d/
82 #install -m 644 %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/profile.d/
83
84 mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rpm
85 install -m 644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/rpm/macros.mingw64
86
87 mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rpmlint
88 install -m 644 %{SOURCE7} $RPM_BUILD_ROOT%{_sysconfdir}/rpmlint/
89
90 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32
91
92 # GCC requires these directories, even though they contain links
93 # to binaries which are also installed in /usr/bin etc.  These
94 # contain Fedora native binaries.
95 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/bin
96 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/lib
97
98 # The MinGW system root which will contain Windows native binaries
99 # and Windows-specific header files, pkgconfig, etc.
100 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw
101 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw/bin
102 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw/include
103 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw/include/sys
104 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw/lib
105 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw/lib/pkgconfig
106
107 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw/share/aclocal
108
109 # We don't normally package manual pages and info files, except
110 # where those are not supplied by a Fedora native package.  So we
111 # need to create the directories.
112 #
113 # Note that some packages try to install stuff in
114 #   /usr/x86_64-pc-mingw32/sys-root/mingw/man and
115 #   /usr/x86_64-pc-mingw32/sys-root/mingw/doc
116 # but those are both packaging bugs.
117 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw/share
118 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw/share/doc
119 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw/share/info
120 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw/share/man
121 mkdir -p $RPM_BUILD_ROOT%{_prefix}/x86_64-pc-mingw32/sys-root/mingw/share/man/man{1,2,3,4,5,6,7,8,l,n}
122
123 # NB. NOT _libdir
124 mkdir -p $RPM_BUILD_ROOT/usr/lib/rpm
125 install -m 0755 mingw64-find-requires.sh $RPM_BUILD_ROOT/usr/lib/rpm
126 install -m 0755 %{SOURCE5} $RPM_BUILD_ROOT/usr/lib/rpm
127
128
129 %clean
130 rm -rf $RPM_BUILD_ROOT
131
132
133 %files
134 %defattr(-,root,root,-)
135 %doc COPYING
136 %config(noreplace) %{_sysconfdir}/rpm/macros.mingw64
137 %config(noreplace) %{_sysconfdir}/profile.d/mingw64.sh
138 #%config(noreplace) %{_sysconfdir}/profile.d/mingw64.csh
139 %config(noreplace) %{_sysconfdir}/rpmlint/mingw64-rpmlint.config
140 %{_bindir}/mingw64-configure
141 %{_bindir}/mingw64-make
142 %{_libexecdir}/mingw64-scripts
143 %{_prefix}/x86_64-pc-mingw32/
144 /usr/lib/rpm/mingw64-*
145
146
147 %changelog
148 * Wed Feb 11 2009 Richard W.M. Jones <rjones@redhat.com> - 2-1
149 - Start mingw64 development.
150
151 * Sun Feb  1 2009 Richard W.M. Jones <rjones@redhat.com> - 46-1
152 - Unset PKG_CONFIG_PATH because /usr/lib/rpm/macros sets it (Erik van
153   Pienbroek).
154
155 * Wed Jan 28 2009 Richard W.M. Jones <rjones@redhat.com> - 45-1
156 - Use PKG_CONFIG_LIBDIR instead of PKG_CONFIG_PATH so that native pkgconfig
157   is never searched.
158
159 * Mon Jan 26 2009 Richard W.M. Jones <rjones@redhat.com> - 44-1
160 - Install rpmlint overrides file to suppress some rpmlint warnings.
161
162 * Sat Jan 24 2009 Richard W.M. Jones <rjones@redhat.com> - 43-6
163 - Don't claim C++ compiler exists if it's not installed, as this
164   breaks autoconf and (in particular) libtool.
165
166 * Wed Jan 14 2009 Richard W.M. Jones <rjones@redhat.com> - 42-1
167 - Add pseudo-provides secur32.dll
168
169 * Wed Dec 17 2008 Levente Farkas <lfarkas@lfarkas.org> - 41-1
170 - Re-add mingw32-make
171
172 * Sat Dec  6 2008 Levente Farkas <lfarkas@lfarkas.org> - 40-2
173 - Rewrite mingw32-scripts to run in the current shell
174 - (Re-add mingw32-make) - Removed by RWMJ.
175 - Add mingw32-env to mingw32.sh
176
177 * Mon Nov 24 2008 Richard W.M. Jones <rjones@redhat.com> - 39-3
178 - Unify mingw32-filesystem packages from all three branches again, and test.
179 - Fix mingw32-scripts so it can handle extra parameters correctly.
180 - Remove mingw32-env & mingw32-make since neither of them actually work.
181
182 * Sun Nov 23 2008 Richard Jones <rjones@redhat.com> - 38-1
183 - Added mingw32(glut32.dll).
184
185 * Wed Nov 19 2008 Richard Jones <rjones@redhat.com> - 37-1
186 - Revert part of the 36-1 patch.  --build option to configure was wrong.
187
188 * Wed Nov 19 2008 Richard Jones <rjones@redhat.com> - 36-1
189 - Greatly improved macros (Levente Farkas).
190 - Added -mms-bitfields.
191
192 * Thu Nov 13 2008 Richard Jones <rjones@redhat.com> - 35-1
193 - Added mingw32(wldap32.dll) pseudo-provides.
194
195 * Wed Oct 29 2008 Richard Jones <rjones@redhat.com> - 34-1
196 - Set --prefix correctly.
197
198 * Wed Oct 29 2008 Richard Jones <rjones@redhat.com> - 33-1
199 - Remove mingw32.{sh,csh} which are unused.
200
201 * Mon Oct 27 2008 Richard Jones <rjones@redhat.com> - 32-1
202 - Add mingw32-configure script.
203
204 * Mon Oct 27 2008 Richard Jones <rjones@redhat.com> - 31-1
205 - Update the spec file with explanation of the 'Provides: mingw32(...)'
206   lines for Windows system DLLs.
207
208 * Mon Oct  6 2008 Richard Jones <rjones@redhat.com> - 30-1
209 - Added _mingw32_cxx.
210
211 * Thu Sep 25 2008 Richard Jones <rjones@redhat.com> - 29-1
212 - Added _mingw32_as, _mingw32_dlltool, _mingw32_windres.
213
214 * Wed Sep 24 2008 Richard W.M. Jones <rjones@redhat.com> - 27-1
215 - Begin the grand renaming of mingw -> mingw32.
216 - Added mingw32(mscoree.dll).
217
218 * Sun Sep 21 2008 Richard W.M. Jones <rjones@redhat.com> - 25-1
219 - Add shared aclocal directory.
220
221 * Sun Sep 21 2008 Richard W.M. Jones <rjones@redhat.com> - 24-1
222 - Remove mingw-defs, since no longer used.
223 - Add _mingw_infodir.
224
225 * Thu Sep 11 2008 Daniel P. Berrange <berrange@redhat.com> - 23-1
226 - Add macros for find-provides/requires scripts
227
228 * Wed Sep 10 2008 Richard W.M. Jones <rjones@redhat.com> - 22-1
229 - Windows provides OLE32.DLL.
230
231 * Wed Sep 10 2008 Richard W.M. Jones <rjones@redhat.com> - 21-1
232 - Allow '.' in dll names for find-requires
233 - Windows provides GDI32.DLL.
234
235 * Fri Sep  5 2008 Richard W.M. Jones <rjones@redhat.com> - 20-1
236 - On 64 bit install in /usr/lib/rpm always.
237
238 * Thu Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 19-1
239 - 'user32.dll' is provided by Windows.
240 - Allow '-' in DLL names.
241 - More accurate detection of DLLs in requires/provides scripts.
242
243 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 17-1
244 - Automatically add mingw-filesystem and mingw-runtime requires.
245 - Add --prefix to _mingw_configure macro.
246 - Three backslashes required on each continuation line in RPM macros.
247
248 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 14-1
249 - Fix path to mingw-find-requires/provides scripts.
250
251 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 12-1
252 - Put CFLAGS on a single line to avoid problems in some configure scripts.
253
254 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 10-1
255 - Provides certain base Windows DLLs (not literally).
256
257 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 9-1
258 - Include RPM dependency generators and definitions.
259
260 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 4-1
261 - Add _mingw_cc/cflags/etc. and _mingw_configure macros.
262
263 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 3-1
264 - Add _mingw_host macro.
265
266 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 2-1
267 - Add _mingw_sysroot macro.
268 - Add _mingw_target macro.
269
270 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 1-1
271 - Basic filesystem layout.