build: fix emulator-skin.jar local DIBS build. 33/23533/4
authorKitae Kim <kt920.kim@samsung.com>
Fri, 27 Jun 2014 08:40:28 +0000 (17:40 +0900)
committerSeokYeon Hwang <syeon.hwang@samsung.com>
Mon, 30 Jun 2014 04:50:05 +0000 (13:50 +0900)
The location of swt.jar was not specified properly in the build.xml
when using local DIBS.

Change-Id: If653bcbebdcc93b8208e55d30d270a50f28bed48
Signed-off-by: Kitae Kim <kt920.kim@samsung.com>
Signed-off-by: SeokYeon Hwang <syeon.hwang@samsung.com>
tizen/src/Makefile
tizen/src/skin/client/build.xml

index 1e1e65002493b6c55002f509eb0378e815ae11ad..ba88b34ac058f72041511939b6ab52962bfb1144 100644 (file)
@@ -2,6 +2,7 @@ EMUL_DIR=../emulator
 DIBS_X86_DIR=../x86
 DIBS_ARM_DIR=../arm
 DIBS_COMMON_DIR=../common
+DIBS_SWT_DIR=-Dclasspath.dibs=$(ROOTDIR)/tools/emulator/bin
 
 ifndef TIZEN_SDK_DEV_PATH
 TIZEN_SDK_DEV_PATH=${HOME}/tizen-sdk-dev
@@ -52,7 +53,12 @@ ifdef CONFIG_DARWIN
 endif
 
 skin_client:
-       TIZEN_SDK_DEV_PATH=${TIZEN_SDK_DEV_PATH} ant -buildfile skin/client/build.xml make-jar
+#      TIZEN_SDK_DEV_PATH=${TIZEN_SDK_DEV_PATH} ant -buildfile skin/client/build.xml make-jar
+ifdef CONFIG_USE_SHM
+       TIZEN_SDK_DEV_PATH=${TIZEN_SDK_DEV_PATH} ant -DdoNotUseSHM=false -buildfile skin/client/build.xml make-jar
+else
+       TIZEN_SDK_DEV_PATH=${TIZEN_SDK_DEV_PATH} ant -DdoNotUseSHM=true -buildfile skin/client/build.xml make-jar
+endif
 
 build_info:
        @echo "Generate a build information file"
@@ -175,7 +181,14 @@ endif
 # for dibs system...
 all_dibs: qemu skin_client_dibs
 skin_client_dibs:
-       ant -buildfile skin/client/build.xml -Dclasspath.dibs=$(ROOTDIR)/tools/emulator/bin make-jar-dibs
+#      ant -buildfile skin/client/build.xml -Dclasspath.dibs=$(ROOTDIR)/tools/emulator/bin make-jar-dibs
+ifdef CONFIG_USE_SHM
+       TIZEN_SDK_DEV_PATH=${TIZEN_SDK_DEV_PATH} ant -DdoNotUseSHM=false ${DIBS_SWT_DIR} -buildfile skin/client/build.xml make-jar
+else
+       TIZEN_SDK_DEV_PATH=${TIZEN_SDK_DEV_PATH} ant -DdoNotNotUseSHM=true ${DIBS_SWT_DIR} -buildfile skin/client/build.xml make-jar
+endif
+
+
 install_dibs: all_dibs
        mkdir -p $(DIBS_COMMON_DIR)/bin
        mkdir -p $(DIBS_COMMON_DIR)/etc
index c0c3d1997401ea04d0439f41c1fe8497189f72be..b1c27b130f6e287bcca6de952dd391dca861800e 100644 (file)
@@ -4,12 +4,21 @@
                <os family="windows" />
        </condition>
        <condition property="isLinux">
-               <os family="unix" />
+               <and>
+                       <os family="unix" />
+                       <not><os family="mac" /></not>
+               </and>
        </condition>
        <condition property="isMac">
-               <os family="mac" />
+               <and>
+                       <os family="mac" />
+                       <!-- we don't support legacy mac -->
+                       <and><os family="unix" /></and>
+               </and>
        </condition>
 
+       <property name="doNotUseSHM" value="${doNotUseSHM}" />
+
        <property environment="env" />
        <property name="jar.file" value="emulator-skin.jar" />
        <property name="mainclass" value="org.tizen.emulator.skin.EmulatorSkinMain" />
@@ -20,6 +29,7 @@
                <pathelement location="${env.TIZEN_SDK_DEV_PATH}/distrib/lib/${swt.file}" />
                <pathelement location="lib/${swt.file}" />
                <pathelement location="build/" />
+               <pathelement location="${classpath.dibs}/${swt.file}" />
        </path>
 
        <target name="clean">
@@ -50,7 +60,7 @@
 
        <target name="prepare-compile" depends="make-properties">
                <echo message="prepare for compile..." />
-               <delete dir="build" />
+                       <delete dir="build" />
                <mkdir dir="build" />
        </target>
 
@@ -80,7 +90,7 @@
                <delete dir="build" />
        </target>
 
-       <target name="create-native-linux" if="isLinux" unless="isMac">
+       <target name="create-native-linux" if="isLinux" unless="doNotUseSHM">
                <echo message="create native shared library on linux..." />
                <javah destdir="native_src">
                        <classpath refid="classpath" />
                        <arg line="-o" />
                        <arg line="libshared.so" />
                </exec>
-
-               <!--
-               <exec dir="native_src" executable="./check-gtk.sh" outputproperty="gtkabi" failifexecutionfails="false" />
-               <echo message="gtkversion : ${gtkabi}" />
-
-               <javah classpath="build;lib/swt.jar" destdir="native_src">
-                       <class name="org.tizen.emulator.skin.screenshot.ScreenShotDialog" />
-               </javah>
-               <echo message="build libclipboard.so" />
-               <exec executable="pkg-config" outputproperty="gtk" failifexecutionfails="false">
-                       <arg line="- -cflags" />
-                       <arg line="- -libs" />
-                       <arg line="${gtkabi}" />
-               </exec>
-               <exec dir="native_src" executable="gcc" failifexecutionfails="false">
-                       <arg line="-c" />
-                       <arg line="-fPIC" />
-                       <arg line="clipboard.c" />
-                       <arg line="-o" />
-                       <arg line="clipboard.o" />
-                       <arg line="-I${env.JAVA_JNI_H_INCLUDE_PATH}" />
-                       <arg line="-I${env.JAVA_JNI_H_INCLUDE_PATH}/linux" />
-                       <arg line="${gtk}" />
-               </exec>
-               <exec dir="native_src" executable="gcc" failifexecutionfails="false">
-                       <arg line="clipboard.o" />
-                       <arg line="-shared" />
-                       <arg line="-o" />
-                       <arg line="libclipboard.so" />
-               </exec>
-               -->
-
                <delete>
                        <fileset dir="native_src" includes="**/*.h" />
                </delete>
        </target>
 
        <target name="make-jar" depends="compile, create-native-linux, create-native-mac, create-jar" />
-
-       <!-- for dibs system... -->
-       <path id="classpath-dibs">
-               <fileset dir="${classpath.dibs}" includes="${swt.file}" />
-       </path>
-
-       <target name="compile-dibs" depends="prepare-compile">
-               <echo message="compiling..." />
-               <javac encoding="UTF-8" fork="true" srcdir="src:jaxb_src" destdir="build" debug="on" memorymaximumsize="128m">
-                       <classpath refid="classpath-dibs" />
-               </javac>
-       </target>
-
-       <target name="make-jar-dibs" depends="compile-dibs, create-native-linux, create-native-mac, create-jar" />
 </project>