Added dlfcn to MinGW temporary repository.
[fedora-mingw.git] / dlfcn / mingw32-dlfcn.spec
1 %define __strip %{_mingw32_strip}
2 %define __objdump %{_mingw32_objdump}
3 %define _use_internal_dependency_generator 0
4 %define __find_requires %{_mingw32_findrequires}
5 %define __find_provides %{_mingw32_findprovides}
6
7 %define realname dlfcn-win32
8
9 %define alphatag r11
10
11 Name:          mingw32-dlfcn
12 Version:       0.1
13 Release:       0.2.%{alphatag}%{?dist}
14 Summary:       Implements a wrapper for dlfcn (dlopen dlclose dlsym dlerror)
15
16 License:       LGPLv2+
17 Group:         Development/Libraries
18 URL:           http://code.google.com/p/dlfcn-win32/
19 Source0:       http://dlfcn-win32.googlecode.com/files/%{realname}-%{alphatag}.tar.bz2
20 BuildRoot:     %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
21
22 BuildArch:     noarch
23
24 BuildRequires: mingw32-filesystem >= 40
25 BuildRequires: mingw32-gcc
26 BuildRequires: mingw32-binutils
27 BuildRequires: dos2unix
28
29 Patch1:        dlfcn_configure.patch
30
31
32 %description
33 This library implements a wrapper for dlfcn, as specified in POSIX and SUS,
34 around the dynamic link library functions found in the Windows API.
35
36
37 %prep
38 %setup -q -n %{realname}-%{alphatag}
39 dos2unix --keepdate configure
40 dos2unix --keepdate README
41 dos2unix --keepdate COPYING
42
43 %patch1 -p1
44
45
46 %build
47 %{_mingw32_configure} \
48   --incdir=%{_mingw32_includedir} \
49   --cc=i686-pc-mingw32-gcc \
50   --enable-shared=yes \
51   --enable-static=no \
52   --enable-strip=i686-pc-mingw32-strip
53 make 
54
55
56 %install
57 rm -rf $RPM_BUILD_ROOT
58 make DESTDIR=$RPM_BUILD_ROOT install
59
60
61 %clean
62 rm -rf $RPM_BUILD_ROOT
63
64
65 %files
66 %defattr(-,root,root)
67 %doc README COPYING
68 %{_mingw32_bindir}/libdl.dll
69 %{_mingw32_libdir}/libdl.dll.a
70 %{_mingw32_includedir}/dlfcn.h
71
72
73 %changelog
74 * Tue Jan 13 2009 Richard W.M. Jones <rjones@redhat.com> - 0.1-0.2.r11
75 - Import into fedora-mingw temporary repository because there are packages
76   which will depend on this.
77 - Fix the version/release according to packaging guidelines.
78 - Tidy up the spec file.
79 - Use dos2unix and keep the timestamps.
80
81 * Fri Jan 02 2009 Itamar Reis Peixoto <itamar@ispbrasil.com.br> - r11-1
82 - Initial RPM release.