Skip to content

Commit

Permalink
Applying mcm-update to xcfa-refactor (ftsrg#199)
Browse files Browse the repository at this point in the history
* Added mcm-udpate and xcfa-refactor files

* Updated copyright headers

* Fixed compilation errors

* Fixed tests

* Added dependencies for antlr and kotlin

* Added dependencies for antlr and kotlin

* Fixed bugs from Sonar
  • Loading branch information
leventeBajczi authored Jul 23, 2023
1 parent d26650e commit 4480126
Show file tree
Hide file tree
Showing 121 changed files with 3,374 additions and 3,089 deletions.
6 changes: 5 additions & 1 deletion buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import java.io.FileOutputStream
import org.jetbrains.kotlin.gradle.plugin.KotlinSourceSet
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile

Expand Down Expand Up @@ -90,6 +89,11 @@ fun generateVersionsSource(): String {
}

tasks {
withType<KotlinCompile>() {
kotlinOptions {
jvmTarget = "17"
}
}
val generateVersions by creating {
description = "Updates Versions.kt from project properties."
group = "build"
Expand Down
1 change: 0 additions & 1 deletion buildSrc/src/main/kotlin/antlr-grammar.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import java.nio.file.Files

apply<AntlrPlugin>()

Expand Down
17 changes: 17 additions & 0 deletions buildSrc/src/main/kotlin/kotlin-common.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,21 @@ tasks {
jvmTarget = "17"
}
}
}

// Check if "antlr-common" plugin is applied and if the "generateGrammarSource" task is available
// If yes, add a task dependency from "compileKotlin" to "generateGrammarSource"
project.plugins.withType<AntlrPlugin> {
val generateGrammarTask = tasks.findByName("generateGrammarSource")
if (generateGrammarTask != null) {
project.tasks.named("compileKotlin").configure {
dependsOn(generateGrammarTask)
}
}
val generateTestGrammarTask = tasks.findByName("generateTestGrammarSource")
if (generateTestGrammarTask != null) {
project.tasks.named("compileTestKotlin").configure {
dependsOn(generateTestGrammarTask)
}
}
}
4 changes: 3 additions & 1 deletion settings.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ include(

"xcfa/xcfa",
"xcfa/cat",
"xcfa/exec-graph-cli",
"xcfa/c2xcfa",
"xcfa/litmus2xcfa",
"xcfa/xcfa-analysis",
Expand All @@ -51,7 +52,8 @@ include(
"solver/solver",
"solver/solver-z3",
"solver/solver-smtlib",
"solver/solver-smtlib-cli"
"solver/solver-smtlib-cli",
"solver/graph-solver",
)

for (project in rootProject.children) {
Expand Down
1 change: 1 addition & 0 deletions subprojects/common/analysis/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,6 @@ dependencies {
implementation(project(":theta-common"))
implementation(project(":theta-core"))
implementation(project(":theta-solver"))
implementation(project(":theta-graph-solver"))
testImplementation(project(":theta-solver-z3"))
}

This file was deleted.

This file was deleted.

Loading

0 comments on commit 4480126

Please sign in to comment.