Skip to content

Commit

Permalink
windows fixes
Browse files Browse the repository at this point in the history
update chigraph
update minimum required cmake
char type fs
  • Loading branch information
russelltg committed Nov 29, 2019
1 parent 7960d4c commit f66c573
Show file tree
Hide file tree
Showing 4 changed files with 23 additions and 15 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
cmake_minimum_required(VERSION 3.0)
cmake_minimum_required(VERSION 3.10)

project(chigraph-gui)

Expand Down
2 changes: 1 addition & 1 deletion chigraph
Submodule chigraph updated 70 files
+3 −0 chi/CMakeLists.txt
+5 −0 lib/core/CMakeLists.txt
+1 −1 lib/core/src/BitcodeParser.cpp
+18 −14 lib/core/src/ClangFinder.cpp
+8 −4 lib/core/src/Context.cpp
+1 −1 lib/core/src/DefaultModuleCache.cpp
+1 −0 lib/core/src/FunctionCompiler.cpp
+2 −2 lib/core/src/GraphModule.cpp
+3 −0 lib/fetcher/CMakeLists.txt
+7 −4 lib/support/CMakeLists.txt
+4 −0 test/CMakeLists.txt
+4 −0 test/codegen/CMakeLists.txt
+3 −0 test/error/CMakeLists.txt
+81 −0 third_party/boost/include/boost/winapi/access_rights.hpp
+43 −0 third_party/boost/include/boost/winapi/apc.hpp
+290 −0 third_party/boost/include/boost/winapi/basic_types.hpp
+83 −0 third_party/boost/include/boost/winapi/bcrypt.hpp
+105 −0 third_party/boost/include/boost/winapi/character_code_conversion.hpp
+120 −0 third_party/boost/include/boost/winapi/condition_variable.hpp
+230 −0 third_party/boost/include/boost/winapi/config.hpp
+189 −0 third_party/boost/include/boost/winapi/critical_section.hpp
+188 −0 third_party/boost/include/boost/winapi/crypt.hpp
+171 −0 third_party/boost/include/boost/winapi/dbghelp.hpp
+58 −0 third_party/boost/include/boost/winapi/debugapi.hpp
+37 −0 third_party/boost/include/boost/winapi/detail/cast_ptr.hpp
+103 −0 third_party/boost/include/boost/winapi/directory_management.hpp
+238 −0 third_party/boost/include/boost/winapi/dll.hpp
+142 −0 third_party/boost/include/boost/winapi/environment.hpp
+3,178 −0 third_party/boost/include/boost/winapi/error_codes.hpp
+153 −0 third_party/boost/include/boost/winapi/error_handling.hpp
+190 −0 third_party/boost/include/boost/winapi/event.hpp
+594 −0 third_party/boost/include/boost/winapi/file_management.hpp
+259 −0 third_party/boost/include/boost/winapi/file_mapping.hpp
+31 −0 third_party/boost/include/boost/winapi/get_current_process.hpp
+30 −0 third_party/boost/include/boost/winapi/get_current_process_id.hpp
+31 −0 third_party/boost/include/boost/winapi/get_current_thread.hpp
+31 −0 third_party/boost/include/boost/winapi/get_current_thread_id.hpp
+30 −0 third_party/boost/include/boost/winapi/get_last_error.hpp
+60 −0 third_party/boost/include/boost/winapi/get_process_times.hpp
+60 −0 third_party/boost/include/boost/winapi/get_system_directory.hpp
+55 −0 third_party/boost/include/boost/winapi/get_thread_times.hpp
+59 −0 third_party/boost/include/boost/winapi/handle_info.hpp
+72 −0 third_party/boost/include/boost/winapi/handles.hpp
+83 −0 third_party/boost/include/boost/winapi/heap_memory.hpp
+120 −0 third_party/boost/include/boost/winapi/init_once.hpp
+146 −0 third_party/boost/include/boost/winapi/jobs.hpp
+49 −0 third_party/boost/include/boost/winapi/limits.hpp
+53 −0 third_party/boost/include/boost/winapi/local_memory.hpp
+19 −0 third_party/boost/include/boost/winapi/memory.hpp
+182 −0 third_party/boost/include/boost/winapi/mutex.hpp
+51 −0 third_party/boost/include/boost/winapi/overlapped.hpp
+54 −0 third_party/boost/include/boost/winapi/page_protection_flags.hpp
+318 −0 third_party/boost/include/boost/winapi/pipes.hpp
+75 −0 third_party/boost/include/boost/winapi/priority_class.hpp
+478 −0 third_party/boost/include/boost/winapi/process.hpp
+80 −0 third_party/boost/include/boost/winapi/security.hpp
+186 −0 third_party/boost/include/boost/winapi/semaphore.hpp
+151 −0 third_party/boost/include/boost/winapi/shell.hpp
+101 −0 third_party/boost/include/boost/winapi/show_window.hpp
+113 −0 third_party/boost/include/boost/winapi/srw_lock.hpp
+51 −0 third_party/boost/include/boost/winapi/stack_backtrace.hpp
+27 −0 third_party/boost/include/boost/winapi/synchronization.hpp
+87 −0 third_party/boost/include/boost/winapi/system.hpp
+42 −0 third_party/boost/include/boost/winapi/thread.hpp
+129 −0 third_party/boost/include/boost/winapi/thread_pool.hpp
+140 −0 third_party/boost/include/boost/winapi/time.hpp
+45 −0 third_party/boost/include/boost/winapi/timers.hpp
+60 −0 third_party/boost/include/boost/winapi/tls.hpp
+113 −0 third_party/boost/include/boost/winapi/wait.hpp
+145 −0 third_party/boost/include/boost/winapi/waitable_timer.hpp
32 changes: 20 additions & 12 deletions src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,10 @@ include(FeatureSummary)
find_package(Qt5 5.6.0 REQUIRED COMPONENTS Gui Script Xml Core Widgets Network PrintSupport Svg)
find_package(Qt5 5.6.0 COMPONENTS DBus)

