From: Thomas Geymayer Date: Thu, 21 Feb 2013 13:02:45 +0000 (+0100) Subject: Fix package management compiling with linux X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=06bfa4f1a1ef13ce8e52b8b610fa05786ecbe5a6;p=simgear.git Fix package management compiling with linux --- diff --git a/simgear/package/CMakeLists.txt b/simgear/package/CMakeLists.txt index 4c41020f..7ce1e90c 100644 --- a/simgear/package/CMakeLists.txt +++ b/simgear/package/CMakeLists.txt @@ -23,8 +23,8 @@ if (SIMGEAR_SHARED) set(APP_LIBS SimGearCore) else() set(APP_LIBS - ${LibArchive_LIBRARIES} SimGearCore + ${LibArchive_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} ${WINSOCK_LIBRARY} ${ZLIB_LIBRARY} diff --git a/simgear/package/Catalog.cxx b/simgear/package/Catalog.cxx index e8a17573..bc9b6e59 100644 --- a/simgear/package/Catalog.cxx +++ b/simgear/package/Catalog.cxx @@ -3,6 +3,7 @@ #include #include +#include #include #include diff --git a/simgear/package/Root.cxx b/simgear/package/Root.cxx index 780617f7..6783b331 100644 --- a/simgear/package/Root.cxx +++ b/simgear/package/Root.cxx @@ -78,7 +78,7 @@ Package* Root::getPackageById(const std::string& aName) const size_t lastDot = aName.rfind('.'); Package* pkg = NULL; - if (lastDot == -1) { + if (lastDot == std::string::npos) { // naked package ID CatalogDict::const_iterator it = m_catalogs.begin(); for (; it != m_catalogs.end(); ++it) {