File: 0002-build-Install-headers-to-system.patch

package info (click to toggle)
iotjs 1.0%2B715-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, sid
  • size: 36,416 kB
  • sloc: ansic: 241,611; javascript: 58,534; python: 8,269; sh: 7,889; cpp: 2,526; makefile: 1,744; perl: 1,554; tcl: 862; xml: 464; asm: 97
file content (43 lines) | stat: -rw-r--r-- 1,774 bytes parent folder | download
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
From: Philippe Coval <rzr@users.sf.net>
Date: Thu, 20 Jun 2019 14:08:55 +0200
Subject: build: Install static lib

installing the static lib will also install headers (Fixes: #1896).

This is useful for debian's iotjs-dev package

Change-Id: Ib9f6cb50631f4cdfeb308108f91ed28e7d204dc4
Forwarded: https://github.com/jerryscript-project/iotjs/pull/1948
Origin: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master
Bug: https://github.com/jerryscript-project/iotjs/issues/1945
Bug-Debian: https://bugs.debian.org/957364
Relate-to: https://github.com/jerryscript-project/iotjs/pull/1896
Gbp-Pq: Name 0002-build-Install-headers-to-system.patch
Last-Update: 2020-10-16
IoT.js-DCO-1.0-Signed-off-by: Philippe Coval rzr@users.sf.net
---
 cmake/iotjs.cmake | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/cmake/iotjs.cmake b/cmake/iotjs.cmake
index 2216f12..5c1b8db 100644
--- a/cmake/iotjs.cmake
+++ b/cmake/iotjs.cmake
@@ -580,16 +580,10 @@ if(NOT BUILD_LIB_ONLY)
   )
   target_include_directories(${TARGET_IOTJS} PRIVATE ${IOTJS_INCLUDE_DIRS})
   target_link_libraries(${TARGET_IOTJS} ${TARGET_LIB_IOTJS})
-  install(TARGETS ${TARGET_IOTJS}
+  install(TARGETS ${TARGET_IOTJS} ${TARGET_LIB_IOTJS}
           RUNTIME DESTINATION "${INSTALL_PREFIX}/bin"
           LIBRARY DESTINATION "${INSTALL_PREFIX}/lib"
           PUBLIC_HEADER DESTINATION "${INSTALL_PREFIX}/include/iotjs")
-  if(CREATE_SHARED_LIB)
-    install(TARGETS ${TARGET_LIB_IOTJS}
-            RUNTIME DESTINATION "${INSTALL_PREFIX}/bin"
-            LIBRARY DESTINATION "${INSTALL_PREFIX}/lib"
-            PUBLIC_HEADER DESTINATION "${INSTALL_PREFIX}/include/iotjs")
-  endif()
 else()
   install(TARGETS ${TARGET_LIB_IOTJS} DESTINATION ${LIB_INSTALL_DIR})
 endif()