- Allow '.' in dll names for find-requires
[fedora-mingw.git] / filesystem / mingw-filesystem.spec
1 %define debug_package %{nil}
2
3 Name:           mingw-filesystem
4 Version:        21
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:        mingw-COPYING
15 Source1:        mingw-macros.mingw
16 Source2:        mingw.sh
17 Source3:        mingw.csh
18 Source4:        mingw-find-requires.sh
19 Source5:        mingw-find-provides.sh
20 Source6:        mingw-defs
21
22 Requires:       setup
23 Requires:       rpm
24
25 # These are actually provided by Windows itself, or Wine.
26 Provides:       mingw(msvcrt.dll)
27 Provides:       mingw(kernel32.dll)
28 Provides:       mingw(user32.dll)
29 Provides:       mingw(gdi32.dll)
30
31
32 %description
33 This package contains the base filesystem layout, RPM macros and
34 environment for all Fedora MinGW packages.
35
36 This environment is maintained by the Fedora MinGW SIG at:
37
38   http://fedoraproject.org/wiki/SIGs/MinGW
39
40
41 %prep
42 %setup -q -c -T
43 cp %{SOURCE0} COPYING
44 sed 's/@VERSION@/%{version}/' < %{SOURCE4} > mingw-find-requires.sh
45
46
47 %build
48 # nothing
49
50
51 %install
52 rm -rf $RPM_BUILD_ROOT
53
54 mkdir -p $RPM_BUILD_ROOT
55
56 mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/profile.d
57 install -m 644 %{SOURCE2} %{SOURCE3} $RPM_BUILD_ROOT%{_sysconfdir}/profile.d/
58
59 mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rpm
60 install -m 644 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/rpm/macros.mingw
61
62 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32
63
64 # GCC requires these directories, even though they contain links
65 # to binaries which are also installed in /usr/bin etc.  These
66 # contain Fedora native binaries.
67 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/bin
68 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/lib
69
70 # The MinGW system root which will contain Windows native binaries
71 # and Windows-specific header files, man pages, pkgconfig, etc.
72 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw
73 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw/bin
74 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw/doc
75 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw/include
76 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw/include/sys
77 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw/lib
78 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw/lib/pkgconfig
79 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw/share
80 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw/share/doc
81 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw/share/man
82 mkdir -p $RPM_BUILD_ROOT%{_prefix}/i686-pc-mingw32/sys-root/mingw/share/man/man{1,2,3,4,5,6,7,8,l,n}
83
84 # Note that some packages try to install in
85 # /usr/i686-pc-mingw32/sys-root/mingw/man and
86 # /usr/i686-pc-mingw32/sys-root/mingw/doc
87 # but these are both packaging bugs.
88
89 # NB. NOT libdir
90 mkdir -p $RPM_BUILD_ROOT/usr/lib/rpm
91 install -m 0755 mingw-find-requires.sh $RPM_BUILD_ROOT/usr/lib/rpm
92 install -m 0755 %{SOURCE5} $RPM_BUILD_ROOT/usr/lib/rpm
93 install -m 0644 %{SOURCE6} $RPM_BUILD_ROOT/usr/lib/rpm
94
95
96 %clean
97 rm -rf $RPM_BUILD_ROOT
98
99
100 %files
101 %defattr(-,root,root,-)
102 %doc COPYING
103 %config(noreplace) %{_sysconfdir}/rpm/macros.mingw
104 %config(noreplace) %{_sysconfdir}/profile.d/mingw.sh
105 %config(noreplace) %{_sysconfdir}/profile.d/mingw.csh
106 %{_prefix}/i686-pc-mingw32/
107 /usr/lib/rpm/mingw-*
108
109
110 %changelog
111 * Wed Sep 10 2008 Richard W.M. Jones <rjones@redhat.com> - 21-1
112 - Allow '.' in dll names for find-requires
113 - Windows provides GDI32.DLL.
114
115 * Fri Sep  5 2008 Richard W.M. Jones <rjones@redhat.com> - 20-1
116 - On 64 bit install in /usr/lib/rpm always.
117
118 * Thu Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 19-1
119 - 'user32.dll' is provided by Windows.
120 - Allow '-' in DLL names.
121 - More accurate detection of DLLs in requires/provides scripts.
122
123 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 17-1
124 - Automatically add mingw-filesystem and mingw-runtime requires.
125 - Add --prefix to _mingw_configure macro.
126 - Three backslashes required on each continuation line in RPM macros.
127
128 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 14-1
129 - Fix path to mingw-find-requires/provides scripts.
130
131 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 12-1
132 - Put CFLAGS on a single line to avoid problems in some configure scripts.
133
134 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 10-1
135 - Provides certain base Windows DLLs (not literally).
136
137 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 9-1
138 - Include RPM dependency generators and definitions.
139
140 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 4-1
141 - Add _mingw_cc/cflags/etc. and _mingw_configure macros.
142
143 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 3-1
144 - Add _mingw_host macro.
145
146 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 2-1
147 - Add _mingw_sysroot macro.
148 - Add _mingw_target macro.
149
150 * Mon Sep  4 2008 Richard W.M. Jones <rjones@redhat.com> - 1-1
151 - Basic filesystem layout.