1
1
mirror of https://github.com/ariya/phantomjs.git synced 2024-10-05 16:57:15 +03:00

Fix building on Windows using MinGW (#15405)

This commit is contained in:
Ariya Hidayat 2019-12-31 01:30:37 -08:00
parent 8542540d09
commit 0e3c01252e

View File

@ -25,7 +25,12 @@ include_directories(src/linenoise/src)
include_directories(src/mongoose)
include_directories(src/qcommandline)
set(EXTRA_LIBS dl)
if (WIN32)
set(EXTRA_LIBS ws2_32)
add_definitions(-DQCOMMANDLINE_STATIC)
else()
set(EXTRA_LIBS dl)
endif()
add_executable(${PROJECT_NAME} src/phantomjs.qrc ${PHANTOMJS_SOURCES} ${THIRDPARTY_SOURCES})
target_link_libraries(${PROJECT_NAME} ${EXTRA_LIBS} Qt5::Core Qt5::Network Qt5::WebKitWidgets Threads::Threads)