1 |
radhermit 11/06/30 22:06:33 |
2 |
|
3 |
Modified: libgit2-0.13.0-system-zlib.patch |
4 |
Log: |
5 |
Use system zlib on all non-Windows systems if available. |
6 |
|
7 |
(Portage version: 2.2.0_alpha41/cvs/Linux x86_64) |
8 |
|
9 |
Revision Changes Path |
10 |
1.2 dev-libs/libgit2/files/libgit2-0.13.0-system-zlib.patch |
11 |
|
12 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/libgit2/files/libgit2-0.13.0-system-zlib.patch?rev=1.2&view=markup |
13 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/libgit2/files/libgit2-0.13.0-system-zlib.patch?rev=1.2&content-type=text/plain |
14 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/libgit2/files/libgit2-0.13.0-system-zlib.patch?r1=1.1&r2=1.2 |
15 |
|
16 |
Index: libgit2-0.13.0-system-zlib.patch |
17 |
=================================================================== |
18 |
RCS file: /var/cvsroot/gentoo-x86/dev-libs/libgit2/files/libgit2-0.13.0-system-zlib.patch,v |
19 |
retrieving revision 1.1 |
20 |
retrieving revision 1.2 |
21 |
diff -u -r1.1 -r1.2 |
22 |
--- libgit2-0.13.0-system-zlib.patch 30 Jun 2011 21:02:39 -0000 1.1 |
23 |
+++ libgit2-0.13.0-system-zlib.patch 30 Jun 2011 22:06:33 -0000 1.2 |
24 |
@@ -1,22 +1,26 @@ |
25 |
--- libgit2-0.13.0/CMakeLists.txt.orig |
26 |
+++ libgit2-0.13.0/CMakeLists.txt |
27 |
-@@ -22,7 +22,14 @@ |
28 |
+@@ -22,7 +22,18 @@ |
29 |
SET(LIBGIT2_VERSION_STRING "${LIBGIT2_VERSION_MAJOR}.${LIBGIT2_VERSION_MINOR}.${LIBGIT2_VERSION_REV}") |
30 |
|
31 |
# Find required dependencies |
32 |
-INCLUDE_DIRECTORIES(deps/zlib src include) |
33 |
+INCLUDE_DIRECTORIES(src include) |
34 |
-+IF (${CMAKE_SYSTEM_NAME} MATCHES "Linux") |
35 |
-+ find_package(ZLIB REQUIRED) |
36 |
-+ INCLUDE_DIRECTORIES( ${ZLIB_INCLUDE_DIRS} ) |
37 |
-+ELSE (${CMAKE_SYSTEM_NAME} MATCHES "Linux") |
38 |
++IF (NOT WIN32) |
39 |
++ find_package(ZLIB) |
40 |
++ENDIF() |
41 |
++ |
42 |
++IF (ZLIB_FOUND) |
43 |
++ INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIRS}) |
44 |
++ LINK_LIBRARIES(${ZLIB_LIBRARIES}) |
45 |
++ELSE (ZLIB_FOUND) |
46 |
+ INCLUDE_DIRECTORIES(deps/zlib) |
47 |
+ FILE(GLOB SRC_ZLIB deps/zlib/*.c) |
48 |
+ENDIF() |
49 |
|
50 |
# Installation paths |
51 |
SET(INSTALL_BIN bin CACHE PATH "Where to install binaries to.") |
52 |
-@@ -57,7 +64,6 @@ |
53 |
+@@ -57,7 +68,6 @@ |
54 |
|
55 |
# Collect sourcefiles |
56 |
FILE(GLOB SRC src/*.c src/backends/*.c) |
57 |
@@ -24,21 +28,3 @@ |
58 |
FILE(GLOB SRC_SHA1 src/block-sha1/*.c) |
59 |
FILE(GLOB SRC_PLAT src/unix/*.c) |
60 |
FILE(GLOB SRC_H include/git2/*.h) |
61 |
-@@ -70,7 +76,7 @@ |
62 |
- |
63 |
- # Compile and link libgit2 |
64 |
- ADD_LIBRARY(git2 ${SRC} ${SRC_PLAT} ${SRC_SHA1} ${SRC_ZLIB}) |
65 |
--TARGET_LINK_LIBRARIES(git2 ${CMAKE_THREAD_LIBS_INIT}) |
66 |
-+TARGET_LINK_LIBRARIES(git2 ${CMAKE_THREAD_LIBS_INIT} ${ZLIB_LIBRARIES}) |
67 |
- SET_TARGET_PROPERTIES(git2 PROPERTIES VERSION ${LIBGIT2_VERSION_STRING}) |
68 |
- SET_TARGET_PROPERTIES(git2 PROPERTIES SOVERSION ${LIBGIT2_VERSION_MAJOR}) |
69 |
- |
70 |
-@@ -92,7 +98,7 @@ |
71 |
- FILE(GLOB SRC_TEST tests/t??-*.c) |
72 |
- |
73 |
- ADD_EXECUTABLE(libgit2_test tests/test_main.c tests/test_lib.c tests/test_helpers.c ${SRC} ${SRC_PLAT} ${SRC_SHA1} ${SRC_TEST} ${SRC_ZLIB}) |
74 |
-- TARGET_LINK_LIBRARIES(libgit2_test ${CMAKE_THREAD_LIBS_INIT}) |
75 |
-+ TARGET_LINK_LIBRARIES(libgit2_test ${CMAKE_THREAD_LIBS_INIT} ${ZLIB_LIBRARIES}) |
76 |
- |
77 |
- ENABLE_TESTING() |
78 |
- ADD_TEST(libgit2_test libgit2_test) |