2 # Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
8 # http://www.apache.org/licenses/LICENSE-2.0
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
21 PKG_CHECK_MODULES(WRT_BACKLIB_PKGS
32 ${WRT_BACKLIB_PKGS_INCLUDE_DIRS}
35 ADD_LIBRARY(${TARGET_BACKEND_LIB} SHARED
39 TARGET_LINK_LIBRARIES(${TARGET_BACKEND_LIB}
40 ${WRT_BACKLIB_PKGS_LIBRARIES}
43 SET_TARGET_PROPERTIES(${TARGET_BACKEND_LIB} PROPERTIES
44 LINK_FLAGS "-Wl,--as-needed -Wl,--hash-style=both -Wl"
47 INSTALL(TARGETS ${TARGET_BACKEND_LIB}
48 DESTINATION etc/package-manager/backendlib
49 PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE
54 set(SYMLINK_DEST "${CMAKE_INSTALL_PREFIX}/etc/package-manager")
57 ADD_CUSTOM_COMMAND(OUTPUT ${SYMLINK_DEST}/backend/wgt
59 ARGS -p ${SYMLINK_DEST}/backend
61 ARGS -sf ${CMAKE_INSTALL_PREFIX}/bin/${BACKEND} ${SYMLINK_DEST}/backend/wgt
64 ADD_CUSTOM_TARGET(test_symlinks ALL
65 DEPENDS ${SYMLINK_DEST}/backend/wgt