Skip to content

Commit

Permalink
Fix coreutils in container + fix phasar-llvm --> phasar-cli
Browse files Browse the repository at this point in the history
  • Loading branch information
fabianbs96 committed Mar 27, 2024
1 parent 7b2ec98 commit 8a31f1e
Show file tree
Hide file tree
Showing 2 changed files with 152 additions and 32 deletions.
180 changes: 150 additions & 30 deletions varats/varats/projects/c_projects/wc.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,20 @@ class WC(VProject):
]

CONTAINER = get_base_image(ImageBase.DEBIAN_10).run(
'apt', 'install', '-y', 'autoconf', 'autopoint', 'wget', 'gettext',
'texinfo', 'rsync', 'automake', 'autotools-dev', 'pkg-config', 'gperf'
'apt',
'install',
'-y',
'autoconf',
'autopoint',
'wget',
'gettext',
'texinfo',
'rsync',
'automake',
'autotools-dev',
'pkg-config',
'gperf',
'bison',
)

@staticmethod
Expand All @@ -64,7 +76,7 @@ def compile(self) -> None:
with local.cwd(wc_source):
git("submodule", "init")
git("submodule", "update")
with local.env(CC=str(cc_compiler)):
with local.env(CC=str(cc_compiler), FORCE_UNSAFE_CONFIGURE=1):
bb.watch(local["./bootstrap"])()
bb.watch(local["./configure"])("--disable-gcc-warnings")

Expand All @@ -91,8 +103,20 @@ class LS(VProject):
]

CONTAINER = get_base_image(ImageBase.DEBIAN_10).run(
'apt', 'install', '-y', 'autoconf', 'autopoint', 'wget', 'gettext',
'texinfo', 'rsync', 'automake', 'autotools-dev', 'pkg-config', 'gperf'
'apt',
'install',
'-y',
'autoconf',
'autopoint',
'wget',
'gettext',
'texinfo',
'rsync',
'automake',
'autotools-dev',
'pkg-config',
'gperf',
'bison',
)

@staticmethod
Expand All @@ -116,7 +140,7 @@ def compile(self) -> None:
with local.cwd(wc_source):
git("submodule", "init")
git("submodule", "update")
with local.env(CC=str(cc_compiler)):
with local.env(CC=str(cc_compiler), FORCE_UNSAFE_CONFIGURE=1):
bb.watch(local["./bootstrap"])()
bb.watch(local["./configure"])("--disable-gcc-warnings")

Expand All @@ -143,8 +167,20 @@ class CAT(VProject):
]

CONTAINER = get_base_image(ImageBase.DEBIAN_10).run(
'apt', 'install', '-y', 'autoconf', 'autopoint', 'wget', 'gettext',
'texinfo', 'rsync', 'automake', 'autotools-dev', 'pkg-config', 'gperf'
'apt',
'install',
'-y',
'autoconf',
'autopoint',
'wget',
'gettext',
'texinfo',
'rsync',
'automake',
'autotools-dev',
'pkg-config',
'gperf',
'bison',
)

@staticmethod
Expand All @@ -168,7 +204,7 @@ def compile(self) -> None:
with local.cwd(wc_source):
git("submodule", "init")
git("submodule", "update")
with local.env(CC=str(cc_compiler)):
with local.env(CC=str(cc_compiler), FORCE_UNSAFE_CONFIGURE=1):
bb.watch(local["./bootstrap"])()
bb.watch(local["./configure"])("--disable-gcc-warnings")

Expand All @@ -195,8 +231,20 @@ class CP(VProject):
]

CONTAINER = get_base_image(ImageBase.DEBIAN_10).run(
'apt', 'install', '-y', 'autoconf', 'autopoint', 'wget', 'gettext',
'texinfo', 'rsync', 'automake', 'autotools-dev', 'pkg-config', 'gperf'
'apt',
'install',
'-y',
'autoconf',
'autopoint',
'wget',
'gettext',
'texinfo',
'rsync',
'automake',
'autotools-dev',
'pkg-config',
'gperf',
'bison',
)

@staticmethod
Expand All @@ -220,7 +268,7 @@ def compile(self) -> None:
with local.cwd(wc_source):
git("submodule", "init")
git("submodule", "update")
with local.env(CC=str(cc_compiler)):
with local.env(CC=str(cc_compiler), FORCE_UNSAFE_CONFIGURE=1):
bb.watch(local["./bootstrap"])()
bb.watch(local["./configure"])("--disable-gcc-warnings")

Expand All @@ -247,8 +295,20 @@ class WHOAMI(VProject):
]

CONTAINER = get_base_image(ImageBase.DEBIAN_10).run(
'apt', 'install', '-y', 'autoconf', 'autopoint', 'wget', 'gettext',
'texinfo', 'rsync', 'automake', 'autotools-dev', 'pkg-config', 'gperf'
'apt',
'install',
'-y',
'autoconf',
'autopoint',
'wget',
'gettext',
'texinfo',
'rsync',
'automake',
'autotools-dev',
'pkg-config',
'gperf',
'bison',
)

@staticmethod
Expand All @@ -272,7 +332,7 @@ def compile(self) -> None:
with local.cwd(wc_source):
git("submodule", "init")
git("submodule", "update")
with local.env(CC=str(cc_compiler)):
with local.env(CC=str(cc_compiler), FORCE_UNSAFE_CONFIGURE=1):
bb.watch(local["./bootstrap"])()
bb.watch(local["./configure"])("--disable-gcc-warnings")

Expand All @@ -299,8 +359,20 @@ class DD(VProject):
]

CONTAINER = get_base_image(ImageBase.DEBIAN_10).run(
'apt', 'install', '-y', 'autoconf', 'autopoint', 'wget', 'gettext',
'texinfo', 'rsync', 'automake', 'autotools-dev', 'pkg-config', 'gperf'
'apt',
'install',
'-y',
'autoconf',
'autopoint',
'wget',
'gettext',
'texinfo',
'rsync',
'automake',
'autotools-dev',
'pkg-config',
'gperf',
'bison',
)

@staticmethod
Expand All @@ -324,7 +396,7 @@ def compile(self) -> None:
with local.cwd(wc_source):
git("submodule", "init")
git("submodule", "update")
with local.env(CC=str(cc_compiler)):
with local.env(CC=str(cc_compiler), FORCE_UNSAFE_CONFIGURE=1):
bb.watch(local["./bootstrap"])()
bb.watch(local["./configure"])("--disable-gcc-warnings")

Expand All @@ -351,8 +423,20 @@ class FOLD(VProject):
]

CONTAINER = get_base_image(ImageBase.DEBIAN_10).run(
'apt', 'install', '-y', 'autoconf', 'autopoint', 'wget', 'gettext',
'texinfo', 'rsync', 'automake', 'autotools-dev', 'pkg-config', 'gperf'
'apt',
'install',
'-y',
'autoconf',
'autopoint',
'wget',
'gettext',
'texinfo',
'rsync',
'automake',
'autotools-dev',
'pkg-config',
'gperf',
'bison',
)

@staticmethod
Expand All @@ -376,7 +460,7 @@ def compile(self) -> None:
with local.cwd(wc_source):
git("submodule", "init")
git("submodule", "update")
with local.env(CC=str(cc_compiler)):
with local.env(CC=str(cc_compiler), FORCE_UNSAFE_CONFIGURE=1):
bb.watch(local["./bootstrap"])()
bb.watch(local["./configure"])("--disable-gcc-warnings")

Expand All @@ -403,8 +487,20 @@ class JOIN(VProject):
]

CONTAINER = get_base_image(ImageBase.DEBIAN_10).run(
'apt', 'install', '-y', 'autoconf', 'autopoint', 'wget', 'gettext',
'texinfo', 'rsync', 'automake', 'autotools-dev', 'pkg-config', 'gperf'
'apt',
'install',
'-y',
'autoconf',
'autopoint',
'wget',
'gettext',
'texinfo',
'rsync',
'automake',
'autotools-dev',
'pkg-config',
'gperf',
'bison',
)

@staticmethod
Expand All @@ -428,7 +524,7 @@ def compile(self) -> None:
with local.cwd(wc_source):
git("submodule", "init")
git("submodule", "update")
with local.env(CC=str(cc_compiler)):
with local.env(CC=str(cc_compiler), FORCE_UNSAFE_CONFIGURE=1):
bb.watch(local["./bootstrap"])()
bb.watch(local["./configure"])("--disable-gcc-warnings")

Expand All @@ -455,8 +551,20 @@ class KILL(VProject):
]

CONTAINER = get_base_image(ImageBase.DEBIAN_10).run(
'apt', 'install', '-y', 'autoconf', 'autopoint', 'wget', 'gettext',
'texinfo', 'rsync', 'automake', 'autotools-dev', 'pkg-config', 'gperf'
'apt',
'install',
'-y',
'autoconf',
'autopoint',
'wget',
'gettext',
'texinfo',
'rsync',
'automake',
'autotools-dev',
'pkg-config',
'gperf',
'bison',
)

@staticmethod
Expand All @@ -480,7 +588,7 @@ def compile(self) -> None:
with local.cwd(wc_source):
git("submodule", "init")
git("submodule", "update")
with local.env(CC=str(cc_compiler)):
with local.env(CC=str(cc_compiler), FORCE_UNSAFE_CONFIGURE=1):
bb.watch(local["./bootstrap"])()
bb.watch(local["./configure"])("--disable-gcc-warnings")

Expand All @@ -507,8 +615,20 @@ class UNIQ(VProject):
]

CONTAINER = get_base_image(ImageBase.DEBIAN_10).run(
'apt', 'install', '-y', 'autoconf', 'autopoint', 'wget', 'gettext',
'texinfo', 'rsync', 'automake', 'autotools-dev', 'pkg-config', 'gperf'
'apt',
'install',
'-y',
'autoconf',
'autopoint',
'wget',
'gettext',
'texinfo',
'rsync',
'automake',
'autotools-dev',
'pkg-config',
'gperf',
'bison',
)

@staticmethod
Expand All @@ -532,7 +652,7 @@ def compile(self) -> None:
with local.cwd(wc_source):
git("submodule", "init")
git("submodule", "update")
with local.env(CC=str(cc_compiler)):
with local.env(CC=str(cc_compiler), FORCE_UNSAFE_CONFIGURE=1):
bb.watch(local["./bootstrap"])()
bb.watch(local["./configure"])("--disable-gcc-warnings")

Expand Down
4 changes: 2 additions & 2 deletions varats/varats/tools/research_tools/vara.py
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ def build(
)

def get_install_binaries(self) -> tp.List[str]:
return ["bin/clang++", "bin/opt", "bin/phasar-llvm"]
return ["bin/clang++", "bin/opt", "bin/phasar-cli"]

def verify_install(self, install_location: Path) -> bool:
"""
Expand All @@ -392,7 +392,7 @@ def verify_install(self, install_location: Path) -> bool:
status_ok &= vara_name in stdout

# Check that phasar-cli can display its version
phasar_cli = local[str(install_location / "bin/phasar-llvm")]
phasar_cli = local[str(install_location / "bin/phasar-cli")]
ret, stdout, _ = phasar_cli.run("--version")
status_ok &= ret == 0

Expand Down

0 comments on commit 8a31f1e

Please sign in to comment.