Commit ed112464 authored by Robert Kimball's avatar Robert Kimball Committed by Scott Cyphers

Updates towards building on windows native (#1156)

* cmake runs for interpreter

* more updates towards building on windows
parent 82ee0a77
......@@ -76,6 +76,7 @@ config_args.txt
.nfs*
venv/
.vscode/
.vs/
# VisualGDB files
VisualGDB/
......
......@@ -149,7 +149,9 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -march=${NGRAPH_TARGET_ARCH}")
# flags required for SDL-3
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -O2 -fPIE -D_FORTIFY_SOURCE=2")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wformat -Wformat-security")
if (NOT WIN32)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wformat -Wformat-security")
endif()
if (NOT APPLE)
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -z noexecstack")
set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -z relro -z now")
......
......@@ -49,12 +49,12 @@ if (${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
set(MKLPACKAGE "mklml_lnx_${MKLVERSION}.tgz")
set(MKL_SHA1_HASH aea0d9ce65773cfcf5d8292b8db553bde965fc8f)
set(MKL_LIBS libiomp5.so libmklml_intel.so)
elseif (${CMAKE_SYSTEM_NAME} STREQUAL "Darwin")
elseif (APPLE)
set(MKLPACKAGE "mklml_mac_${MKLVERSION}.tgz")
set(MKL_SHA1_HASH d76083fd5a79767a96572ad0e23e7f4c892818f2)
set(MKL_LIBS libmklml.dylib libiomp5.dylib)
elseif (${CMAKE_SYSTEM_NAME} STREQUAL "Windows")
set(MKLPACKAGE "mklml_win_${MKLVERSION}.tgz")
elseif (WIN32)
set(MKLPACKAGE "mklml_win_${MKLVERSION}.zip")
set(MKL_SHA1_HASH d607ca92d7bfc101f0828c0b005098b75531669b)
set(MKL_LIBS mklml.dll libiomp5md.dll)
endif()
......
......@@ -144,7 +144,7 @@ set (SRC
)
message(STATUS ${CMAKE_CURRENT_SOURCE_DIR}/op)
file(GLOB OPS "${CMAKE_CURRENT_SOURCE_DIR}/op" "${CMAKE_CURRENT_SOURCE_DIR}/op/*.hpp")
file(GLOB OPS "${CMAKE_CURRENT_SOURCE_DIR}/op/" "${CMAKE_CURRENT_SOURCE_DIR}/op/*.hpp")
foreach(OP ${OPS})
file(STRINGS ${OP} OP_CLASS REGEX "class [A-Za-z0-9_]+ :")
foreach(LINE ${OP_CLASS})
......
......@@ -115,14 +115,14 @@ vector<string> op::Constant::get_value_strings() const
}
else if (m_element_type == element::u8)
{
for (uint value : get_vector<uint8_t>())
for (uint32_t value : get_vector<uint8_t>())
{
rc.push_back(to_string(value));
}
}
else if (m_element_type == element::u16)
{
for (uint value : get_vector<uint16_t>())
for (uint32_t value : get_vector<uint16_t>())
{
rc.push_back(to_string(value));
}
......
......@@ -28,5 +28,8 @@ if (NGRAPH_INTERPRETER_ENABLE)
target_link_libraries(interpreter_backend PUBLIC ngraph)
set_target_properties(interpreter_backend PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${NGRAPH_BUILD_DIR})
install(TARGETS interpreter_backend LIBRARY DESTINATION ${NGRAPH_INSTALL_LIB})
install(TARGETS interpreter_backend
LIBRARY DESTINATION "${NGRAPH_INSTALL_LIB}"
ARCHIVE DESTINATION "${NGRAPH_INSTALL_LIB}"
)
endif()
......@@ -20,7 +20,6 @@
#include <iostream>
#include <string>
#include <sys/stat.h>
#include <sys/time.h>
#include <vector>
std::string trim(const std::string& s);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment