From 4bd6711ffe7cb356d3c6f3b8c0e9c7d918d45234 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Thu, 1 Jan 1970 00:00:00 +0000 Subject: [PATCH] Added dlfcn to MinGW temporary repository. - Import into fedora-mingw temporary repository because there are packages which will depend on this. - Fix the version/release according to packaging guidelines. - Tidy up the spec file. - Use dos2unix and keep the timestamps. --- .hgignore | 1 + dlfcn/dlfcn_configure.patch | 62 ++++++++++++++++++++++++++++++++++ dlfcn/mingw32-dlfcn.spec | 82 +++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 145 insertions(+) create mode 100644 dlfcn/dlfcn_configure.patch create mode 100644 dlfcn/mingw32-dlfcn.spec diff --git a/.hgignore b/.hgignore index 0c89cb3..50aab3c 100644 --- a/.hgignore +++ b/.hgignore @@ -22,6 +22,7 @@ cairo/svgspacewar cairomm/cairomm-1.6.2.tar.gz curl/curl-7.18.2.tar.bz2 curl/test1 +dlfcn/dlfcn-win32-r11.tar.bz2 expat/expat-2.0.1.tar.gz flexdll/flexdll-0.11.tar.gz fontconfig/fontconfig-2.6.0.tar.gz diff --git a/dlfcn/dlfcn_configure.patch b/dlfcn/dlfcn_configure.patch new file mode 100644 index 0000000..8a0e7db --- /dev/null +++ b/dlfcn/dlfcn_configure.patch @@ -0,0 +1,62 @@ +diff -ruNp dlfcn-win32-r11/config.mak dlfcn-win32-r11.new/config.mak +--- dlfcn-win32-r11/config.mak 1969-12-31 21:00:00.000000000 -0300 ++++ dlfcn-win32-r11.new/config.mak 2009-01-02 12:08:15.000000000 -0200 +@@ -0,0 +1,9 @@ ++# Automatically generated by configure ++PREFIX=/usr/i686-pc-mingw32/sys-root/mingw ++libdir=/usr/i686-pc-mingw32/sys-root/mingw/lib ++incdir=/usr/i686-pc-mingw32/sys-root/mingw/include ++CC=i686-pc-mingw32-gcc ++BUILD_SHARED=yes ++BUILD_STATIC=yes ++BUILD_MSVC=no ++DO_STRIP=yes +diff -ruNp dlfcn-win32-r11/configure dlfcn-win32-r11.new/configure +--- dlfcn-win32-r11/configure 2009-01-02 11:54:38.000000000 -0200 ++++ dlfcn-win32-r11.new/configure 2009-01-02 12:35:30.000000000 -0200 +@@ -97,6 +97,45 @@ for opt do + --make=*) + make="$optval" + ;; ++ --enable-shared=*) ++ shared="$optval" ++ ;; ++ --enable-static=*) ++ static="$optval" ++ ;; ++ --enable-strip=*) ++ strip="$optval" ++ ;; ++ --cache-file=*) ++ ;; ++ --host=*) ++ ;; ++ --build=*) ++ ;; ++ --target=*) ++ ;; ++ --exec-prefix=*) ++ ;; ++ --bindir=*) ++ ;; ++ --sbindir=*) ++ ;; ++ --sysconfdir=*) ++ ;; ++ --datadir=*) ++ ;; ++ --includedir=*) ++ ;; ++ --libexecdir=*) ++ ;; ++ --localstatedir=*) ++ ;; ++ --sharedstatedir=*) ++ ;; ++ --mandir=*) ++ ;; ++ --infodir=*) ++ ;; + --enable-?*|--disable-?*) + eval `echo "$opt" | sed 's/--/action=/;s/-/ option=/;s/-/_/g'` + echo "$CMDLINE_SELECT" | grep -q "^ *$option\$" || die_unknown $opt diff --git a/dlfcn/mingw32-dlfcn.spec b/dlfcn/mingw32-dlfcn.spec new file mode 100644 index 0000000..25b77b3 --- /dev/null +++ b/dlfcn/mingw32-dlfcn.spec @@ -0,0 +1,82 @@ +%define __strip %{_mingw32_strip} +%define __objdump %{_mingw32_objdump} +%define _use_internal_dependency_generator 0 +%define __find_requires %{_mingw32_findrequires} +%define __find_provides %{_mingw32_findprovides} + +%define realname dlfcn-win32 + +%define alphatag r11 + +Name: mingw32-dlfcn +Version: 0.1 +Release: 0.2.%{alphatag}%{?dist} +Summary: Implements a wrapper for dlfcn (dlopen dlclose dlsym dlerror) + +License: LGPLv2+ +Group: Development/Libraries +URL: http://code.google.com/p/dlfcn-win32/ +Source0: http://dlfcn-win32.googlecode.com/files/%{realname}-%{alphatag}.tar.bz2 +BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) + +BuildArch: noarch + +BuildRequires: mingw32-filesystem >= 40 +BuildRequires: mingw32-gcc +BuildRequires: mingw32-binutils +BuildRequires: dos2unix + +Patch1: dlfcn_configure.patch + + +%description +This library implements a wrapper for dlfcn, as specified in POSIX and SUS, +around the dynamic link library functions found in the Windows API. + + +%prep +%setup -q -n %{realname}-%{alphatag} +dos2unix --keepdate configure +dos2unix --keepdate README +dos2unix --keepdate COPYING + +%patch1 -p1 + + +%build +%{_mingw32_configure} \ + --incdir=%{_mingw32_includedir} \ + --cc=i686-pc-mingw32-gcc \ + --enable-shared=yes \ + --enable-static=no \ + --enable-strip=i686-pc-mingw32-strip +make + + +%install +rm -rf $RPM_BUILD_ROOT +make DESTDIR=$RPM_BUILD_ROOT install + + +%clean +rm -rf $RPM_BUILD_ROOT + + +%files +%defattr(-,root,root) +%doc README COPYING +%{_mingw32_bindir}/libdl.dll +%{_mingw32_libdir}/libdl.dll.a +%{_mingw32_includedir}/dlfcn.h + + +%changelog +* Tue Jan 13 2009 Richard W.M. Jones - 0.1-0.2.r11 +- Import into fedora-mingw temporary repository because there are packages + which will depend on this. +- Fix the version/release according to packaging guidelines. +- Tidy up the spec file. +- Use dos2unix and keep the timestamps. + +* Fri Jan 02 2009 Itamar Reis Peixoto - r11-1 +- Initial RPM release. -- 1.8.3.1