6 #include <msp/parser/loader.h>
10 #include "packageref.h"
17 class Loader: public Msp::Parser::Loader
21 Package &get_object() { return pkg; }
26 void require(const std::string &);
27 void program(const std::string &);
28 void library(const std::string &);
29 void headers(const std::string &);
33 Package(Builder &, const std::string &, const Msp::Path::Path &);
34 void set_path(const Msp::Path::Path &);
35 const std::string &get_name() const { return name; }
36 const Msp::Path::Path &get_source() const { return source; }
37 const ComponentList &get_components() const { return components; }
38 bool get_buildable() const { return buildable; }
39 const Config &get_config() const { return config; }
40 const PkgRefList &get_requires() const { return requires; }
41 const BuildInfo &get_build_info() const { return build_info; }
42 const BuildInfo &get_exported_binfo() const { return export_binfo; }
43 Builder &get_builder() const { return builder; }
44 bool get_need_path() const { return need_path; }
46 void create_build_info();
47 void process_options(const RawOptionMap &);
49 static Package *create(Builder &, const std::string &);
63 std::string description;
66 Msp::Path::Path source;
69 BuildInfo export_binfo;
70 ComponentList components;
72 bool build_info_ready;
77 Package(Builder &, const std::string &, const std::vector<std::string> &);
78 void init_buildable();
79 unsigned get_install_flags();