22#if !defined(D02AFD831E4F4B9E8394D2B294DF4582)
23#define D02AFD831E4F4B9E8394D2B294DF4582
29#include <miktex/Util/PathName>
30#include <miktex/Core/Paths>
31#include <miktex/Core/Session>
32#include <miktex/Core/VersionNumber>
40# define UNUSED(x) static_cast<void>(x)
44#if !defined(UNUSED_ALWAYS)
45# define UNUSED_ALWAYS(x) static_cast<void>(x)
48#define UNIMPLEMENTED() MIKTEX_INTERNAL_ERROR()
50#if defined(MIKTEX_WINDOWS) && 1
51#define LOCTRACE() OutputDebugString((std::string(__FILE__) + ":" + std::to_string(__LINE__)).c_str())
52#define TRACE(msg) OutputDebugString(msg)
60MPM_INTERNAL_BEGIN_NAMESPACE;
62inline std::string GetMpmAgent()
68constexpr const char* TEXMF_PREFIX_DIRECTORY =
"texmf" MIKTEX_PATH_DIRECTORY_DELIMITER_STRING;
73 std::size_t operator()(
const std::string& str)
const
82 bool operator()(
const std::string& str1,
const std::string& str2)
const
88inline void DbgView(
const std::string& s)
91 OutputDebugStringW(UW_(
"MiKTeX MPM: " + s));
95inline bool StripPrefix(
const std::string& str,
const char* prefix, std::string& result)
97 std::size_t n = strlen(prefix);
102 result = str.c_str() + n;
110inline int StrCmp(
const char* lpsz1,
const char* lpsz2)
112 return strcmp(lpsz1, lpsz2);
115inline int StrCmp(
const wchar_t* lpsz1,
const wchar_t* lpsz2)
117 return wcscmp(lpsz1, lpsz2);
125bool IsUrl(
const std::string& url);
127std::string MakeUrl(
const std::string& base,
const std::string& rel);
129MPM_INTERNAL_END_NAMESPACE;
static time_t GetLastWriteTime(const MiKTeX::Util::PathName &path)
Definition File.h:419
static bool Exists(const MiKTeX::Util::PathName &path, FileExistsOptionSet options)
Instances of this class can be used to store path names.
Definition PathName.h:64
static int ComparePrefixes(const PathName &path1, const PathName &path2, std::size_t count)
An instance of this struct represents a version number.
Definition VersionNumber.h:36
std::string ToString() const