summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorYaakov Selkowitz <yselkowitz@users.sourceforge.net>2011-02-17 04:20:58 -0600
committerYaakov Selkowitz <yselkowitz@users.sourceforge.net>2011-02-17 04:20:58 -0600
commit6b1fe9d630a7841c6a8f0de18af1cdc7d5593609 (patch)
treeea3a47af8a8cdd85633c01ac83687a034835b7d1
downloadcygwin-zlib-6b1fe9d630a7841c6a8f0de18af1cdc7d5593609.tar.gz
cygwin-zlib-6b1fe9d630a7841c6a8f0de18af1cdc7d5593609.tar.xz
cygwin-zlib-6b1fe9d630a7841c6a8f0de18af1cdc7d5593609.zip
Initial commit
-rw-r--r--cygwin-zlib.spec92
-rw-r--r--sources1
-rw-r--r--zlib-1.2.5-gentoo.patch12
3 files changed, 105 insertions, 0 deletions
diff --git a/cygwin-zlib.spec b/cygwin-zlib.spec
new file mode 100644
index 0000000..794f42a
--- /dev/null
+++ b/cygwin-zlib.spec
@@ -0,0 +1,92 @@
+%global __strip %{_cygwin_strip}
+%global __objdump %{_cygwin_objdump}
+%global _use_internal_dependency_generator 0
+%global __find_requires %{_cygwin_findrequires}
+%global __find_provides %{_cygwin_findprovides}
+%define __os_install_post %{_cygwin_os_install_post}
+
+Name: cygwin-zlib
+Version: 1.2.5
+Release: 1%{?dist}
+Summary: Cygwin zlib compression library
+
+License: zlib
+Group: Development/Libraries
+URL: http://www.zlib.net/
+Source0: http://www.zlib.net/zlib-%{version}.tar.gz
+# https://bugzilla.redhat.com/show_bug.cgi?id=591317
+Patch0: zlib-1.2.5-gentoo.patch
+BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+BuildArch: noarch
+
+BuildRequires: cygwin-filesystem
+BuildRequires: cygwin-gcc
+BuildRequires: cygwin-binutils
+
+
+%description
+Cygwin zlib compression library.
+
+%package static
+Summary: Static libraries for cygwin-zlib development.
+Group: Development/Libraries
+Requires: cygwin-zlib = %{version}-%{release}
+
+%description static
+The cygwin-zlib-static package contains static library for cygwin-zlib development.
+
+
+%prep
+%setup -q -n zlib-%{version}
+%patch0 -p1 -b .gentoo
+iconv -f windows-1252 -t utf-8 <ChangeLog >ChangeLog.tmp
+
+%build
+CC=%{_cygwin_cc} \
+CFLAGS="%{_cygwin_cflags}" \
+RANLIB=%{_cygwin_ranlib} \
+./configure
+
+make -f win32/Makefile.gcc \
+ CFLAGS="%{_cygwin_cflags}" \
+ PREFIX=%{_cygwin_target}- \
+ SHAREDLIB=cygz.dll \
+ IMPLIB=libz.dll.a \
+ all
+
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+make -f win32/Makefile.gcc \
+ BINARY_PATH=$RPM_BUILD_ROOT/%{_cygwin_bindir} \
+ INCLUDE_PATH=$RPM_BUILD_ROOT/%{_cygwin_includedir} \
+ LIBRARY_PATH=$RPM_BUILD_ROOT/%{_cygwin_libdir} \
+ SHARED_MODE=1 \
+ SHAREDLIB=cygz.dll \
+ IMPLIB=libz.dll.a \
+ install
+
+rm -rf $RPM_BUILD_ROOT/%{_cygwin_mandir}
+
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+
+%files
+%defattr(-,root,root,-)
+%{_cygwin_includedir}/zconf.h
+%{_cygwin_includedir}/zlib.h
+%{_cygwin_libdir}/libz.dll.a
+%{_cygwin_bindir}/cygz.dll
+
+
+%files static
+%defattr(-,root,root,-)
+%{_cygwin_libdir}/libz.a
+
+
+%changelog
+* Wed Feb 16 2011 Yaakov Selkowitz <cygwin-ports-general@lists.sourceforge.net> - 1.2.5-1
+- Initial RPM release, largely based on mingw32-zlib.
diff --git a/sources b/sources
new file mode 100644
index 0000000..c00fef0
--- /dev/null
+++ b/sources
@@ -0,0 +1 @@
+c735eab2d659a96e5a594c9e8541ad63 zlib-1.2.5.tar.gz
diff --git a/zlib-1.2.5-gentoo.patch b/zlib-1.2.5-gentoo.patch
new file mode 100644
index 0000000..82c7f39
--- /dev/null
+++ b/zlib-1.2.5-gentoo.patch
@@ -0,0 +1,12 @@
+diff -up zlib-1.2.5/zlib.h.pom zlib-1.2.5/zlib.h
+--- zlib-1.2.5/zlib.h.pom 2010-04-20 06:12:48.000000000 +0200
++++ zlib-1.2.5/zlib.h 2010-06-16 13:08:59.000000000 +0200
+@@ -1578,7 +1578,7 @@ ZEXTERN int ZEXPORT inflateBackInit_ OF(
+ # define gzoffset gzoffset64
+ # define adler32_combine adler32_combine64
+ # define crc32_combine crc32_combine64
+-# ifdef _LARGEFILE64_SOURCE
++# ifndef _LARGEFILE64_SOURCE
+ ZEXTERN gzFile ZEXPORT gzopen64 OF((const char *, const char *));
+ ZEXTERN z_off_t ZEXPORT gzseek64 OF((gzFile, z_off_t, int));
+ ZEXTERN z_off_t ZEXPORT gztell64 OF((gzFile));