Skip to content
Snippets Groups Projects
Commit b4abc73b authored by Mayank Rathee's avatar Mayank Rathee
Browse files

Completed shift to CMake

parent beb72446
No related branches found
No related tags found
No related merge requests found
cmake_minimum_required (VERSION 3.0) cmake_minimum_required (VERSION 3.0)
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
if(APPLE) if(APPLE)
set(CMAKE_C_COMPILER "/usr/local/bin/gcc-9") set(CMAKE_C_COMPILER "/usr/local/bin/gcc-9")
set(CMAKE_CXX_COMPILER "/usr/local/bin/g++-9") set(CMAKE_CXX_COMPILER "/usr/local/bin/g++-9")
endif() endif()
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/bin)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
project(Porthos) project(Porthos)
set(NAME "Porthos") set(NAME "Porthos")
...@@ -24,13 +27,16 @@ target_link_libraries(Porthos-Protocols ...@@ -24,13 +27,16 @@ target_link_libraries(Porthos-Protocols
PUBLIC OpenMP::OpenMP_CXX PUBLIC OpenMP::OpenMP_CXX
${OPENSSL_LIBRARIES}) ${OPENSSL_LIBRARIES})
add_executable(Porthos3PC ${CMAKE_CURRENT_SOURCE_DIR}/example_neural_nets/mainResNet50.cpp) macro (add_network _name)
target_link_libraries(Porthos3PC Porthos-Protocols) add_executable(${_name} ${CMAKE_CURRENT_SOURCE_DIR}/example_neural_nets/main${_name}.cpp)
target_link_libraries(${_name} Porthos-Protocols)
endmacro()
target_compile_options(Porthos-Protocols target_compile_options(Porthos-Protocols
PUBLIC "-pthread;-Wall;-march=native;-msse4.1;-maes;-mpclmul;-mrdseed;-fpermissive;-fpic;-std=c++17;-w;-O3") PUBLIC "-pthread;-Wall;-march=native;-msse4.1;-maes;-mpclmul;-mrdseed;-fpermissive;-fpic;-std=c++17;-w;-O3")
target_compile_options(Porthos3PC add_network(DenseNet121)
PRIVATE "-pthread;-Wall;-march=native;-msse4.1;-maes;-mpclmul;-mrdseed;-fpermissive;-fpic;-std=c++17;-w;-O3") add_network(ResNet50)
add_network(SqNetImgNet)
//Which network to run //Which network to run
//New set of main files - choose which one to run //New set of main files - choose which one to run
//#define F_RESNET50 #define F_RESNET50
//#define F_DENSENET121 #define F_DENSENET121
//#define F_SQUEEZENET_IMAGENET #define F_SQUEEZENET_IMAGENET
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