Merge branch 'merge' into tizen_2.1
[platform/framework/web/web-ui-fw.git] / Makefile
index 664d3b7..ec2a1fa 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -9,6 +9,7 @@ PKG_VERSION = $(shell cat packaging/web-ui-fw.spec | grep Version: | sed -e "s@V
 THEME_NAME = default
 
 PATH := $(CURDIR)/build-tools/bin:$(PATH)
+NODE = /usr/bin/node
 
 JSLINT_LEVEL = 1
 JSLINT = jslint --sloppy --eqeq --bitwise --forin --nomen --predef jQuery --color --plusplus --browser --jqmspace --regexp --continue
@@ -53,7 +54,9 @@ FW_WIDGET_CSS_FILE = ${WIDGET_CSS_OUTPUT_ROOT}/${PROJECT_NAME}-widget.css
 LIBS_JS_FILES = jquery.easing.1.3.js \
                jquery.tmpl.js \
                jquery.mobile.js \
-                $(NULL)
+               globalize/lib/globalize.js \
+               gl-matrix.js \
+               $(NULL)
 
 JQUERY_MOBILE_CSS = submodules/jquery-mobile/compiled/jquery.mobile.structure.css \
                     submodules/jquery-mobile/compiled/jquery.mobile.css \
@@ -87,7 +90,7 @@ jqm: init
        cd ${JQM_LIB_PATH} && make js NODE=/usr/bin/node || exit 1; \
        cp -f ${JQM_LIB_PATH}/compiled/*.js ${JQM_LIB_PATH}/../; \
 
-third_party: init jqm
+third_party: init jqm globalize
        # Building third party components...
        @@cd ${LIBS_DIR}/js; \
            for f in ${LIBS_JS_FILES}; do \
@@ -98,11 +101,11 @@ third_party: init jqm
            cp ${LIBS_DIR}/js/${JQUERY} ${JS_OUTPUT_ROOT}/jquery.js
            cp ${LIBS_DIR}/js/${JQUERY_MIN} ${JS_OUTPUT_ROOT}/jquery.min.js
 
-js: init third_party globalize
+js: init third_party
        # Building JS files...
        mkdir -p ${JS_LIB_OUTPUT_DIR}; \
        cp -a ${JS_DIR}/* ${JS_LIB_OUTPUT_DIR}/; \
-       /usr/bin/node $(CURDIR)/tools/moduledep.js -c ${JS_LIB_OUTPUT_DIR} > ${JS_LIB_OUTPUT_DIR}/../depData.json; \
+       ${NODE} $(CURDIR)/tools/moduledep.js -c ${JS_LIB_OUTPUT_DIR} > ${JS_LIB_OUTPUT_DIR}/../depData.json; \
        find ${JS_LIB_OUTPUT_DIR} -iname '*.js' | sort | \
        while read JSFILE; do \
                echo " # Building $$JSFILE"; \
@@ -122,9 +125,9 @@ js: init third_party globalize
                        echo "          $$f"; \
                fi; \
        done; \
-       /usr/bin/node $(CURDIR)/tools/moduledep.js -d ${JS_LIB_OUTPUT_DIR} ${JS_LIB_OUTPUT_DIR}/../depData.json >> ${FW_JS}; \
+       ${NODE} $(CURDIR)/tools/moduledep.js -d ${JS_LIB_OUTPUT_DIR} ${JS_LIB_OUTPUT_DIR}/../depData.json >> ${FW_JS}; \
        cp -a ${JS_DIR}/* ${JQM_LIB_PATH}/js/* ${JS_LIB_OUTPUT_DIR}/; \
-       /usr/bin/node $(CURDIR)/tools/moduledep.js -c ${JS_LIB_OUTPUT_DIR} > ${JS_LIB_OUTPUT_DIR}/../depData.json; \
+       ${NODE} $(CURDIR)/tools/moduledep.js -c ${JS_LIB_OUTPUT_DIR} > ${JS_LIB_OUTPUT_DIR}/../depData.json; \
        find ${JS_LIB_OUTPUT_DIR} -iname '*.js' | xargs sed -i -e '/^\/\/>>excludeStart\(.*\);/,/^\/\/>>excludeEnd\(.*\);/d';
 
 widgets: init third_party globalize
@@ -176,7 +179,6 @@ widgets: init third_party globalize
            done
 
 globalize:
-       cat 'libs/js/globalize/lib/globalize.js' >> ${FW_LIB_JS}
        # copy globalize libs...
        cp -a libs/js/globalize/lib/cultures ${FRAMEWORK_ROOT}/js/
 
@@ -187,7 +189,7 @@ version: js themes
        echo '(function($$){$$.tizen.frameworkData.pkgVersion="$(PKG_VERSION)";}(jQuery));' >> ${FW_JS}
        echo "$(PKG_VERSION)" > ${FRAMEWORK_ROOT}/../VERSION
 
-compress: js themes
+compress: third_party js themes
        # Javacript code compressing
        @@echo "        # Compressing...."; \
        echo '/*' > ${FW_MIN}; \