Merge topic 'curl-tls-verify'
[kiteware-cmake.git] / Source / cmFindLibraryCommand.h
blobf3874ff29b4c27a9014fd4c7719421ead2622fb6
1 /* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
2 file Copyright.txt or https://cmake.org/licensing for details. */
3 #pragma once
5 #include "cmConfigure.h" // IWYU pragma: keep
7 #include <string>
8 #include <vector>
10 #include "cmFindBase.h"
12 class cmExecutionStatus;
14 /** \class cmFindLibraryCommand
15 * \brief Define a command to search for a library.
17 * cmFindLibraryCommand is used to define a CMake variable
18 * that specifies a library. The command searches for a given
19 * file in a list of directories.
21 class cmFindLibraryCommand : public cmFindBase
23 public:
24 cmFindLibraryCommand(cmExecutionStatus& status);
26 bool InitialPass(std::vector<std::string> const& args);
28 protected:
29 void AddArchitecturePaths(const char* suffix);
30 void AddArchitecturePath(std::string const& dir,
31 std::string::size_type start_pos,
32 const char* suffix, bool fresh = true);
33 std::string FindLibrary();
35 private:
36 std::string FindNormalLibrary();
37 std::string FindNormalLibraryNamesPerDir();
38 std::string FindNormalLibraryDirsPerName();
39 std::string FindFrameworkLibrary();
40 std::string FindFrameworkLibraryNamesPerDir();
41 std::string FindFrameworkLibraryDirsPerName();
44 bool cmFindLibrary(std::vector<std::string> const& args,
45 cmExecutionStatus& status);