-${JQ_MIN}: ${JQ}
- @@echo "Building" ${JQ_MIN}
-
- @@echo " - Compressing using Minifier"
- @@${JAR} ${BUILD_DIR}/build/min.js ${JQ} ${JQ_MIN}
-
- @@echo ${JQ_MIN} "Built"
- @@echo
-
-test: ${JQ}
- @@echo "Building Test Suite"
- @@echo "Test Suite Built"
- @@echo
-
-runtest: ${JQ} test
- @@echo "Running Automated Test Suite"
- @@${JAR} ${BUILD_DIR}/runtest/test.js
-
- @@echo "Test Suite Finished"
- @@echo
-
-docs: ${JQ}
- @@echo "Building Documentation"
-
- @@echo " - Making Documentation Directory:" ${DOCS_DIR}
- @@mkdir -p ${DOCS_DIR}
- @@mkdir -p ${DOCS_DIR}/data
-
- @@echo " - Copying over htaccess file."
- @@cp -fR ${BUILD_DIR}/docs/.htaccess ${DOCS_DIR}
-
- @@echo " - Copying over script files."
- @@cp -fR ${BUILD_DIR}/docs/js ${DOCS_DIR}/js
-
- @@echo " - Copying over style files."
- @@cp -fR ${BUILD_DIR}/docs/style ${DOCS_DIR}/style
-
- @@echo " - Extracting ScriptDoc from" ${JQ}
- @@${JAR} ${BUILD_DIR}/docs/docs.js ${JQ} ${DOCS_DIR}
-
- @@echo "Documentation Built"
- @@echo
-
-speed: ${JQ}
- @@echo "Building Speed Test Suite"
-
- @@echo " - Making Speed Test Suite Directory:" ${SPEED_DIR}
- @@mkdir -p ${SPEED_DIR}
-
- @@echo " - Copying over script files."
- @@cp -f ${BUILD_DIR}/speed/index.html ${SPEED_DIR}
- @@cp -f ${BUILD_DIR}/speed/benchmarker.css ${SPEED_DIR}
- @@cp -f ${BUILD_DIR}/speed/benchmarker.js ${SPEED_DIR}
- @@cp -f ${BUILD_DIR}/speed/jquery-1.1.2.js ${SPEED_DIR}
-
- @@echo "Speed Test Suite Built"
- @@echo
+${JQ_MIN}: jquery
+ @@if test ! -z ${JS_ENGINE}; then \
+ echo "Minifying jQuery" ${JQ_MIN}; \
+ ${COMPILER} ${JQ} > ${JQ_MIN}.tmp; \
+ sed '$ s#^\( \*/\)\(.\+\)#\1\n\2;#' ${JQ_MIN}.tmp > ${JQ_MIN}; \
+ rm -rf ${JQ_MIN}.tmp; \
+ else \
+ echo "You must have NodeJS installed in order to minify jQuery."; \
+ fi
+