- Add htonl() and friends declarations on non-x86 arches

- Rebuilt with fixed libxdiff for big endian arches
This commit is contained in:
Dan Horák 2013-06-19 11:20:15 +02:00
parent d3af3a530b
commit 5ba73998c3
2 changed files with 23 additions and 1 deletions

View File

@ -0,0 +1,14 @@
diff -up libgit2-0.18.0/src/bswap.h.non-x86 libgit2-0.18.0/src/bswap.h
--- libgit2-0.18.0/src/bswap.h.non-x86 2013-06-19 10:01:31.000000000 +0200
+++ libgit2-0.18.0/src/bswap.h 2013-06-19 10:01:50.000000000 +0200
@@ -76,6 +76,10 @@ GIT_INLINE(uint16_t) default_swab16(uint
#define bswap32(x) _byteswap_ulong(x)
#define bswap16(x) _byteswap_ushort(x)
+#else
+
+#include <arpa/inet.h>
+
#endif
#ifdef bswap32

View File

@ -1,6 +1,6 @@
Name: libgit2
Version: 0.18.0
Release: 4%{?dist}
Release: 5%{?dist}
Summary: A C implementation of the Git core methods as a library
License: GPLv2 with exceptions
@ -13,6 +13,9 @@ Patch0: libgit2-0.18.0-http.patch
# Use system libxdiff
Patch1: libgit2-0.18.0-system-libxdiff.patch
# Add htonl() and friends declarations on non-x86 arches
Patch2: libgit2-0.18.0-non-x86.patch
BuildRequires: cmake >= 2.6
BuildRequires: http-parser-devel
BuildRequires: libxdiff-devel
@ -44,6 +47,7 @@ find examples -name ".gitignore" -delete
# Apply patches
%patch0 -p1
%patch1 -p1 -b .system-libxdiff
%patch2 -p1 -b .non-x86
# Fix pkgconfig generation
sed -i 's|@CMAKE_INSTALL_PREFIX@/||' libgit2.pc.in
@ -86,6 +90,10 @@ make install DESTDIR=%{buildroot}
%changelog
* Wed Jun 19 2013 Dan Horák <dan[at]danny.cz> - 0.18.0-5
- Add htonl() and friends declarations on non-x86 arches
- Rebuilt with fixed libxdiff for big endian arches
* Thu May 30 2013 Veeti Paananen <veeti.paananen@rojekti.fi> - 0.18.0-4
- Update the http-parser patch
- Skip tests that require network connectivity