aboutsummaryrefslogtreecommitdiff
path: root/tools/depends/target/libnfs/001-fix-cmake-build.patch
blob: fe59fffca5f8d845ffa616bb8777344762b83519 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
--- a/cmake/Macros.cmake
+++ b/cmake/Macros.cmake
@@ -12,4 +12,12 @@
   add_library(${name} OBJECT ${SOURCES} ${HEADERS})
   target_include_directories(${name} PUBLIC $<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>)
   set(CORE_LIBRARIES "${name};${CORE_LIBRARIES}" CACHE INTERNAL "")
+
+  # no need to install core libs if we build shared library
+  if(NOT BUILD_SHARED_LIBS)
+    install(TARGETS ${name} EXPORT libnfs
+            RUNTIME DESTINATION bin
+            ARCHIVE DESTINATION lib
+            LIBRARY DESTINATION lib)
+  endif()
 endfunction()
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -116,6 +116,7 @@
 
 install(FILES mount/libnfs-raw-mount.h
               nfs/libnfs-raw-nfs.h
+              nfs4/libnfs-raw-nfs4.h
               nlm/libnfs-raw-nlm.h
               nsm/libnfs-raw-nsm.h
               portmap/libnfs-raw-portmap.h