Permalink
Browse files

env var renaming and substitution

  • Loading branch information...
1 parent 71d48a2 commit eae946b5274ed5b4aced9b0d513cc0d1c6f719d3 @Aqua-Ye Aqua-Ye committed Oct 5, 2012
Showing with 11 additions and 11 deletions.
  1. +4 −4 Makefile
  2. +2 −2 tools/build/Makefile.bld
  3. +5 −5 tools/build/gen_myocamlbuild.sh
View
@@ -10,9 +10,9 @@
.PHONY: default
default: node
-OPALANG_REPO ?= $(PWD)
+OPALANG_DIR ?= .
-BUILD_PATH = $(OPALANG_REPO)/tools/build
+BUILD_PATH = $(OPALANG_DIR)/tools/build
include $(BUILD_PATH)/config.make
@@ -137,8 +137,8 @@ endef
# List all packages and plugins in stdlib
-OPA_PACKAGES := $(shell cd $(OPALANG_REPO)/lib/stdlib && ./all_packages.sh)
-OPA_PLUGINS := $(shell cd $(OPALANG_REPO)/lib/stdlib && ./all_plugins.sh && echo "opabsl")
+OPA_PACKAGES := $(shell cd $(OPALANG_DIR)/lib/stdlib && ./all_packages.sh)
+OPA_PLUGINS := $(shell cd $(OPALANG_DIR)/lib/stdlib && ./all_plugins.sh && echo "opabsl")
# Rules installing everything that has been compiled
#
View
@@ -36,7 +36,7 @@
#
BUILD_DIR ?= _build
-BLDDIR ?= $(OPALANG_REPO)/tools/build
+BLDDIR ?= $(OPALANG_DIR)/tools/build
MYOCAMLBUILD = $(BUILD_DIR)/myocamlbuild
OCAMLBUILD = $(MYOCAMLBUILD) -no-plugin $(OCAMLBUILD_OPT) $(OCAMLBUILD_FLAGS)
@@ -46,7 +46,7 @@ DESTDIR ?=
INSTALL_DIR = $(DESTDIR)$(PREFIX)
LIB_INSTALL_DIR = $(INSTALL_DIR)/lib/opa/static
-CONFIG_PATH = $(OPALANG_REPO)/tools/build
+CONFIG_PATH = $(OPALANG_DIR)/tools/build
.PHONY: clean
clean::
@@ -11,7 +11,7 @@ set -e
# $ <build_dir>/myocamlbuild -no-plugin -j 6 <targets>
-TOOLS_PATH=$OPALANG_REPO/tools
+TOOLS_PATH=$OPALANG_DIR/tools
CONFIG_PATH=$TOOLS_PATH/build
CONFIG_SH=$CONFIG_PATH/config.sh
@@ -28,7 +28,7 @@ fi
. $TOOLS_PATH/platform_helper.sh
-: ${BLDDIR:="$PWD"/tools/build}
+: ${BLDDIR:=$TOOLS_PATH/build}
CONFIG_ML=$CONFIG_PATH/config.ml
if [ ! -e $CONFIG_ML ]; then
@@ -46,9 +46,9 @@ fi
BUILD_DIR="_build"
-BUILD_RULES="tools/build/build_rules.ml"
-BUILD_LIBS="tools/build/build_libs"
-BUILD_TOOLS="tools/build/build_tools"
+BUILD_RULES=$BLDDIR/build_rules.ml
+BUILD_LIBS=$BLDDIR/build_libs
+BUILD_TOOLS=$BLDDIR/build_tools
while [ $# -gt 0 ]; do
case $1 in

0 comments on commit eae946b

Please sign in to comment.