summaryrefslogtreecommitdiffhomepage
path: root/examples/example_02_libnebuild/libnebuild.cc
blob: df5258be67634986d568f015a85cc6deed99ccf0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#include <NeBuildKit/JSONManifestBuilder.h>
#include <cstdlib>

#ifndef _WIN32
static constexpr auto kPath = "./posix.json";
#else
static constexpr auto kPath = ".\\win64.json";
#endif

int main(int argc, char** argv) {
  auto builder = new NeBuild::JSONManifestBuilder();
  if (!builder) return EXIT_FAILURE;

  NeBuild::BuildConfig config;
  config.path_ = kPath;
  config.dry_run_ = false;

  return builder->BuildTarget(config);
}