aboutsummaryrefslogtreecommitdiff
path: root/include/GlobalLib.hpp
blob: 78511c3d106af26dca9a8b5df42c2280afe04f79 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#ifndef SIBS_GLOBALLIB_HPP
#define SIBS_GLOBALLIB_HPP

#include "Result.hpp"
#include "Linker.hpp"
#include "Dependency.hpp"

namespace sibs
{
    class GlobalLib
    {
    public:
        enum DependencyError
        {
            DEPENDENCY_NOT_FOUND = 10,
            DEPENDENCY_VERSION_NO_MATCH = 20
        };

        static Result<bool> validatePackageExists(const std::string &globalLibRootDir, const std::string &name);
        static Result<std::string> getLibsLinkerFlags(const std::string &globalLibRootDir, const std::string &name, const std::string &version, LinkerFlagCallbackFunc staticLinkerFlagCallbackFunc, LinkerFlagCallbackFunc dynamicLinkerFlagCallbackFunc);
        static Result<bool> downloadDependency(const Dependency &dependency);
    };
}

#endif //SIBS_GLOBALLIB_HPP