Permalink
Browse files

Merge pull request #10946 from Kwiboo/cmake-win32

[cmake/win32] fixes for building with abnormal configuration
  • Loading branch information...
phil65 committed Dec 9, 2016
2 parents e394eb3 + daafecf commit bfd9d003851682b92dc0bdf516752867b8bceb7b
@@ -347,7 +347,7 @@ unset(_MAIN_LIBRARIES)
if(WIN32)
set_target_properties(${APP_NAME_LC} PROPERTIES WIN32_EXECUTABLE ON)
set_property(DIRECTORY PROPERTY VS_STARTUP_PROJECT ${APP_NAME_LC})
target_sources(kodi PRIVATE ${CORE_SOURCE_DIR}/xbmc/platform/win32/app.manifest)
target_sources(${APP_NAME_LC} PRIVATE ${CORE_SOURCE_DIR}/xbmc/platform/win32/app.manifest)
elseif(CORE_SYSTEM_NAME STREQUAL android)
# Nothing
else()
@@ -595,9 +595,9 @@ macro(core_find_versions)
set(APP_VERSION ${APP_VERSION_MAJOR}.${APP_VERSION_MINOR})
if(APP_VERSION_TAG)
set(APP_VERSION ${APP_VERSION}-${APP_VERSION_TAG})
string(TOLOWER ${APP_VERSION_TAG} APP_VERSION_TAG_LC)
endif()
string(REPLACE "." "," FILE_VERSION ${APP_ADDON_API}.0)
string(TOLOWER ${APP_VERSION_TAG} APP_VERSION_TAG_LC)
file(STRINGS ${CORE_SOURCE_DIR}/xbmc/addons/kodi-addon-dev-kit/include/kodi/libKODI_guilib.h guilib_version REGEX "^.*GUILIB_API_VERSION (.*)$")
string(REGEX REPLACE ".*\"(.*)\"" "\\1" guilib_version ${guilib_version})
file(STRINGS ${CORE_SOURCE_DIR}/xbmc/addons/kodi-addon-dev-kit/include/kodi/libKODI_guilib.h guilib_version_min REGEX "^.*GUILIB_MIN_API_VERSION (.*)$")
@@ -37,12 +37,14 @@ void CWin32StorageProvider::Initialize()
else
CLog::Log(LOGDEBUG, "%s: No optical drive found.", __FUNCTION__);
#ifdef HAS_DVD_DRIVE
// Can be removed once the StorageHandler supports optical media
VECSOURCES::const_iterator it;
for(it=vShare.begin();it!=vShare.end();++it)
if(g_mediaManager.GetDriveStatus(it->strPath) == DRIVE_CLOSED_MEDIA_PRESENT)
CJobManager::GetInstance().AddJob(new CDetectDisc(it->strPath, false), NULL);
// remove end
#endif
}
void CWin32StorageProvider::GetLocalDrives(VECSOURCES &localDrives)
@@ -95,6 +97,7 @@ CDetectDisc::CDetectDisc(const std::string &strPath, const bool bautorun)
bool CDetectDisc::DoWork()
{
#ifdef HAS_DVD_DRIVE
CLog::Log(LOGDEBUG, "%s: Optical media found in drive %s", __FUNCTION__, m_strPath.c_str());
CMediaSource share;
share.strPath = m_strPath;
@@ -108,5 +111,6 @@ bool CDetectDisc::DoWork()
share.m_ignore = true;
share.m_iDriveType = CMediaSource::SOURCE_TYPE_DVD;
g_mediaManager.AddAutoSource(share, m_bautorun);
#endif
return true;
}
View
@@ -96,14 +96,11 @@
#if defined(TARGET_WINDOWS)
#define HAS_WIN32_NETWORK
#define HAS_IRSERVERSUITE
#define HAS_AUDIO
#define HAS_WEB_SERVER
#define HAS_WEB_INTERFACE
#define HAS_FILESYSTEM_SMB
#define HAS_ZEROCONF
#define HAS_MDNS
#define HAS_AIRTUNES
#define HAS_UPNP
#define DECLARE_UNUSED(a,b) a b;
#endif

0 comments on commit bfd9d00

Please sign in to comment.