Fix vconf tools for sysroot.
authorRonan Le Martret <ronan@fridu.net>
Thu, 3 Jul 2014 15:28:33 +0000 (17:28 +0200)
committerRonan Le Martret <ronan@fridu.net>
Thu, 3 Jul 2014 15:28:33 +0000 (17:28 +0200)
Change-Id: Ib5769a991c6af4123636b57707318ec654e49369
Signed-off-by: Ronan Le Martret <ronan@fridu.net>
recipes-tizen/tizen-platform-config/tizen-platform-config-extraconf.inc
recipes-tizen/tizen-platform-wrapper/tizen-platform-wrapper-extraconf.inc
recipes-tizen/vconf/files/remove-dlog-for-native.patch [new file with mode: 0644]
recipes-tizen/vconf/vconf-extraconf.inc

index 5d4b615..c0b4955 100644 (file)
@@ -4,3 +4,12 @@ DEPENDS_append_class-target = " tizen-platform-wrapper-native"
 do_configure() {
  sed -i 's@wrappersrcdir=.*@wrappersrcdir=$(PKG_CONFIG_SYSROOT_DIR)$(datadir)@' ${S}/src/Makefile.am
 }
+
+do_install_append_class-native() {
+ sed -i "s@=/home@=${D}/home@g" ${D}${sysconfdir}/tizen-platform.conf
+ sed -i "s@=/opt@=${D}/opt@g" ${D}${sysconfdir}/tizen-platform.conf
+ sed -i "s@=/usr@=${D}/usr@g" ${D}${sysconfdir}/tizen-platform.conf
+ sed -i "s@=/etc@=${D}/etc@g" ${D}${sysconfdir}/tizen-platform.conf
+ sed -i "s@=/root@=${D}/root@g" ${D}${sysconfdir}/tizen-platform.conf
+}
+
index e69de29..317a9e0 100644 (file)
@@ -0,0 +1,4 @@
+do_configure_append_class-native() {
+ sed -i "s@\"/etc/tizen-platform.conf\"@\"${sysconfdir}/tizen-platform.conf\"@g" ${S}/src/tzplatform_config.c
+ sed -i "s@\"/etc/tizen-platform.conf\"@\"${sysconfdir}/tizen-platform.conf\"@g" ${S}/src/toolbox.c
+}
diff --git a/recipes-tizen/vconf/files/remove-dlog-for-native.patch b/recipes-tizen/vconf/files/remove-dlog-for-native.patch
new file mode 100644 (file)
index 0000000..b714d45
--- /dev/null
@@ -0,0 +1,25 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 28d168d..9dd6e52 100755
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -17,7 +17,7 @@ INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
+ INCLUDE(FindPkgConfig)
+ pkg_check_modules(glib_pkg REQUIRED gobject-2.0)
+-pkg_check_modules(pkgs REQUIRED glib-2.0 dlog libtzplatform-config vconf-internal-keys)
++pkg_check_modules(pkgs REQUIRED glib-2.0 libtzplatform-config vconf-internal-keys)
+ FOREACH(flag ${pkgs_CFLAGS})
+       SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}")
+diff --git a/include/vconf-log.h b/include/vconf-log.h
+index fa53102..f70d1e1 100755
+--- a/include/vconf-log.h
++++ b/include/vconf-log.h
+@@ -26,7 +26,6 @@
+ #include <unistd.h>
+ #include <stdlib.h>
+-#define VCONF_DLOG_OUT
+ /************** Error ***************/
+ #ifdef VCONF_SYSLOG_OUT
index e69de29..b3bf3e4 100644 (file)
@@ -0,0 +1,11 @@
+SRC_URI_append_class-native = " file://remove-dlog-for-native.patch"
+
+RDEPENDS_${PN}_remove_class-native = "eglibc-native"
+RDEPENDS_${PN}_remove_class-native = "systemd-native"
+DEPENDS_remove_class-native = "dlog-native"
+
+DEPENDS_class-target += "vconf-native"
+
+do_install_append_class-native() {
+ sed -i "s@source /etc/tizen-platform.conf@source ${sysconfdir}/tizen-platform.conf@g" ${D}${prefix}/bin/vconf-init
+}