Skip to content
Snippets Groups Projects
Commit f40c228b authored by mathieusalz's avatar mathieusalz
Browse files

Created git repository using PCSC template

parents
No related branches found
No related tags found
No related merge requests found
[submodule "googletest"]
path = googletest
url = https://github.com/google/googletest.git
cmake_minimum_required (VERSION 3.0)
project (PCSC-project)
set(CMAKE_CXX_STANDARD 17)
add_library(pcsc
src/pcsc.cc
)
add_subdirectory(googletest)
add_executable(main src/main.cc)
target_link_libraries(main pcsc)
add_executable(test_pcsc test/test.cc)
target_link_libraries(test_pcsc gtest_main gtest pthread pcsc)
add_custom_target(test ./test_pcsc DEPENDS test_pcsc)
This is a template project structure for the *Programming concepts in scientific computing* (MATH-458)
In order to compile it you should first install *googletest*
```
git submodule update --init
```
Then, building is done as usual, e.g. with CLion or in the terminal:
```
mkdir build
cd build
cmake ..
make
```
{"requests":[{"kind":"cache","version":2},{"kind":"codemodel","version":2},{"kind":"toolchains","version":1},{"kind":"cmakeFiles","version":1}]}
\ No newline at end of file
#include "pcsc.hh"
#include <iostream>
int main(int argc, char **argv) {}
#include "pcsc.hh"
int foo() { return 2; }
#ifndef __PCSC__HH__
#define __PCSC__HH__
int foo();
#endif
#include <cmath>
#include <gtest/gtest.h>
TEST(sqrt, integer) { EXPECT_EQ(2, std::sqrt(4)); }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment