From ea76fb270d40e11f3c4b02671babc47ffe836646 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Mon, 31 Jan 2011 19:32:58 +0100 Subject: [PATCH] make libubus a dynamic library --- .gitignore | 2 ++ CMakeLists.txt | 4 +++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 210271d..8bd0afc 100644 --- a/.gitignore +++ b/.gitignore @@ -3,6 +3,8 @@ CMakeCache.txt CMakeFiles *.cmake *.a +*.so +*.dylib ubus.sock listener ubusd diff --git a/CMakeLists.txt b/CMakeLists.txt index 3114aa9..e579297 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2,7 +2,9 @@ cmake_minimum_required(VERSION 2.8) PROJECT(ubus C) ADD_DEFINITIONS(-Os -Wall -Werror --std=gnu99 -g3) -ADD_LIBRARY(ubus STATIC libubus.c) + +ADD_LIBRARY(ubus SHARED libubus.c) +TARGET_LINK_LIBRARIES(ubus ubox) ADD_EXECUTABLE(ubusd ubusd.c ubusd_id.c ubusd_obj.c ubusd_proto.c) TARGET_LINK_LIBRARIES(ubusd ubox) -- 2.11.0