Skip to content

Instantly share code, notes, and snippets.

@Ben1980
Created April 6, 2019 19:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Ben1980/6f15404765bab84c3e38a262dbcbf4ee to your computer and use it in GitHub Desktop.
Save Ben1980/6f15404765bab84c3e38a262dbcbf4ee to your computer and use it in GitHub Desktop.
plugins {
id 'cpp-library'
}
library {
linkage = [Linkage.SHARED]
targetMachines = [
machines.windows.x86_64,
machines.macOS.x86_64,
machines.linux.x86_64
]
baseName = "greeter"
}
def fmtHeaders = file("$rootDir/../fmt/include")
components.main.binaries.whenElementFinalized { binary ->
project.dependencies {
if (binary.optimized) {
add(binary.includePathConfiguration.name, files(fmtHeaders))
} else {
add(binary.includePathConfiguration.name, files(fmtHeaders))
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment