summaryrefslogtreecommitdiff
path: root/bin/compiler
diff options
context:
space:
mode:
Diffstat (limited to 'bin/compiler')
-rw-r--r--bin/compiler/.gitignore2
-rwxr-xr-xbin/compiler/1-clean.sh5
-rwxr-xr-xbin/compiler/2-configure.sh5
-rwxr-xr-xbin/compiler/3-build.sh5
-rw-r--r--bin/compiler/README.md32
-rwxr-xr-xbin/compiler/compiler.sh44
-rw-r--r--bin/compiler/includes/defines.sh7
-rw-r--r--bin/compiler/includes/functions.sh57
-rw-r--r--bin/compiler/includes/includes.sh23
9 files changed, 0 insertions, 180 deletions
diff --git a/bin/compiler/.gitignore b/bin/compiler/.gitignore
deleted file mode 100644
index ba57f2bccf..0000000000
--- a/bin/compiler/.gitignore
+++ /dev/null
@@ -1,2 +0,0 @@
-config.sh
-
diff --git a/bin/compiler/1-clean.sh b/bin/compiler/1-clean.sh
deleted file mode 100755
index 558c093e3f..0000000000
--- a/bin/compiler/1-clean.sh
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/usr/bin/env bash
-
-CURRENT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-
-bash "$CURRENT_PATH/compiler.sh" 1
diff --git a/bin/compiler/2-configure.sh b/bin/compiler/2-configure.sh
deleted file mode 100755
index 0d59b1caac..0000000000
--- a/bin/compiler/2-configure.sh
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/usr/bin/env bash
-
-CURRENT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-
-bash "$CURRENT_PATH/compiler.sh" 2
diff --git a/bin/compiler/3-build.sh b/bin/compiler/3-build.sh
deleted file mode 100755
index 6956f82fd3..0000000000
--- a/bin/compiler/3-build.sh
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/usr/bin/env bash
-
-CURRENT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-
-bash "$CURRENT_PATH/compiler.sh" 3
diff --git a/bin/compiler/README.md b/bin/compiler/README.md
deleted file mode 100644
index a4759ee232..0000000000
--- a/bin/compiler/README.md
+++ /dev/null
@@ -1,32 +0,0 @@
-## How to compile:
-
-first of all, if you need some custom configuration you have to copy and rename
-/conf/config.sh.dist in /conf/config.sh and configure it
-
-* for a "clean" compilation you must run all scripts in their order:
-
- ./1-clean.sh
- ./2-configure.sh
- ./3-build.sh
-
-* if you add/rename/delete some sources and you need to compile it you have to run:
-
- ./2-configure.sh
- ./3-build.sh
-
-* if you have modified code only, you just need to run
-
- ./3-build.sh
-
-
-## compiler.sh
-
-compiler.sh script contains an interactive menu to clean/compile/build. You can also run actions directly by command lines specifying the option.
-Ex:
- ./compiler.sh 3
-
-It will start the build process (it's equivalent to ./3-build.sh)
-
-## Note:
-
-For an optimal development process and **really faster** compilation time, is suggested to use clang instead of gcc
diff --git a/bin/compiler/compiler.sh b/bin/compiler/compiler.sh
deleted file mode 100755
index cb89bfb705..0000000000
--- a/bin/compiler/compiler.sh
+++ /dev/null
@@ -1,44 +0,0 @@
-#!/usr/bin/env bash
-
-CURRENT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-
-source "$CURRENT_PATH/includes/includes.sh"
-
-function all() {
- comp_clean
- comp_configure
- comp_build
-}
-
-function run_option() {
- if test "${comp_functions[$1-1]+'test'}"; then
- ${comp_functions[$1-1]}
- else
- echo "invalid option"
- fi
-}
-
-comp_options=("Clean" "Configure" "Build" "All")
-comp_functions=("comp_clean" "comp_configure" "comp_build" "all")
-
-runHooks "ON_AFTER_OPTIONS" #you can create your custom options
-
-# push exit after custom options
-comp_options+=('Exit')
-comp_functions+=('exit 0')
-
-# run option directly if specified in argument
-[ ! -z $1 ] && run_option $1 && exit 0
-
-PS3='[ Please enter your choice ]: '
-select opt in "${comp_options[@]}"
-do
- case $opt in
- 'Exit')
- break
- ;;
- *)
- run_option $REPLY
- ;;
- esac
-done
diff --git a/bin/compiler/includes/defines.sh b/bin/compiler/includes/defines.sh
deleted file mode 100644
index 57c809c470..0000000000
--- a/bin/compiler/includes/defines.sh
+++ /dev/null
@@ -1,7 +0,0 @@
-# you can choose build type from cmd argument
-if [ ! -z $1 ]
-then
- CCTYPE=$1
- CCTYPE=${CCTYPE^} # capitalize first letter if it's not yet
-fi
-
diff --git a/bin/compiler/includes/functions.sh b/bin/compiler/includes/functions.sh
deleted file mode 100644
index 4dfaa46038..0000000000
--- a/bin/compiler/includes/functions.sh
+++ /dev/null
@@ -1,57 +0,0 @@
-
-function comp_clean() {
- echo "Cleaning build files"
-
- CWD=$(pwd)
-
- cd $BUILDPATH
-
- make -f Makefile clean
- make clean
- find -iname '*cmake*' -not -name CMakeLists.txt -exec rm -rf {} \+
-
- cd $CWD
-}
-
-function comp_configure() {
- CWD=$(pwd)
-
- cd $BUILDPATH
-
- echo "Build path: $BUILDPATH"
- echo "DEBUG info: $CDEBUG"
- echo "Compilation type: $CTYPE"
- # -DCMAKE_BUILD_TYPE=$CCTYPE disable optimization "slow and huge amount of ram"
- # -DWITH_COREDEBUG=$CDEBUG compiled with debug information
-
- #-DSCRIPTS_COMMANDS=$CSCRIPTS -DSCRIPTS_CUSTOM=$CSCRIPTS -DSCRIPTS_EASTERNKINGDOMS=$CSCRIPTS -DSCRIPTS_EVENTS=$CSCRIPTS -DSCRIPTS_KALIMDOR=$CSCRIPTS \
- #-DSCRIPTS_NORTHREND=$CSCRIPTS -DSCRIPTS_OUTDOORPVP=$CSCRIPTS -DSCRIPTS_OUTLAND=$CSCRIPTS -DSCRIPTS_PET=$CSCRIPTS -DSCRIPTS_SPELLS=$CSCRIPTS -DSCRIPTS_WORLD=$CSCRIPTS \
- #-DAC_WITH_UNIT_TEST=$CAC_UNIT_TEST -DAC_WITH_PLUGINS=$CAC_PLG \
-
- cmake $SRCPATH -DCMAKE_INSTALL_PREFIX=$BINPATH -DCONF_DIR=$CONFDIR -DSERVERS=$CSERVERS \
- -DSCRIPTS=$CSCRIPTS \
- -DTOOLS=$CTOOLS -DUSE_SCRIPTPCH=$CSCRIPTPCH -DUSE_COREPCH=$CCOREPCH -DWITH_COREDEBUG=$CDEBUG -DCMAKE_BUILD_TYPE=$CTYPE -DWITH_WARNINGS=$CWARNINGS \
- -DCMAKE_C_COMPILER=$CCOMPILERC -DCMAKE_CXX_COMPILER=$CCOMPILERCXX "-DDISABLED_AC_MODULES=$CDISABLED_AC_MODULES" $CCUSTOMOPTIONS
-
- cd $CWD
-
- runHooks "ON_AFTER_CONFIG"
-}
-
-
-function comp_build() {
- [ $MTHREADS == 0 ] && MTHREADS=`grep -c ^processor /proc/cpuinfo` && MTHREADS=$(($MTHREADS + 2))
-
- echo "Using $MTHREADS threads"
-
- CWD=$(pwd)
-
- cd $BUILDPATH
-
- time make -j $MTHREADS
- make -j $MTHREADS install
-
- cd $CWD
-
- runHooks "ON_AFTER_BUILD"
-}
diff --git a/bin/compiler/includes/includes.sh b/bin/compiler/includes/includes.sh
deleted file mode 100644
index ffde93a73e..0000000000
--- a/bin/compiler/includes/includes.sh
+++ /dev/null
@@ -1,23 +0,0 @@
-CURRENT_PATH="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-
-source "$CURRENT_PATH/../../bash_shared/includes.sh"
-
-AC_PATH_COMPILER="$AC_PATH_BIN/compiler"
-
-if [ -f "$AC_PATH_COMPILER/config.sh" ]; then
- source "$AC_PATH_COMPILER/config.sh" # should overwrite previous
-fi
-
-function ac_on_after_build() {
- # move the run engine
- cp -rvf "$AC_PATH_MODULES/acore/startup-scripts/"* "$BINPATH"
-}
-
-registerHooks "ON_AFTER_BUILD" ac_on_after_build
-
-source "$AC_PATH_COMPILER/includes/defines.sh"
-
-source "$AC_PATH_COMPILER/includes/functions.sh"
-
-mkdir -p $BUILDPATH
-mkdir -p $BINPATH