Lott, Christopher (cl778h) | 6f1e4a5 | 2020-02-07 13:38:19 -0500 | [diff] [blame] | 1 | #!/bin/sh |
| 2 | ############################################################################## |
| 3 | # |
| 4 | # Copyright (c) 2020 AT&T Intellectual Property. |
| 5 | # |
| 6 | # Licensed under the Apache License, Version 2.0 (the "License"); |
| 7 | # you may not use this file except in compliance with the License. |
| 8 | # You may obtain a copy of the License at |
| 9 | # |
| 10 | # http://www.apache.org/licenses/LICENSE-2.0 |
| 11 | # |
| 12 | # Unless required by applicable law or agreed to in writing, software |
| 13 | # distributed under the License is distributed on an "AS IS" BASIS, |
| 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 15 | # See the License for the specific language governing permissions and |
| 16 | # limitations under the License. |
| 17 | # |
| 18 | ############################################################################## |
| 19 | |
| 20 | # Installs NNG then runs a build script in the repository |
| 21 | # Assumes ubuntu - uses apt-get |
| 22 | |
| 23 | echo "--> prescan-e2mgr-ubuntu.sh" |
| 24 | |
| 25 | set -ex |
| 26 | |
| 27 | sudo apt-get update && sudo apt-get install -y cmake ninja-build |
| 28 | |
| 29 | # NNG repo is not frequently tagged so it's pinned to a commit hash. |
| 30 | # This commit repairs bug https://github.com/nanomsg/nng/issues/970 |
| 31 | git clone https://github.com/nanomsg/nng.git |
| 32 | (cd nng \ |
| 33 | && git checkout e618abf8f3db2a94269a79c8901a51148d48fcc2 \ |
| 34 | && mkdir build \ |
| 35 | && cd build \ |
| 36 | && cmake -DBUILD_SHARED_LIBS=1 -G Ninja .. \ |
| 37 | && ninja \ |
| 38 | && sudo ninja install) |
| 39 | |
| 40 | # build script must start in this subdir |
| 41 | cd E2Manager |
| 42 | bash ./build-e2mgr-ubuntu.sh |
| 43 | |
| 44 | echo "--> prescan-e2mgr-ubuntu.sh ends" |