Use Go modules for building libsyncthing
Requires Go 1.11 or later
This commit is contained in:
parent
2f081bd28b
commit
4cabaf0c4b
|
@ -1,5 +1,4 @@
|
|||
# C++ objects and libs
|
||||
|
||||
*.slo
|
||||
*.lo
|
||||
*.o
|
||||
|
@ -11,7 +10,6 @@
|
|||
*.dylib
|
||||
|
||||
# Qt-es
|
||||
|
||||
/.qmake.cache
|
||||
/.qmake.stash
|
||||
*.pro.user
|
||||
|
@ -27,13 +25,15 @@ Makefile*
|
|||
*-build-*
|
||||
|
||||
# QtCreator
|
||||
|
||||
*.autosave
|
||||
|
||||
#QtCtreator Qml
|
||||
# QtCtreator Qml
|
||||
*.qmlproject.user
|
||||
*.qmlproject.user.*
|
||||
|
||||
# Go modules
|
||||
/libsyncthing/go/pkg
|
||||
|
||||
# Dolphin
|
||||
.directory
|
||||
|
||||
|
|
|
@ -91,6 +91,7 @@ message(STATUS "Syncthing's go files: ${SRC_FILES_SYNCTHING}")
|
|||
# generate Syncthing's assets: don't set GOARCH/GOOS here, this is supposed to run on the host
|
||||
add_custom_command(OUTPUT "${SYNCTHING_PATH}/lib/auto/gui.files.go"
|
||||
COMMAND "GOPATH=${GO_DEVELOPMENT_PATH}"
|
||||
"GO111MODULE=on"
|
||||
"${GO_BIN}"
|
||||
run
|
||||
./script/genassets.go
|
||||
|
@ -110,6 +111,7 @@ add_custom_command(OUTPUT "${CMAKE_CURRENT_BINARY_DIR}/libsyncthinginternal.a"
|
|||
"GOOS=${GO_TARGET_OS}"
|
||||
"GOARCH=${GO_TARGET_ARCH}"
|
||||
"CGO_ENABLED=1"
|
||||
"GO111MODULE=on"
|
||||
"GOPATH=${GO_DEVELOPMENT_PATH}"
|
||||
"${GO_BIN}"
|
||||
build
|
||||
|
|
Loading…
Reference in New Issue