aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMiodrag Milanovic <mmicko@gmail.com>2018-07-16 08:07:57 +0200
committerMiodrag Milanovic <mmicko@gmail.com>2018-07-16 08:07:57 +0200
commit29df566a60e575462a8dd96a1d405f7d5632f38d (patch)
tree3fb1fc013dd91f5bc843715d8ef0b46c62dc9c06
parent5531546d6bcf188c27449b6256108c6c722b5b5b (diff)
downloadnextpnr-29df566a60e575462a8dd96a1d405f7d5632f38d.tar.gz
nextpnr-29df566a60e575462a8dd96a1d405f7d5632f38d.tar.bz2
nextpnr-29df566a60e575462a8dd96a1d405f7d5632f38d.zip
Fix MSVC build
-rw-r--r--CMakeLists.txt5
-rw-r--r--gui/fpgaviewwidget.cc8
2 files changed, 8 insertions, 5 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 3ca7935e..c8ee6805 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -214,7 +214,10 @@ foreach (family ${ARCH})
# Include family-specific source files to all family targets and set defines appropriately
target_include_directories(${target} PRIVATE ${family}/ ${CMAKE_CURRENT_BINARY_DIR}/generated/)
target_compile_definitions(${target} PRIVATE NEXTPNR_NAMESPACE=nextpnr_${family} ARCH_${ufamily} ARCHNAME=${family})
- target_link_libraries(${target} LINK_PUBLIC ${Boost_LIBRARIES} pthread)
+ target_link_libraries(${target} LINK_PUBLIC ${Boost_LIBRARIES})
+ if (NOT MSVC)
+ target_link_libraries(${target} LINK_PUBLIC pthread)
+ endif()
add_sanitizers(${target})
if (BUILD_GUI)
target_include_directories(${target} PRIVATE gui/${family}/ gui/)
diff --git a/gui/fpgaviewwidget.cc b/gui/fpgaviewwidget.cc
index 2d8d4cef..3ac69463 100644
--- a/gui/fpgaviewwidget.cc
+++ b/gui/fpgaviewwidget.cc
@@ -400,10 +400,10 @@ void FPGAViewWidget::paintGL()
}
lineShader_.draw(grid, gridColor_, thick1Px, matrix);
- LineShaderData shaders[4] = {[GraphicElement::G_FRAME] = LineShaderData(),
- [GraphicElement::G_HIDDEN] = LineShaderData(),
- [GraphicElement::G_INACTIVE] = LineShaderData(),
- [GraphicElement::G_ACTIVE] = LineShaderData()};
+ LineShaderData shaders[4] = {LineShaderData(),
+ LineShaderData(),
+ LineShaderData(),
+ LineShaderData()};
if (ctx_) {
// Draw Bels.