Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
  • limx1980/oai-cn5g-common-build
  • oai/cn5g/oai-cn5g-common-build
2 results
Show changes
Commits on Source (2)
################################################################################
# Licensed to the OpenAirInterface (OAI) Software Alliance under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The OpenAirInterface Software Alliance licenses this file to You under
# the OAI Public License, Version 1.1 (the "License"); you may not use this file
# except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.openairinterface.org/?page_id=698
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#-------------------------------------------------------------------------------
# For more information about the OpenAirInterface (OAI) Software Alliance:
# contact@openairinterface.org
################################################################################
#-------------------------------------------------------------------------------
#arg1 is force (0 or 1) (no interactive script)
#arg2 is debug (0 or 1) (install debug libraries)
install_odb() {
echo "Starting to install odb"
if [ $1 -eq 0 ]; then
read -p "Do you want to install odb ? <y/N> " prompt
OPTION=""
else
prompt='y'
OPTION="-y"
fi
if [[ $prompt =~ [yY](es)* ]]
then
C_URL=https://download.build2.org/0.17.0/build2-install-0.17.0.sh
echo "Install ODB runtime library from $C_URL"
pushd /tmp
if [[ $prompt =~ [yY](es)* ]]
then
$SUDO rm -rf build2
fi
mkdir build2 && cd build2
curl -sSfO $C_URL
echo "download done"
sleep 4
sh build2-install-0.17.0.sh --yes --no-bdep --no-modules --trust yes
echo "build2 installation complete"
sleep 4
which bpkg
sleep 4
cd ..
echo "Starting to install odb"
mkdir odb-build && cd odb-build
bpkg create -d libodb-gcc cc \
config.cxx=g++ \
config.cc.coptions=-O3 \
config.install.root=/usr/local
cd libodb-gcc
echo "Build odb runtime libraries"
bpkg add https://pkg.cppget.org/1/beta
bpkg fetch --trust-yes
bpkg build libodb --yes
bpkg build libodb-mysql --yes
echo "Install odb runtime libraries"
sleep 4
$SUDO bpkg install --all --recursive
fi
echo "odb installation complete"
return 0
}
\ No newline at end of file