find_package(KF5 REQUIRED COMPONENTS Archive TextEditor JobWidgets DBusAddons KIO Crash Sonnet SyntaxHighlighting Parts GuiAddons ItemViews Config ConfigWidgets Auth Codecs Completion GlobalAccel Service WindowSystem CoreAddons I18n XmlGui WidgetsAddons TextWidgets IconThemes)
find_package(KF5 REQUIRED COMPONENTS
Attica Archive TextEditor JobWidgets DBusAddons KIO Crash Sonnet SyntaxHighlighting
Parts GuiAddons ItemViews Config ConfigWidgets Auth Codecs Completion GlobalAccel
Service WindowSystem CoreAddons I18n XmlGui WidgetsAddons TextWidgets IconThemes)

set(CMAKE_CXX_STANDARD 17)

Expand Down Expand Up @@ -148,14 +151,14 @@ if(WIN32)
foreach(QTLIB
Qt5::Widgets Qt5::Core Qt5::Gui Qt5::Script
Qt5::Network Qt5::DBus Qt5::Svg Qt5::PrintSupport Qt5::Xml
KF5::Crash KF5::Parts KF5::KIOCore KF5::KIOWidgets
KF5::Attica KF5::Crash KF5::Parts KF5::KIOCore KF5::KIOWidgets
KF5::JobWidgets KF5::TextEditor KF5::SyntaxHighlighting
KF5::DBusAddons KF5::Archive KF5::ConfigWidgets
KF5::GuiAddons KF5::ItemViews KF5::Codecs KF5::Auth
KF5::Completion KF5::SonnetCore KF5::SonnetUi
KF5::Service KF5::ConfigGui KF5::ConfigCore KF5::WindowSystem
KF5::Service KF5::ConfigGui KF5::WindowSystem
KF5::GlobalAccel KF5::CoreAddons KF5::I18n KF5::XmlGui
KF5::WidgetsAddons KF5::TextWidgets KF5::IconThemes
KF5::WidgetsAddons KF5::TextWidgets KF5::IconThemes KF5::AuthCore
)

add_custom_command(
Expand All @@ -170,25 +173,30 @@ if(WIN32)

endforeach()

find_package(Intl REQUIRED)
get_filename_component(INTL_DIR ${Intl_LIBRARY} DIRECTORY)

# copy iconv.dll
find_file(INTL_DLL "intl.dll" HINTS "${INTL_DIR}/../bin") # "$<TARGET_FILE_DIR:Qt5::Widgets>" "$<TARGET_FILE_DIR:KF5::Attica>")

# copy libintl.dll
add_custom_command(
TARGET copydlls POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_CURRENT_SOURCE_DIR}/../third_party/iconv-win64/bin/iconv.dll
${INTL_DLL}
$<TARGET_FILE_DIR:chigraphgui>
COMMENT "Copying iconv from ${CMAKE_CURRENT_SOURCE_DIR}/../third_party/iconv-win64/bin/iconv.dll to $<TARGET_FILE_DIR:chigraphgui>"
COMMENT "Copying libitnl from ${INTL_DLL} to $<TARGET_FILE_DIR:chigraphgui>"
)

# copy libintl.dll

# copy clang
find_program(CLANG_EXE "clang")
add_custom_command(
TARGET copydlls POST_BUILD
COMMAND ${CMAKE_COMMAND} -E copy_if_different
${CMAKE_CURRENT_SOURCE_DIR}/../third_party/gettext-win64/bin/libintl.dll
${CLANG_EXE}
$<TARGET_FILE_DIR:chigraphgui>
COMMENT "Copying libitnl from ${CMAKE_CURRENT_SOURCE_DIR}/../third_party/gettext-win64/bin/libintl.dll to $<TARGET_FILE_DIR:chigraphgui>"
COMMENT "Copying clang from ${CLANG_EXE} to $<TARGET_FILE_DIR:chigraphgui>"
)

endif()

install(TARGETS chigraphgui DESTINATION bin)
Expand Down
2 changes: 1 addition & 1 deletion src/subprocessoutputview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ SubprocessOutputView::SubprocessOutputView(chi::GraphModule* module) : mModule(m

// write it to a temporary file
fs::path tempBitcodeFile = chi::makeTempPath(".bc");
LLVMWriteBitcodeToFile(*llmod, tempBitcodeFile.c_str());
LLVMWriteBitcodeToFile(*llmod, tempBitcodeFile.string().c_str());
setReadOnly(true);

std::filesystem::path chiPath =
Expand Down

0 comments on commit f66c573

Please sign in to comment.