// tag::apply-plugin[] apply plugin: 'objective-c' // end::apply-plugin[] // tag::executables[] model { components { main(NativeExecutableSpec) } } // end::executables[] // tag::all-binaries[] model { binaries { all { //on macOS we need different settings than on Linux or Windows if (targetPlatform.operatingSystem.macOsX) { linker.args "-framework", "Foundation" } else { objcCompiler.args "-I/usr/include/GNUstep", "-fconstant-string-class=NSConstantString", "-D_NATIVE_OBJC_EXCEPTIONS" linker.args "-lgnustep-base", "-lobjc" } } } } // end::all-binaries[]