Skip to content
This repository has been archived by the owner on Dec 16, 2020. It is now read-only.

Commit

Permalink
Makefiles now more robust and in-sync with README.md. I also removed …
Browse files Browse the repository at this point in the history
…the oai-deps package because it was much easier/lighter-weight to add a build_deps Makefile target.
  • Loading branch information
Spencer Sevilla committed Dec 13, 2018
1 parent fb4baa6 commit 11c40a3
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 40 deletions.
2 changes: 1 addition & 1 deletion LIBRARIES/Makefile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#### MAKEFILES
BUILD_DIR = ./BUILD
BUILD_DIR = ../BUILD
BUILD_PATH = $(realpath $(BUILD_DIR))

FD_VERSION=1.2.3
Expand Down
40 changes: 16 additions & 24 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,24 +8,31 @@ EPC_VERSION=0.9.10
DB_VERSION=0.9.10
OAI_DEPS_VERSION=0.9.10
TARGET_DIR=./BUILD/
LIB_DIR=./LIBRARIES/

fpm:
sudo apt-get install ruby ruby-dev rubygems build-essential
build_deps:
sudo apt-get install autoconf automake bison build-essential cmake cmake-curses-gui doxygen doxygen-gui flex pkg-config git libconfig-dev libgcrypt11-dev libidn2-0-dev libidn11-dev default-libmysqlclient-dev libpthread-stubs0-dev libsctp1 libsctp-dev libssl-dev libtool openssl nettle-dev nettle-bin php python-pexpect castxml guile-2.0-dev libgmp-dev libhogweed4 libgtk-3-dev libxml2 libxml2-dev mscgen check python libgnutls28-dev python-dev unzip libmnl-dev libevent-dev ruby ruby-dev rubygems
sudo gem install --no-ri --no-rdoc fpm

libraries:
make -C $(LIB_DIR) all

libraries_deb:
make -C $(LIB_DIR) all_deb

target:
mkdir -p $(TARGET_DIR)

hss: target
./oaienv; ./scripts/buid_hss -C
./oaienv; ./scripts/build_hss -C

mme: target
./oaienv; ./scripts/buid_mme -C
./oaienv; ./scripts/build_mme -C

spgw: target
./oaienv; ./scripts/buid_spgw -C
./oaienv; ./scripts/build_spgw -C

hss_deb: target
hss_deb: hss
fpm --input-type dir \
--output-type deb \
--force \
Expand All @@ -48,7 +55,7 @@ hss_deb: target
./package/hss/colte-hss.service=/etc/systemd/system/colte-hss.service \
./package/hss/freeDiameter=/usr/local/etc/oai/

mme_deb: target
mme_deb: mme
fpm --input-type dir \
--output-type deb \
--force \
Expand All @@ -70,7 +77,7 @@ mme_deb: target
./package/mme/colte-mme.service=/etc/systemd/system/colte-mme.service \
./package/mme/freeDiameter=/usr/local/etc/oai/

spgw_deb: target
spgw_deb: spgw
fpm --input-type dir \
--output-type deb \
--force \
Expand Down Expand Up @@ -128,22 +135,7 @@ db: target
--after-remove ./package/db/postrm \
./package/db/sample_db.sql=/usr/local/etc/colte/sample_db.sql

oai-deps: target
fpm --input-type empty \
--output-type deb \
--force \
--vendor uw-ictd \
--maintainer sevilla@cs.washington.edu \
--description "All dependencies needed to build the OpenAirInterface EPC" \
--url "https://github.com/uw-ictd/colte" \
--deb-compression xz \
--name oai-deps \
--version $(OAI_DEPS_VERSION) \
--package $(TARGET_DIR) \
--after-install ./package/oai_deps/postinst \
--depends 'autoconf, automake, bison, build-essential, cmake, cmake-curses-gui, doxygen, doxygen-gui, flex, pkg-config, git, libconfig-dev, libgcrypt11-dev, libidn2-0-dev, libidn11-dev, default-libmysqlclient-dev, libpthread-stubs0-dev, libsctp1, libsctp-dev, libssl-dev, libtool, openssl, nettle-dev, nettle-bin, php, python-pexpect, castxml, guile-2.0-dev, libgmp-dev, libhogweed4, libgtk-3-dev, libxml2, libxml2-dev, mscgen, check, python, libgnutls28-dev, python-dev, unzip, libmnl-dev, colte-freediameter, colte-liblfds, colte-libgtpnl, colte-asn1c, libevent-dev, ruby, ruby-dev, rubygems'

all: hss_deb mme_deb spgw_deb epc db oai-deps
all: hss_deb mme_deb spgw_deb epc db

package-clean:
rm colte*\.deb
Expand Down
17 changes: 6 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ CoLTE (https://github.com/uw-ictd/colte.git) is the Community LTE Project: an al
## System Requirements
We currently support Ubuntu 18.04 (Bionic) and Debian 9 (Stretch).

## Quick Start: Apt-get
## Quick Start: Use apt-get!
We host debian packages of precompiled binaries of the EPC that correspond to tagged releases on here. If you just want to get started with the EPC, copy-paste the following code:
```
echo "deb http://colte.cs.washington.edu $(lsb_release -sc) main" | sudo tee /etc/apt/sources/list.d/colte.list
Expand All @@ -26,22 +26,17 @@ apt-get install colte-epc
```

## Building the EPC
Building the EPC can be broken down into three main parts: build requirements, OAI-specific libraries (freeDiameter, asn1c, libgtpnl, and liblfds), and the EPC itself. To quickly get the build requirements, use our repo above and then run `sudo apt-get install oai-deps`. To apt-get the build requirements yourself, use the following commands:
```
sudo apt-get install autoconf, automake, bison, build-essential, cmake, cmake-curses-gui, doxygen, doxygen-gui, flex, pkg-config, git, libconfig-dev, libgcrypt11-dev, libidn2-0-dev, libidn11-dev, default-libmysqlclient-dev, libpthread-stubs0-dev, libsctp1, libsctp-dev, libssl-dev, libtool, openssl, nettle-dev, nettle-bin, php, python-pexpect, castxml, guile-2.0-dev, libgmp-dev, libhogweed4, libgtk-3-dev, libxml2, libxml2-dev, mscgen, check, python, libgnutls28-dev, python-dev, unzip, libmnl-dev, colte-freediameter, colte-liblfds, colte-libgtpnl, colte-asn1c, libevent-dev, ruby, ruby-dev, rubygems
sudo gem install --no-ri --no-rdoc fpm
```
Building the EPC can be broken down into three main parts: build requirements, OAI-specific libraries (freeDiameter, asn1c, libgtpnl, and liblfds), and the EPC itself. To download all the build requirements, run `make build_deps`.

Once you have the build requirements, you need to install four OAI specific libraries. You can get them from our repository with the following command:
Once you have the build requirements, you need to install four OAI specific libraries before you can build the EPC. We provide them as pre-built debian packages in our repository; you can download them with the following command:
```
sudo apt-get install colte-freediameter colte-asn1c colte-libgtpnl colte-liblfds
```
Alternately, you can build and install these libraries yourself with the following commands:
```
cd LIBRARIES
make all
make all_deb
make libraries
make libraries_deb
sudo dpkg -i BUILD/*.deb
```

Finally, you can build the three components of the EPC (HSS, MME, and SPGW) and package them into .deb files, along with some supporting packages, with `make all`. The output packages will appear in the `BUILD` directory.
Finally, you can build the three components of the EPC (HSS, MME, and SPGW) and package them into .deb files, along with the supporting packages `colte-epc` and `colte-db`, with `make all`. Just as above, the output packages will appear in the `BUILD` directory.
4 changes: 0 additions & 4 deletions package/oai_deps/postinst

This file was deleted.

0 comments on commit 11c40a3

Please sign in to comment.