GuiLite/workspace/Gradle/build.gradle
2020-01-23 23:26:50 +08:00

37 lines
917 B
Groovy

plugins {
id("org.gradle.cpp-library")
}
library {
/**
* Gradle stipulates that the source directory is: $project/src/main/cpp/,
* specifies the `.cpp` source file directory according to the project.
* */
source.from(
"../core",
"../widgets"
)
/**
* Gradle conventions the header file directory is: $project/src/main/headers/,
* specify the `.h` header file directory according to the project.
*/
privateHeaders.from(
"../core_include",
"../widgets_include"
)
/**
* Gradle only exports shared libraries(dynamic libraries) by default,
* adds support for static libraries.
* */
linkage.add(Linkage.STATIC)
}
/**
* Compile tasks for custom release type dynamic and static libraries
* */
tasks.register("produce") {
dependsOn(
"assembleReleaseShared",
"assembleReleaseStatic"
)
}