MCPcopy Create free account
hub / github.com/algorithm-archivists/algorithm-archive / generate

Function generate

builders/kotlin.py:156–180  ·  view source on GitHub ↗

Add Builders and construction variables for kotlinc to an Environment.

(env)

Source from the content-addressed store, hash-verified

154
155
156def generate(env):
157 """Add Builders and construction variables for kotlinc to an Environment."""
158
159 env["KOTLINC"] = _detect(env)
160
161 env.SetDefault(
162 KOTLINC="kotlinc",
163 KOTLINSUFFIX=".kt",
164 KOTLINEXTENSION="Kt",
165 KOTLINCLASSSUFFIX=".class",
166 KOTLINJARSUFFIX=".jar",
167 KOTLINCFLAGS=SCons.Util.CLVar(),
168 KOTLINJARFLAGS=SCons.Util.CLVar(),
169 KOTLINRTJARFLAGS=SCons.Util.CLVar(["-include-runtime"]),
170 KOTLINCCOM="$KOTLINC $KOTLINCFLAGS $SOURCE",
171 KOTLINCCOMSTR="",
172 KOTLINJARCOM="$KOTLINC $KOTLINJARFLAGS -d $TARGET $SOURCE",
173 KOTLINJARCOMSTR="",
174 KOTLINRTJARCOM="$KOTLINC $KOTLINRTJARFLAGS -d $TARGET $SOURCE",
175 KOTLINRTJARCOMSTR="",
176 )
177
178 env.AddMethod(Kotlin, "Kotlin")
179 env.AddMethod(KotlinJar, "KotlinJar")
180 env.AddMethod(KotlinRuntimeJar, "KotlinRuntimeJar")
181
182
183def exists(env):

Callers

nothing calls this directly

Calls 1

_detectFunction · 0.70

Tested by

no test coverage detected