Commit 75677401 authored by Lionel Gauthier's avatar Lionel Gauthier

git-svn-id: http://svn.eurecom.fr/openair4G/trunk@6219 818b1a75-f10b-46b9-bf7c-635c3b92a50f
parent 738ef607
...@@ -700,10 +700,17 @@ compile_exmimo2_driver() { ...@@ -700,10 +700,17 @@ compile_exmimo2_driver() {
compile_ltesoftmodem() { compile_ltesoftmodem() {
cd $OPENAIR_TARGETS/RT/USER cd $OPENAIR_TARGETS/RT/USER
if [ -f Makefile ]; then if [ -f Makefile ]; then
echo "Compiling directives: $SOFTMODEM_DIRECTIVES" echo "LTE softmodem compiling directives: $SOFTMODEM_DIRECTIVES"
echo "OAI_CLEAN: $OAI_CLEAN"
if [ $OAI_CLEAN -ne 0 ]; then
echo "Cleaning LTE softmodem"
make cleanall > /dev/null 2>&1 make cleanall > /dev/null 2>&1
make $SOFTMODEM_DIRECTIVES fi
make -j $NUM_CPU $SOFTMODEM_DIRECTIVES make -j $NUM_CPU $SOFTMODEM_DIRECTIVES
if [ $? -ne 0 ]; then
# to locate easily compilation error in log file
make $SOFTMODEM_DIRECTIVES
fi
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
if [ ! -f ./lte-softmodem ]; then if [ ! -f ./lte-softmodem ]; then
echo_error "Build lte-softmodem failed, returning" echo_error "Build lte-softmodem failed, returning"
......
...@@ -59,6 +59,7 @@ declare CONFIG_FILE="" ...@@ -59,6 +59,7 @@ declare CONFIG_FILE=""
declare EXE_ARGUMENTS="" declare EXE_ARGUMENTS=""
declare RUN_GDB=0 declare RUN_GDB=0
declare DISABLE_CHECK_INSTALLED_SOFTWARE=0 declare DISABLE_CHECK_INSTALLED_SOFTWARE=0
declare OAI_CLEAN=0
declare OAI_TEST=0 declare OAI_TEST=0
declare XFORMS=0 declare XFORMS=0
...@@ -91,8 +92,8 @@ fi ...@@ -91,8 +92,8 @@ fi
# case $i in # case $i in
until [ -z "$1" ]
while true; do do
case "$1" in case "$1" in
-a | --doxygen) -a | --doxygen)
DOXYGEN=1 DOXYGEN=1
...@@ -128,7 +129,7 @@ while true; do ...@@ -128,7 +129,7 @@ while true; do
shift; shift;
;; ;;
-e | --realtime) -e | --realtime)
RT="$2" RT=$2
echo "setting realtime flag to: $RT" echo "setting realtime flag to: $RT"
shift 2 ; shift 2 ;
;; ;;
...@@ -146,7 +147,7 @@ while true; do ...@@ -146,7 +147,7 @@ while true; do
shift 2; shift 2;
;; ;;
-l | --build-target) -l | --build-target)
BUILD_LTE="$2" BUILD_LTE=$2
echo "setting top-level build target to: $2" echo "setting top-level build target to: $2"
shift 2; shift 2;
;; ;;
...@@ -161,7 +162,7 @@ while true; do ...@@ -161,7 +162,7 @@ while true; do
shift; shift;
;; ;;
-r | --3gpp-release) -r | --3gpp-release)
REL="$2" REL=$2
echo "setting release to: $REL" echo "setting release to: $REL"
shift 2 ; shift 2 ;
;; ;;
...@@ -171,8 +172,8 @@ while true; do ...@@ -171,8 +172,8 @@ while true; do
shift; shift;
;; ;;
-t | --enb-build-target) -t | --enb-build-target)
TARGET="$2" TARGET=$2
echo "setting target to: $TARGET" echo "setting enb build target to: $TARGET"
shift 2; shift 2;
;; ;;
-V | --vcd) -V | --vcd)
...@@ -205,9 +206,6 @@ while true; do ...@@ -205,9 +206,6 @@ while true; do
OAI_TEST=0 OAI_TEST=0
shift ; shift ;
;; ;;
' ')
shift ;
;;
*) *)
echo "Unknown option $1" echo "Unknown option $1"
break ; break ;
...@@ -284,12 +282,12 @@ build_enb(){ ...@@ -284,12 +282,12 @@ build_enb(){
SOFTMODEM_DIRECTIVES="DEBUG=$DEBUG XFORMS=$XFORMS " SOFTMODEM_DIRECTIVES="DEBUG=$DEBUG XFORMS=$XFORMS "
OAISIM_DIRECTIVES="DEBUG=$DEBUG XFORMS=$XFORMS " OAISIM_DIRECTIVES="DEBUG=$DEBUG XFORMS=$XFORMS "
if [ $ENB_S1 = 1 ]; then if [ $ENB_S1 -eq 1 ]; then
SOFTMODEM_DIRECTIVES="$SOFTMODEM_DIRECTIVES USE_MME=R10 ENABLE_ITTI=1 LINK_PDCP_TO_GTPV1U=1 SECU=1 " SOFTMODEM_DIRECTIVES="$SOFTMODEM_DIRECTIVES USE_MME=R10 ENABLE_ITTI=1 LINK_PDCP_TO_GTPV1U=1 SECU=1 "
OAISIM_DIRECTIVES="$OAISIM_DIRECTIVES USE_MME=R10 ENABLE_ITTI=1 LINK_PDCP_TO_GTPV1U=1 SECU=1 " OAISIM_DIRECTIVES="$OAISIM_DIRECTIVES USE_MME=R10 ENABLE_ITTI=1 LINK_PDCP_TO_GTPV1U=1 SECU=1 "
fi fi
if [ $DEBUG = 0 ]; then if [ $DEBUG -eq 0 ]; then
SOFTMODEM_DIRECTIVES="$SOFTMODEM_DIRECTIVES DISABLE_XER_PRINT=1 " SOFTMODEM_DIRECTIVES="$SOFTMODEM_DIRECTIVES DISABLE_XER_PRINT=1 "
OAISIM_DIRECTIVES="$OAISIM_DIRECTIVES DISABLE_XER_PRINT=1 " OAISIM_DIRECTIVES="$OAISIM_DIRECTIVES DISABLE_XER_PRINT=1 "
fi fi
...@@ -368,6 +366,7 @@ build_enb(){ ...@@ -368,6 +366,7 @@ build_enb(){
check_install_nettle check_install_nettle
else else
echo_info "6. Not checking the required softwares/packages ..." echo_info "6. Not checking the required softwares/packages ..."
touch ./.lock_oaibuild
fi fi
############################################ ############################################
...@@ -407,15 +406,14 @@ build_enb(){ ...@@ -407,15 +406,14 @@ build_enb(){
else else
if [ $TARGET == "SOFTMODEM" ]; then
if [ $TARGET = "SOFTMODEM" ]; then
echo "############# compile_ltesoftmodem #############" >> bin/install_log.txt echo "############# compile_ltesoftmodem #############" >> bin/install_log.txt
output=$(compile_ltesoftmodem >> bin/install_log.txt 2>&1 ) output=$(compile_ltesoftmodem >> bin/install_log.txt 2>&1 )
softmodem_compiled=$? softmodem_compiled=$?
check_for_ltesoftmodem_executable check_for_ltesoftmodem_executable
echo_info "7.1 finished ltesoftmodem target: check the installation log file bin/install_log.txt" echo_info "7.1 finished ltesoftmodem target: check the installation log file bin/install_log.txt"
if [ $HW = "EXMIMO" ]; then if [ $HW == "EXMIMO" ]; then
compile_exmimo2_driver compile_exmimo2_driver
fi fi
fi fi
...@@ -449,17 +447,17 @@ build_enb(){ ...@@ -449,17 +447,17 @@ build_enb(){
echo_info "8. Installing ..." echo_info "8. Installing ..."
if [ $softmodem_compiled = 0 ]; then if [ $softmodem_compiled -eq 0 ]; then
echo_success "target lte-softmodem built and installed in the bin directory" echo_success "target lte-softmodem built and installed in the bin directory"
echo "target lte-softmodem built and installed in the bin directory" >> bin/${oai_build_date} echo "target lte-softmodem built and installed in the bin directory" >> bin/${oai_build_date}
output=$(install_ltesoftmodem $RT $HW $ENB_S1 ) output=$(install_ltesoftmodem $RT $HW $ENB_S1 )
fi fi
if [ $oaisim_compiled = 0 ]; then if [ $oaisim_compiled -eq 0 ]; then
echo_success "target oaisim built and installed in the bin directory" echo_success "target oaisim built and installed in the bin directory"
echo "target oaisim built and installed in the bin directory" >> bin/${oai_build_date} echo "target oaisim built and installed in the bin directory" >> bin/${oai_build_date}
output=$(install_oaisim $ENB_S1 ) output=$(install_oaisim $ENB_S1 )
fi fi
if [ $unisim_compiled = 0 ]; then if [ $unisim_compiled -eq 0 ]; then
echo_success "target unisim built and installed in the bin directory" echo_success "target unisim built and installed in the bin directory"
echo "target unisim built and installed in the bin directory" >> bin/${oai_build_date} echo "target unisim built and installed in the bin directory" >> bin/${oai_build_date}
fi fi
...@@ -485,7 +483,7 @@ build_epc(){ ...@@ -485,7 +483,7 @@ build_epc(){
check_install_asn1c check_install_asn1c
if [ $OAI_CLEAN = 1 ]; then if [ $OAI_CLEAN -eq 1 ]; then
check_install_freediamter check_install_freediamter
else else
if [ ! -d /usr/local/etc/freeDiameter ]; then if [ ! -d /usr/local/etc/freeDiameter ]; then
...@@ -512,7 +510,7 @@ build_epc(){ ...@@ -512,7 +510,7 @@ build_epc(){
echo_info "6. install the binary file" echo_info "6. install the binary file"
if [ $epc_compiled = 0 ]; then if [ $epc_compiled -eq 0 ]; then
echo_success "target epc built and installed in the bin directory" echo_success "target epc built and installed in the bin directory"
echo "target epc built and installed in the bin directory" >> bin/${oai_build_date} echo "target epc built and installed in the bin directory" >> bin/${oai_build_date}
cp -f $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/epc.generic.conf $OPENAIR_TARGETS/bin cp -f $OPENAIR_TARGETS/PROJECTS/GENERIC-LTE-EPC/CONF/epc.generic.conf $OPENAIR_TARGETS/bin
...@@ -542,7 +540,7 @@ build_hss(){ ...@@ -542,7 +540,7 @@ build_hss(){
check_install_hss_software check_install_hss_software
if [ $OAI_CLEAN = 1 ]; then if [ $OAI_CLEAN -eq 1 ]; then
check_install_freediamter check_install_freediamter
else else
if [ ! -d /usr/local/etc/freeDiameter ]; then if [ ! -d /usr/local/etc/freeDiameter ]; then
...@@ -580,7 +578,7 @@ build_hss(){ ...@@ -580,7 +578,7 @@ build_hss(){
###################################### ######################################
echo_info "7. install the binary file" echo_info "7. install the binary file"
if [ $hss_compiled = 0 ]; then if [ $hss_compiled -eq 0 ]; then
echo_success "target hss built, DB created and installed in the bin directory" echo_success "target hss built, DB created and installed in the bin directory"
echo "target hss built, DB created, and installed in the bin directory" >> bin/${oai_build_date} echo "target hss built, DB created, and installed in the bin directory" >> bin/${oai_build_date}
cp -rf $OPENAIRCN_DIR/OPENAIRHSS/conf $OPENAIR_TARGETS/bin cp -rf $OPENAIRCN_DIR/OPENAIRHSS/conf $OPENAIR_TARGETS/bin
...@@ -641,7 +639,7 @@ esac ...@@ -641,7 +639,7 @@ esac
# testing # testing
############################################ ############################################
if [ $OAI_TEST = 1 ]; then if [ $OAI_TEST -eq 1 ]; then
echo_info "10. Testing ..." echo_info "10. Testing ..."
python $OPENAIR_TARGETS/TEST/OAI/test01.py python $OPENAIR_TARGETS/TEST/OAI/test01.py
else else
...@@ -652,8 +650,8 @@ esac ...@@ -652,8 +650,8 @@ esac
# run # run
############################################ ############################################
echo_info "11. Running ... To be done" echo_info "11. Running ... To be done"
if [ $TARGET = "SOFTMODEM" ]; then if [ $TARGET == "SOFTMODEM" ]; then
if [ $HW = "EXMIMO" ]; then if [ $HW == "EXMIMO" ]; then
bash $OPENAIR_TARGETS/RT/USER/init_exmimo2.sh bash $OPENAIR_TARGETS/RT/USER/init_exmimo2.sh
fi fi
echo "############# running ltesoftmodem #############" echo "############# running ltesoftmodem #############"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment