Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add build for B-lang-org/bsc-contrib repo as 'bluespec-libraries' target, also add 'bluespec' alias #404

Merged
merged 2 commits into from
Aug 12, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions pycheribuild/projects/bluespec_compiler.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
# SUCH DAMAGE.
#
from .project import DefaultInstallDir, GitRepository, MakeCommandKind, Project
from .simple_project import TargetAliasWithDependencies
from ..utils import OSInfo


Expand Down Expand Up @@ -86,3 +87,26 @@ def install(self, **kwargs):

def run_tests(self) -> None:
self.run_cmd("check-smoke")


class BuildBluespecLibraries(Project):
target = "bluespec-libraries"
dependencies = ("bluespec-compiler",)
default_directory_basename = "bsc-contrib"
repository = GitRepository("https://github.com/B-Lang-org/bsc-contrib.git")
native_install_dir = DefaultInstallDir.BOOTSTRAP_TOOLS
build_in_source_dir = True
make_kind = MakeCommandKind.GnuMake

def compile(self, **kwargs):
self.make_args.set(PREFIX=self.install_dir)
self.run_make("all")

def clean(self):
self.make_args.set(PREFIX=self.install_dir)
self.run_make("full_clean", cwd=self.source_dir)


class BuildBluespec(TargetAliasWithDependencies):
target = "bluespec"
dependencies = ("bluespec-libraries",)
Loading