<commit_before># Base it on good ol' trusty
FROM ubuntu:trusty
MAINTAINER hbirch

# List of system dependencies, rest come from git
RUN apt-get -y install software-properties-common

RUN bash -c "add-apt-repository \"deb http://archive.ubuntu.com/ubuntu $(lsb_release -sc) universe multiverse\""

RUN apt-get update

RUN apt-get -y install \
	git \
	build-essential \
	cmake \
	libopencv-dev \
	libboost-dev \
	libboost-thread-dev \
	libboost-system-dev \
	libboost-date-time-dev \
	libboost-chrono-dev \
	libboost-program-options-dev \
	libboost-filesystem-dev \
	libusb-1.0-0-dev

RUN useradd -m bob

USER bob
WORKDIR /home/bob

# Cloning repos
RUN git clone --recursive https://github.com/OSVR/OSVR-Core.git
RUN git clone --recursive https://github.com/OSVR/libfunctionality.git
RUN git clone --recursive https://github.com/VRPN/jsoncpp

USER root
RUN add-apt-repository "ppa:george-edison55/cmake-3.x"

RUN apt-get update
RUN apt-get -y install cmake

USER bob

# Building JSONCPP
RUN mkdir /home/bob/json-build
WORKDIR /home/bob/json-build
RUN cmake ../jsoncpp/ -DJSONCPP_WITH_CMAKE_PACKAGE=ON -DJSONCPP_LIB_BUILD_SHARED=OFF -DCMAKE_CXX_FLAGS=-fPIC
RUN make
# Deploying JSONCPP to /usr/local
USER root
RUN make install

# Building libfunctionality
USER bob
RUN mkdir /home/bob/libfun-build
WORKDIR /home/bob/libfun-build
RUN cmake ../libfunctionality/
RUN make
# Deploying libfunctionality to /usr/local
RUN cmake ../libfunctionality/ -DCMAKE_INSTALL_PREFIX=/home/bob/osvr-bin/
RUN make install
USER root
RUN cmake ../libfunctionality/
RUN make install

# Extra pass... Just a secret!
USER bob

# At last, building OSVR-Core
USER bob
RUN mkdir /home/bob/osvr-build
WORKDIR /home/bob/osvr-build
RUN cmake ../OSVR-Core -DCMAKE_INSTALL_PREFIX=/home/bob/osvr-bin/
RUN make install<commit_msg> - Make improvements to Dockerfile for building OSVR library<commit_after># Base it on good ol' trusty
FROM ubuntu:xenial
MAINTAINER hbirch

# List of system dependencies, rest come from git
RUN apt-get -y install software-properties-common

RUN bash -c "add-apt-repository \"deb http://archive.ubuntu.com/ubuntu $(lsb_release -sc) universe multiverse\""

RUN apt-get update

RUN apt-get -y install \
	git \
	build-essential \
	cmake \
	libopencv-dev \
	libboost-dev \
	libboost-thread-dev \
	libboost-system-dev \
	libboost-date-time-dev \
	libboost-chrono-dev \
	libboost-program-options-dev \
	libboost-filesystem-dev \
	libusb-1.0-0-dev \
	ninja-build

RUN useradd -m bob

USER bob
WORKDIR /home/bob

# Cloning repos
RUN git clone --recursive https://github.com/OSVR/OSVR-Core.git
RUN git clone --recursive https://github.com/OSVR/libfunctionality.git
RUN git clone --recursive https://github.com/VRPN/jsoncpp
RUN git clone --recursive https://github.com/OSVR/OSVR-Oculus-Rift.git

USER root

# Building JSONCPP
RUN mkdir /home/bob/json-build
WORKDIR /home/bob/json-build
RUN cmake ../jsoncpp/ -DJSONCPP_WITH_CMAKE_PACKAGE=ON -DJSONCPP_LIB_BUILD_SHARED=OFF -DCMAKE_CXX_FLAGS=-fPIC
RUN make
# Deploying JSONCPP to /usr/local
RUN make install

# Building libfunctionality
RUN mkdir /home/bob/libfun-build
WORKDIR /home/bob/libfun-build
RUN cmake ../libfunctionality/ -DBUILD_SHARED_LIBS=OFF -DCMAKE_CXX_FLAGS=-fPIC
RUN make
# Deploying libfunctionality to /usr/local
RUN make install

# At last, building OSVR-Core
RUN mkdir /home/bob/osvr-build
WORKDIR /home/bob/osvr-build
RUN cmake ../OSVR-Core -DCMAKE_CXX_FLAGS=-fPIC
RUN make
RUN make install
RUN cmake ../OSVR-Core -DCMAKE_INSTALL_PREFIX=/home/bob/osvr-bin/ -DCMAKE_CXX_FLAGS=-fPIC
RUN make install

# Build Oculus Rift support
RUN mkdir /home/bob/osvr-ovr-build
WORKDIR /home/bob/osvr-ovr-build
RUN cmake ../OSVR-Oculus-Rift -DCMAKE_INSTALL_PREFIX=/home/bob/osvr-bin/
RUN make install
{'fraction_non_alphanumeric': 0.1076017130620985, 'fraction_numerical': 0.0024089935760171306, 'mean_word_length': 3.8219354838709676, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 7, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '316273', 'n_tokens_mistral': 1431, 'n_tokens_neox': 1336, 'n_words': 353}