diff options
author | Karen Arutyunov <karen@codesynthesis.com> | 2022-06-20 20:59:53 +0300 |
---|---|---|
committer | Karen Arutyunov <karen@codesynthesis.com> | 2022-06-23 12:35:42 +0300 |
commit | c0ca17391c41048cd1db19f0aa08e060624f4bd1 (patch) | |
tree | 4037ed4be1abf8f4b85e7e5420c3cac2d2f10503 /bpkg/package-skeleton.cxx | |
parent | 2ee693000ff6ea44cfd4fc51c7b058258056610a (diff) |
Add support for additional *-build package manifest values and alternative buildfile naming
Diffstat (limited to 'bpkg/package-skeleton.cxx')
-rw-r--r-- | bpkg/package-skeleton.cxx | 22 |
1 files changed, 20 insertions, 2 deletions
diff --git a/bpkg/package-skeleton.cxx b/bpkg/package-skeleton.cxx index d58c846..a3e0b5a 100644 --- a/bpkg/package-skeleton.cxx +++ b/bpkg/package-skeleton.cxx @@ -2501,7 +2501,10 @@ namespace bpkg // additional files. // { - path bf (skl.src_root_ / std_bootstrap_file); + bool an (*ap.alt_naming); + + path bf (skl.src_root_ / + (an ? alt_bootstrap_file : std_bootstrap_file)); mk_p (bf.directory ()); @@ -2524,7 +2527,22 @@ namespace bpkg save (*ap.bootstrap_build, bf); if (ap.root_build) - save (*ap.root_build, skl.src_root_ / std_root_file); + save (*ap.root_build, + skl.src_root_ / (an ? alt_root_file : std_root_file)); + + for (const buildfile& f: ap.buildfiles) + { + path p (skl.src_root_ / + (an ? alt_build_dir : std_build_dir) / + f.path); + + p += "."; + p += (an ? alt_build_ext : std_build_ext); + + mk_p (p.directory ()); + + save (f.content, p); + } } // Create the manifest file containing the bare minimum of values |