Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated README.md and updated required packages to include mio #6

Draft
wants to merge 13 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions .github/workflows/build_test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: C++ Build
'on':
push:
branches:
- master
pull_request:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Build C++ project
run: |
docker build -t ci_cd_image .
docker run ci_cd_image
57 changes: 57 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# Use Ubuntu as base image
FROM ubuntu:latest

# Set non-interactive mode
ENV DEBIAN_FRONTEND=noninteractive

# Update Ubuntu packages and install necessary dependencies
RUN apt-get update && apt-get install -y \
git \
cmake \
libeigen3-dev \
nlohmann-json3-dev \
libspdlog-dev \
build-essential \
zlib1g-dev\
&& rm -rf /var/lib/apt/lists/*

# Install Libzip
RUN git clone https://github.com/nih-at/libzip.git \
&& cd libzip \
&& mkdir build \
&& cd build \
&& cmake .. \
&& make \
&& make install

# Install Google Test v1.12.1
RUN git clone -b release-1.12.1 https://github.com/google/googletest.git \
&& cd googletest \
&& mkdir build \
&& cd build \
&& cmake .. \
&& make \
&& make install

# Install mio
RUN git clone -b master https://github.com/vimpunk/mio.git \
&& cd mio \
&& mkdir build \
&& cd build \
&& cmake .. \
&& make \
&& make install

#setting the working directory
WORKDIR /app

#Copy the project to the container
COPY . .

#Run and build the project
RUN mkdir build && \
cd build && \
cmake .. && \
make


25 changes: 20 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,31 @@
The C++ implementations to the memory-mapped tractography file format.

## Installation

### Dependencies

- c++11 compiler / cmake
- libzip
- nlohmann::json
- Eigen3
- spdlog
- libzip (version 1.10.1 downloaded from https://libzip.org/download/)
- nlohmann::json(version 3.11.3 cloned from https://github.com/nlohmann/json)
- Eigen3(version 3.4.0 from https://eigen.tuxfamily.org/index.php?title=Main_Page )
- spdlog(spd) [version: 1.13.0 cloned from https://github.com/gabime/spdlog)
- GTest (optional)
- mio (cloned from fhttps://github.com/vimpunk/mio/tree/master)

### Installing

`cmake . && make`

## How to use
COMING SOON

* Install all dependencies (after either cloning github repo or downloading) using these commands
* `mkdir build`
* `cd build`
* `cmake ..`
* `make`
* `make install`
* clone into this repo using `git clone https://github.com/tee-ar-ex/trx-cpp.git`
* To run trx_cpp:
* `cmake -B build`
* `cd build`
* `make`
1 change: 1 addition & 0 deletions tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ find_package (Eigen3 CONFIG REQUIRED)
find_package(nlohmann_json CONFIG REQUIRED)
find_package(spdlog CONFIG REQUIRED)
find_package(GTest CONFIG REQUIRED)
find_package(mio REQUIRED)

enable_testing()

Expand Down