-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[No Deploy] opensource COBOL 4Jをビルドできるように変更 (#38)
- Loading branch information
1 parent
5dea9ff
commit 1a197de
Showing
3 changed files
with
33 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,3 @@ | ||
# Ignore Gradle project-specific cache directory | ||
.gradle | ||
|
||
# Ignore Gradle build output directory | ||
build | ||
compiler_bin |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
plugins { | ||
id("cpp-application") | ||
} | ||
|
||
|
||
// opensource COBOL 4J のビルドタスクを追加 | ||
tasks.register<Exec>("buildCompiler") { | ||
group = "build" | ||
description = "Build opensource COBOL 4J" | ||
|
||
//// 作業ディレクトリを指定 | ||
workingDir = file("${project.projectDir}/opensourcecobol4j/") | ||
|
||
// 入力ファイルと出力ファイルを指定 | ||
inputs.files(fileTree("${project.projectDir}/opensourcecobol4j")) | ||
outputs.file("${project.projectDir}/compiler_bin/lib/opensourcecobol4j/libcobj.jar") | ||
|
||
// 実行コマンドを指定 | ||
commandLine("sh", "-c", """ | ||
mkdir -p ${project.projectDir}/compiler_bin && | ||
./configure --prefix=${project.projectDir}/compiler_bin && | ||
make && | ||
make install | ||
""".trimIndent()) | ||
} | ||
|
||
tasks.named("build").configure { | ||
dependsOn("buildCompiler") | ||
} |