MCPcopy Create free account
hub / github.com/celer-pkg/celer / InitBuildSystem

Method InitBuildSystem

buildsystems/buildconfig.go:728–760  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

726}
727
728func (b *BuildConfig) InitBuildSystem() error {
729 name, _, _, err := b.parseBuildSystem(b.BuildSystem)
730 if err != nil {
731 return err
732 }
733
734 switch name {
735 case "cmake":
736 b.buildSystem = NewCMake(b)
737 case "makefiles":
738 b.buildSystem = NewMakefiles(b)
739 case "meson":
740 b.buildSystem = NewMeson(b)
741 case "b2":
742 b.buildSystem = NewB2(b)
743 case "gyp":
744 b.buildSystem = NewGyp(b)
745 case "qmake":
746 b.buildSystem = NewQMake(b)
747 case "prebuilt":
748 b.buildSystem = NewPrebuilt(b)
749 case "nobuild":
750 b.buildSystem = NewNoBuild(b)
751 case "custom":
752 b.buildSystem = NewCustom(b)
753 default:
754 return fmt.Errorf("unsupported build system for %s", b.BuildSystem)
755 }
756
757 // Merges the platform-specific fields into the BuildConfig struct.
758 b.mergeConfig()
759 return nil
760}
761
762func (b *BuildConfig) CheckTools() []string {
763 return b.buildSystem.CheckTools()

Callers 1

initBuildConfigMethod · 0.80

Calls 11

parseBuildSystemMethod · 0.95
mergeConfigMethod · 0.95
NewCMakeFunction · 0.85
NewMakefilesFunction · 0.85
NewMesonFunction · 0.85
NewB2Function · 0.85
NewGypFunction · 0.85
NewQMakeFunction · 0.85
NewPrebuiltFunction · 0.85
NewNoBuildFunction · 0.85
NewCustomFunction · 0.85

Tested by

no test coverage detected