SVN to GIT migration (removed EPC software, updated mailing list address in all files)

git-svn-id: http://svn.eurecom.fr/openair4G/trunk@7885 818b1a75-f10b-46b9-bf7c-635c3b92a50f
This commit is contained in:
gauthier
2015-10-06 16:24:54 +00:00
parent 5938fef4d6
commit c7518ecf42
1773 changed files with 13600 additions and 119437 deletions
+23 -180
View File
@@ -1,29 +1,31 @@
################################################################################
# OpenAirInterface
# Copyright(c) 1999 - 2014 Eurecom
#
# OpenAirInterface is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# Copyright (c) 2015, EURECOM (www.eurecom.fr)
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# OpenAirInterface is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# 1. Redistributions of source code must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
#
# You should have received a copy of the GNU General Public License
# along with OpenAirInterface.The full GNU General Public License is
# included in this distribution in the file called "COPYING". If not,
# see <http://www.gnu.org/licenses/>.
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#
# Contact Information
# OpenAirInterface Admin: openair_admin@eurecom.fr
# OpenAirInterface Tech : openair_tech@eurecom.fr
# OpenAirInterface Dev : openair4g-devel@eurecom.fr
#
# Address : Eurecom, Campus SophiaTech, 450 Route des Chappes, CS 50193 - 06904 Biot Sophia Antipolis cedex, FRANCE
# The views and conclusions contained in the software and documentation are those
# of the authors and should not be interpreted as representing official policies,
# either expressed or implied, of the FreeBSD Project.
#
################################################################################
# file build_helper
@@ -95,12 +97,9 @@ clean_kernel() {
clean_all_files() {
set_openair_env
dir=$OPENAIR_DIR/cmake_targets
rm -rf $dir/log $OPENAIR_DIR/targets/bin/*
rm -rf $dir/log $OPENAIR_DIR/targets/bin/*
rm -rf $dir/lte_build_oai $dir/lte-simulators/build
rm -rf $dir/epc_build_oai/build $dir/epc_build_oai/CMakeLists.txt
rm -rf $dir/oaisim_build_oai/build $dir/oaisim_build_oai/CMakeLists.txt
rm -rf $dir/oaisim_mme_build_oai/build $dir/oaisim_mme_build_oai/CMakeLists.txt
rm -rf $dir/hss_build/build
rm -rf $dir/autotests/bin $dir/autotests/log $dir/autotests/*/build
}
@@ -123,50 +122,6 @@ compilations() {
fi
}
##########################################
# X.509 certificates
##########################################
make_one_cert() {
fqdn=$1
name=$2
$SUDO openssl genrsa -out $name.key.pem 1024
$SUDO openssl req -new -batch -out $name.csr.pem -key $name.key.pem -subj /CN=$name.$fqdn/C=FR/ST=PACA/L=Aix/O=Eurecom/OU=CM
$SUDO openssl ca -cert cacert.pem -keyfile cakey.pem -in $name.csr.pem -out $name.cert.pem -outdir . -batch
}
make_certs(){
fqdn=$1
certs_dir=$FREEDIAMETER_PREFIX/freeDiameter
# certificates are stored in diameter config directory
if [ ! -d $certs_dir ]; then
echo "Creating non existing directory: $certs_dir"
$SUDO mkdir -p $certs_dir || echo_error "can't create: $certs_dir"
fi
cd $certs_dir
echo "creating the CA certificate"
echo_warning "erase all existing certificates as long as the CA is regenerated"
$SUDO rm -f $certs_dir/*.pem
$SUDO mkdir -p $certs_dir/demoCA/
$SUDO touch $certs_dir/demoCA/index.txt
$SUDO sh -c "echo 01 > $certs_dir/demoCA/serial"
# CA self certificate
$SUDO openssl req -new -batch -x509 -days 3650 -nodes -newkey rsa:1024 -out cacert.pem -keyout cakey.pem -subj /CN=$fqdn/C=FR/ST=PACA/L=Aix/O=Eurecom/OU=CM
# generate hss certificate and sign it
make_one_cert eur hss
make_one_cert eur mme
# legacy config is using a certificate named 'user'
make_one_cert eur user
}
############################################
# External packages installers
############################################
@@ -200,58 +155,6 @@ install_gnutls_from_source(){
rm -rf /tmp/gnutls-3.1.23.tar.xz /tmp/gnutls-3.1.23
}
install_1.1.5_freediameter_from_source() {
cd /tmp
echo "Downloading 1.1.5 freeDiameter archive"
rm -rf /tmp/1.1.5.tar.gz* /tmp/freeDiameter-1.1.5
wget http://www.freediameter.net/hg/freeDiameter/archive/1.1.5.tar.gz
tar xzf 1.1.5.tar.gz
cd freeDiameter-1.1.5
patch -p1 < $OPENAIR_DIR/openair-cn/S6A/freediameter/freediameter-1.1.5.patch
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX:PATH=/usr ../
echo "Compiling freeDiameter"
make -j`nproc`
#make test
$SUDO make install
rm -rf /tmp/1.1.5.tar.gz /tmp/freeDiameter-1.1.5
}
install_freediameter_from_source() {
cd /tmp
echo "Downloading 1.2.0 freeDiameter archive"
rm -rf /tmp/1.2.0.tar.gz* /tmp/freeDiameter-1.2.0
wget http://www.freediameter.net/hg/freeDiameter/archive/1.2.0.tar.gz
tar xzf 1.2.0.tar.gz
cd freeDiameter-1.2.0
patch -p1 < $OPENAIR_DIR/openair-cn/S6A/freediameter/freediameter-1.2.0.patch
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX:PATH=/usr ../
echo "Compiling freeDiameter"
make -j`nproc`
#make test
$SUDO make install
rm -rf /tmp/1.2.0.tar.gz /tmp/freeDiameter-1.2.0
}
install_latest_freediameter_from_source() {
cd /tmp
rm -rf /tmp/freeDiameter
echo "Downloading latest freeDiameter trunk (may be unstable)"
git clone https://github.com/Metaswitch/freeDiameter.git
cd freeDiameter
patch -p1 < $OPENAIR_DIR/openair-cn/S6A/freediameter/freediameter-1.2.0.patch
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX:PATH=/usr ../
echo "Compiling freeDiameter"
make -j`nproc`
#make test
$SUDO make install
rm -rf /tmp/freeDiameter
}
check_install_usrp_uhd_driver(){
@@ -345,8 +248,6 @@ check_install_oai_software() {
libxml2-dev \
linux-headers-`uname -r` \
mscgen \
mysql-client \
mysql-server \
octave \
octave-signal \
openssh-client \
@@ -400,65 +301,7 @@ install_nas_tools() {
}
##################################
# create HSS DB
################################
# arg 1 is mysql admin (ex: root)
# arg 2 is mysql password (ex: linux)
# arg 3 is hss username (ex: hssadmin)
# arg 4 is hss password (ex: admin)
# arg 5 is database name (ex: oai_db)
create_hss_database(){
EXPECTED_ARGS=5
if [ $# -ne $EXPECTED_ARGS ]
then
echo_error "Usage: $0 dbadmin dbpass hssuser hsspass databasename"
return 1
fi
local mysql_admin=$1
local mysql_password=$2
local hss_username=$3
local hss_password=$4
local database_name=$5
Q1="GRANT ALL PRIVILEGES ON *.* TO '$hss_username'@'localhost' IDENTIFIED BY '$hss_password' WITH GRANT OPTION;"
Q2="FLUSH PRIVILEGES;"
mysql -u $mysql_admin --password=$mysql_password -e "${Q1}${Q2}"
if [ $? -ne 0 ]; then
echo_error "HSS: $hss_username permissions creation failed"
echo_error "verify root password for mysql is linux: mysql -u root --password=linux"
echo_error "if not, reset it to "linux" with sudo dpkg-reconfigure mysql-server-5.5"
return 1
else
echo_success "HSS: $hss_username permissions creation succeeded"
fi
Q3="CREATE DATABASE IF NOT EXISTS $database_name;"
mysql -u $hss_username --password=$hss_password -e "${Q3}"
if [ $? -ne 0 ]; then
echo_error "HSS: $database_name creation failed"
return 1
else
echo_success "HSS: $database_name creation succeeded"
fi
# test if tables have been created
mysql -u $hss_username --password=$hss_password -e "desc $database_name.users" > /dev/null 2>&1
if [ $? -eq 1 ]; then
mysql -u $hss_username --password=$hss_password $database_name < $OPENAIR_DIR/openair-cn/OPENAIRHSS/db/$database_name.sql
if [ $? -ne 0 ]; then
echo_error "HSS: $database_name tables creation failed"
return 1
else
echo_success "HSS: $database_name tables creation succeeded"
fi
else
echo_success "HSS: $database_name tables already created, nothing done"
fi
return 0
}
################################
# set_openair_env