6 #include <msp/datafile/objectloader.h>
10 Stores information about compiler command line parameters in a more abstract
11 form. Allows combining with other BuildInfos to support package dependencies.
18 FORCE_STATIC, //< Only accept static libraries
19 STATIC, //< Prefer static libraries but accept dynamic as well
20 DYNAMIC, //< Prefer dynamic libraries but accept static as well
21 FORCE_DYNAMIC //< Only accept dynamic libraries
24 class Loader: public Msp::DataFile::ObjectLoader<BuildInfo>
29 void incpath(const std::string &);
30 void define(const std::string &, const std::string &);
31 void libpath(const std::string &);
32 void library(const std::string &);
37 LOCAL, //< Include all information
38 DEPENDENCY, //< Include all but code generation options
39 CHAINED //< Include only compilation options
42 typedef std::map<std::string, std::string> DefineMap;
43 typedef std::list<Msp::FS::Path> PathList;
44 typedef std::list<std::string> WordList;
55 unsigned warning_level;
60 /** Updates the BuildInfo from another one. Lists are concatenated, with
61 the first occurrence of each item preserved. Scalars are overwritten.
63 The update level determines what information is updated. */
64 void update_from(const BuildInfo &, UpdateLevel = LOCAL);
67 /** Makes sure there are no duplicate entries in the lists. For warnings,
68 contradicting flags are eliminated and the last one stays in effect. */