r12164 - in packages/trunk/pokerth/debian: . patches
Evgeni Golov
evgeni at alioth.debian.org
Tue Apr 26 12:34:57 UTC 2011
Author: evgeni
Date: 2011-04-26 12:34:44 +0000 (Tue, 26 Apr 2011)
New Revision: 12164
Added:
packages/trunk/pokerth/debian/patches/06_fix_gcc46_ftbfs.patch
packages/trunk/pokerth/debian/patches/07_boost146_ftbfs.patch
Modified:
packages/trunk/pokerth/debian/changelog
packages/trunk/pokerth/debian/patches/series
Log:
Fix two ftbfs:
* Fix FTBFS with gcc-4.6 by not passing -no_dead_strip_inits_and_terms
on anything but MacOSX.
LP: #770849
* Fix FTBFS with boost1.46 by porting to the v3 filesystem API.
Modified: packages/trunk/pokerth/debian/changelog
===================================================================
--- packages/trunk/pokerth/debian/changelog 2011-04-25 08:55:07 UTC (rev 12163)
+++ packages/trunk/pokerth/debian/changelog 2011-04-26 12:34:44 UTC (rev 12164)
@@ -1,3 +1,12 @@
+pokerth (0.8.3-3) unstable; urgency=low
+
+ * Fix FTBFS with gcc-4.6 by not passing -no_dead_strip_inits_and_terms
+ on anything but MacOSX.
+ LP: #770849
+ * Fix FTBFS with boost1.46 by porting to the v3 filesystem API.
+
+ -- Evgeni Golov <evgeni at debian.org> Tue, 26 Apr 2011 14:31:54 +0200
+
pokerth (0.8.3-2) unstable; urgency=low
* Upload to unstable.
Added: packages/trunk/pokerth/debian/patches/06_fix_gcc46_ftbfs.patch
===================================================================
--- packages/trunk/pokerth/debian/patches/06_fix_gcc46_ftbfs.patch (rev 0)
+++ packages/trunk/pokerth/debian/patches/06_fix_gcc46_ftbfs.patch 2011-04-26 12:34:44 UTC (rev 12164)
@@ -0,0 +1,75 @@
+Index: pokerth-0.8.3/pokerth_game.pro
+===================================================================
+--- pokerth-0.8.3.orig/pokerth_game.pro 2011-04-26 11:23:37.843733137 +0200
++++ pokerth-0.8.3/pokerth_game.pro 2011-04-26 11:24:10.583387436 +0200
+@@ -371,8 +371,6 @@
+ -lwldap32
+ RC_FILE = pokerth.rc
+ }
+-unix:# workaround for problems with boost_filesystem exceptions
+-QMAKE_LFLAGS += -no_dead_strip_inits_and_terms
+ unix:!mac {
+ # #### My release static build options
+ # QMAKE_CXXFLAGS += -ffunction-sections -fdata-sections
+@@ -482,6 +480,9 @@
+ QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.5
+ QMAKE_CXXFLAGS -= -std=gnu++0x
+
++ # workaround for problems with boost_filesystem exceptions
++ QMAKE_LFLAGS += -no_dead_strip_inits_and_terms
++
+ # for universal-compilation on PPC-Mac uncomment the following line
+ # on Intel-Mac you have to comment this line out or build will fail.
+ # QMAKE_MAC_SDK=/Developer/SDKs/MacOSX10.4u.sdk/
+Index: pokerth-0.8.3/pokerth_server.pro
+===================================================================
+--- pokerth-0.8.3.orig/pokerth_server.pro 2011-04-26 11:20:49.614063135 +0200
++++ pokerth-0.8.3/pokerth_server.pro 2011-04-26 11:25:24.385591285 +0200
+@@ -183,11 +183,6 @@
+ SOURCES += src/core/linux/convhelper.cpp
+ }
+
+-unix {
+- # workaround for problems with boost_filesystem exceptions
+- QMAKE_LFLAGS += -no_dead_strip_inits_and_terms
+-}
+-
+ unix : !mac {
+
+ ##### My release static build options
+@@ -299,6 +294,9 @@
+ QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.5
+ QMAKE_CXXFLAGS -= -std=gnu++0x
+
++ # workaround for problems with boost_filesystem exceptions
++ QMAKE_LFLAGS += -no_dead_strip_inits_and_terms
++
+ # for universal-compilation on PPC-Mac uncomment the following line
+ # on Intel-Mac you have to comment this line out or build will fail.
+ # QMAKE_MAC_SDK=/Developer/SDKs/MacOSX10.4u.sdk/
+Index: pokerth-0.8.3/zlib_compress.pro
+===================================================================
+--- pokerth-0.8.3.orig/zlib_compress.pro 2011-04-26 11:24:17.690444077 +0200
++++ pokerth-0.8.3/zlib_compress.pro 2011-04-26 11:24:32.412489943 +0200
+@@ -41,11 +41,6 @@
+ LIBS += -lgdi32 -lcomdlg32 -loleaut32 -limm32 -lwinmm -lwinspool -lole32 -luuid -luser32 -lmsimg32 -lshell32 -lkernel32
+ }
+
+-unix {
+- # workaround for problems with boost_filesystem exceptions
+- QMAKE_LFLAGS += -no_dead_strip_inits_and_terms
+-}
+-
+ unix : !mac {
+
+ ##### My release static build options
+@@ -94,6 +89,9 @@
+ CONFIG += ppc
+ QMAKE_MACOSX_DEPLOYMENT_TARGET = 10.3
+
++ # workaround for problems with boost_filesystem exceptions
++ QMAKE_LFLAGS += -no_dead_strip_inits_and_terms
++
+ # for universal-compilation on PPC-Mac uncomment the following line
+ # on Intel-Mac you have to comment this line out or build will fail.
+ # QMAKE_MAC_SDK=/Developer/SDKs/MacOSX10.4u.sdk/
Added: packages/trunk/pokerth/debian/patches/07_boost146_ftbfs.patch
===================================================================
--- packages/trunk/pokerth/debian/patches/07_boost146_ftbfs.patch (rev 0)
+++ packages/trunk/pokerth/debian/patches/07_boost146_ftbfs.patch 2011-04-26 12:34:44 UTC (rev 12164)
@@ -0,0 +1,250 @@
+Index: pokerth-0.8.3/src/core/common/avatarmanager.cpp
+===================================================================
+--- pokerth-0.8.3.orig/src/core/common/avatarmanager.cpp 2011-04-26 11:45:14.995555435 +0200
++++ pokerth-0.8.3/src/core/common/avatarmanager.cpp 2011-04-26 11:47:10.252256814 +0200
+@@ -76,13 +76,13 @@
+ path tmpDataPath(dataDir);
+ {
+ boost::mutex::scoped_lock lock(m_cacheDirMutex);
+- m_cacheDir = tmpCachePath.directory_string();
++ m_cacheDir = tmpCachePath.string();
+ }
+ {
+ boost::mutex::scoped_lock lock(m_avatarsMutex);
+- tmpRet = InternalReadDirectory((tmpDataPath / "gfx/avatars/default/people/").directory_string(), m_avatars);
++ tmpRet = InternalReadDirectory((tmpDataPath / "gfx/avatars/default/people/").string(), m_avatars);
+ retVal = retVal && tmpRet;
+- tmpRet = InternalReadDirectory((tmpDataPath / "gfx/avatars/default/misc/").directory_string(), m_avatars);
++ tmpRet = InternalReadDirectory((tmpDataPath / "gfx/avatars/default/misc/").string(), m_avatars);
+ retVal = retVal && tmpRet;
+ }
+ if (cacheDir.empty() || tmpCachePath.empty())
+@@ -90,7 +90,7 @@
+ else
+ {
+ boost::mutex::scoped_lock lock(m_cachedAvatarsMutex);
+- tmpRet = InternalReadDirectory(tmpCachePath.directory_string(), m_cachedAvatars);
++ tmpRet = InternalReadDirectory(tmpCachePath.string(), m_cachedAvatars);
+ retVal = retVal && tmpRet;
+ }
+
+@@ -102,7 +102,7 @@
+ AvatarManager::AddSingleAvatar(const std::string &fileName)
+ {
+ path filePath(fileName);
+- string tmpFileName(filePath.file_string());
++ string tmpFileName(filePath.string());
+
+ if (!fileName.empty() && !tmpFileName.empty())
+ {
+@@ -384,7 +384,7 @@
+ {
+ path tmpPath(cacheDir);
+ tmpPath /= (md5buf.ToString() + ext);
+- string fileName(tmpPath.file_string());
++ string fileName(tmpPath.string());
+ ofstream o(fileName.c_str(), ios_base::out | ios_base::binary | ios_base::trunc);
+ if (!o.fail())
+ {
+@@ -456,7 +456,7 @@
+ try
+ {
+ path cachePath(cacheDir);
+- cacheDir = cachePath.directory_string();
++ cacheDir = cachePath.string();
+ // Never delete anything if we do not have a special cache dir set.
+ if (!cacheDir.empty())
+ {
+@@ -474,7 +474,7 @@
+ {
+ bool keepFile = false;
+ path filePath(i->second);
+- string fileString(filePath.file_string());
++ string fileString(filePath.string());
+ // Only consider files which are definitely in the cache dir.
+ if (fileString.size() > cacheDir.size() && fileString.substr(0, cacheDir.size()) == cacheDir)
+ {
+@@ -570,7 +570,7 @@
+ {
+ string md5sum(basename(i->path()));
+ MD5Buf md5buf;
+- string fileName(i->path().file_string());
++ string fileName(i->path().string());
+ if (md5buf.FromString(md5sum))
+ {
+ // Only consider files with md5sum as name.
+Index: pokerth-0.8.3/src/net/common/downloaderthread.cpp
+===================================================================
+--- pokerth-0.8.3.orig/src/net/common/downloaderthread.cpp 2011-04-26 11:47:50.274944396 +0200
++++ pokerth-0.8.3/src/net/common/downloaderthread.cpp 2011-04-26 11:47:58.469856641 +0200
+@@ -90,7 +90,7 @@
+ if (m_curDownloadData)
+ {
+ path filepath(m_curDownloadData->filename);
+- ifstream instream(filepath.file_string().c_str(), ios_base::in | ios_base::binary);
++ ifstream instream(filepath.string().c_str(), ios_base::in | ios_base::binary);
+ // Find out file size.
+ // Not fully portable, but works on win/linux/mac.
+ instream.seekg(0, ios_base::beg);
+@@ -128,7 +128,7 @@
+ if (m_curDownloadData && !m_curDownloadData->filename.empty())
+ {
+ path filepath(m_curDownloadData->filename);
+- m_downloadHelper->Init(m_curDownloadData->address, filepath.file_string());
++ m_downloadHelper->Init(m_curDownloadData->address, filepath.string());
+ m_downloadInProgress = true;
+ }
+ }
+Index: pokerth-0.8.3/src/net/common/serverlobbythread.cpp
+===================================================================
+--- pokerth-0.8.3.orig/src/net/common/serverlobbythread.cpp 2011-04-26 11:48:19.087120004 +0200
++++ pokerth-0.8.3/src/net/common/serverlobbythread.cpp 2011-04-26 11:49:13.967835402 +0200
+@@ -215,7 +215,7 @@
+ if (!logDir.empty())
+ {
+ logPath /= SERVER_STATISTICS_FILE_NAME;
+- m_statisticsFileName = logPath.directory_string();
++ m_statisticsFileName = logPath.string();
+ ReadStatisticsFile();
+ }
+ }
+@@ -1251,7 +1251,7 @@
+ // Init finished - start session.
+ EstablishSession(session);
+ LOG_MSG("Client \"" << session.sessionData->GetClientAddr() << "\" uploaded avatar \""
+- << boost::filesystem::path(avatarFileName).file_string() << "\".");
++ << boost::filesystem::path(avatarFileName).string() << "\".");
+ }
+ else
+ SessionError(session, ERR_NET_WRONG_AVATAR_SIZE);
+Index: pokerth-0.8.3/src/net/common/uploaderthread.cpp
+===================================================================
+--- pokerth-0.8.3.orig/src/net/common/uploaderthread.cpp 2011-04-26 11:48:05.320947260 +0200
++++ pokerth-0.8.3/src/net/common/uploaderthread.cpp 2011-04-26 12:14:37.533604549 +0200
+@@ -74,7 +74,7 @@
+ if (!data.filename.empty() && data.filesize > 0)
+ {
+ path filepath(data.filename);
+- m_uploadHelper->Init(data.address + filepath.leaf(), filepath.file_string(), data.user, data.pwd, data.filesize);
++ m_uploadHelper->Init(data.address + filepath.filename().string(), filepath.string(), data.user, data.pwd, data.filesize);
+ m_uploadInProgress = true;
+ }
+ }
+Index: pokerth-0.8.3/src/core/common/loghelper_server.cpp
+===================================================================
+--- pokerth-0.8.3.orig/src/core/common/loghelper_server.cpp 2011-04-26 11:52:16.931549677 +0200
++++ pokerth-0.8.3/src/core/common/loghelper_server.cpp 2011-04-26 11:52:22.314835127 +0200
+@@ -47,7 +47,7 @@
+ path tmpLogFile(logDir);
+ tmpLogFile /= SERVER_MSG_LOG_FILE_NAME;
+
+- g_logFile = tmpLogFile.directory_string();
++ g_logFile = tmpLogFile.string();
+ g_logLevel = logLevel;
+ }
+
+Index: pokerth-0.8.3/src/gui/qt/qttools/nonqthelper/nonqthelper.cpp
+===================================================================
+--- pokerth-0.8.3.orig/src/gui/qt/qttools/nonqthelper/nonqthelper.cpp 2011-04-26 11:52:40.020484963 +0200
++++ pokerth-0.8.3/src/gui/qt/qttools/nonqthelper/nonqthelper.cpp 2011-04-26 11:52:46.675601596 +0200
+@@ -55,5 +55,5 @@
+ boost::filesystem::path startPath(argv0);
+ startPath = startPath.remove_leaf();
+ startPath /= "data";
+- return stringToUtf8(startPath.directory_string());
++ return stringToUtf8(startPath.string());
+ }
+Index: pokerth-0.8.3/src/net/common/clientstate.cpp
+===================================================================
+--- pokerth-0.8.3.orig/src/net/common/clientstate.cpp 2011-04-26 11:50:48.791248999 +0200
++++ pokerth-0.8.3/src/net/common/clientstate.cpp 2011-04-26 11:51:41.492253721 +0200
+@@ -194,7 +194,7 @@
+ // Download and compare md5.
+ tmpServerListPath = change_extension(tmpServerListPath, extension(tmpServerListPath) + ".md5");
+ boost::shared_ptr<DownloadHelper> downloader(new DownloadHelper);
+- downloader->Init(serverListUrl + ".md5", tmpServerListPath.directory_string());
++ downloader->Init(serverListUrl + ".md5", tmpServerListPath.string());
+ ClientStateSynchronizingServerList::Instance().SetDownloadHelper(downloader);
+ client->SetState(ClientStateSynchronizingServerList::Instance());
+ }
+@@ -202,7 +202,7 @@
+ {
+ // Download server list.
+ boost::shared_ptr<DownloadHelper> downloader(new DownloadHelper);
+- downloader->Init(serverListUrl, tmpServerListPath.directory_string());
++ downloader->Init(serverListUrl, tmpServerListPath.string());
+ ClientStateDownloadingServerList::Instance().SetDownloadHelper(downloader);
+ client->SetState(ClientStateDownloadingServerList::Instance());
+ }
+@@ -270,7 +270,7 @@
+ // Compare the md5 sums.
+ string tmpMd5;
+ {
+- ifstream inFile(md5ServerListPath.directory_string().c_str(), ios_base::in);
++ ifstream inFile(md5ServerListPath.string().c_str(), ios_base::in);
+ if (inFile.fail())
+ throw ClientException(__FILE__, __LINE__, ERR_SOCK_OPEN_MD5_FAILED, 0);
+ inFile >> tmpMd5;
+@@ -279,7 +279,7 @@
+ if (!downloadedMd5.FromString(tmpMd5))
+ throw ClientException(__FILE__, __LINE__, ERR_SOCK_INVALID_SERVERLIST_MD5, 0);
+ MD5Buf currentMd5;
+- if (!CryptHelper::MD5Sum(serverListPath.directory_string(), currentMd5))
++ if (!CryptHelper::MD5Sum(serverListPath.string(), currentMd5))
+ throw ClientException(__FILE__, __LINE__, ERR_SOCK_INVALID_SERVERLIST_MD5, 0);
+ if (downloadedMd5 == currentMd5)
+ {
+@@ -402,8 +402,8 @@
+
+ // Unzip the file using zlib.
+ try {
+- ifstream inFile(zippedServerListPath.directory_string().c_str(), ios_base::in | ios_base::binary);
+- ofstream outFile(xmlServerListPath.directory_string().c_str(), ios_base::out);
++ ifstream inFile(zippedServerListPath.string().c_str(), ios_base::in | ios_base::binary);
++ ofstream outFile(xmlServerListPath.string().c_str(), ios_base::out);
+ boost::iostreams::filtering_streambuf<boost::iostreams::input> in;
+ in.push(boost::iostreams::zlib_decompressor());
+ in.push(inFile);
+@@ -417,7 +417,7 @@
+ xmlServerListPath = zippedServerListPath;
+
+ // Parse the server address.
+- TiXmlDocument doc(xmlServerListPath.directory_string());
++ TiXmlDocument doc(xmlServerListPath.string());
+
+ if (doc.LoadFile())
+ {
+Index: pokerth-0.8.3/src/pokerth_server.cpp
+===================================================================
+--- pokerth-0.8.3.orig/src/pokerth_server.cpp 2011-04-26 11:51:55.450400982 +0200
++++ pokerth-0.8.3/src/pokerth_server.cpp 2011-04-26 11:52:07.096855087 +0200
+@@ -151,7 +151,7 @@
+ {
+ path tmpPidPath(myConfig->readConfigString("LogDir"));
+ tmpPidPath /= "pokerth.pid";
+- pidFile = tmpPidPath.directory_string();
++ pidFile = tmpPidPath.string();
+ }
+ {
+ ofstream pidStream(pidFile.c_str(), ios_base::out | ios_base::trunc);
+Index: pokerth-0.8.3/src/zlib_compress.cpp
+===================================================================
+--- pokerth-0.8.3.orig/src/zlib_compress.cpp 2011-04-26 11:50:16.855487998 +0200
++++ pokerth-0.8.3/src/zlib_compress.cpp 2011-04-26 11:50:32.733380435 +0200
+@@ -49,13 +49,13 @@
+ return 2;
+ }
+ try {
+- ifstream inFile(inputFilePath.directory_string().c_str(), ios_base::in);
+- ofstream outFile(outputFilePath.directory_string().c_str(), ios_base::out | ios_base::binary);
++ ifstream inFile(inputFilePath.string().c_str(), ios_base::in);
++ ofstream outFile(outputFilePath.string().c_str(), ios_base::out | ios_base::binary);
+ boost::iostreams::filtering_streambuf<boost::iostreams::output> out;
+ out.push(boost::iostreams::zlib_compressor());
+ out.push(outFile);
+ boost::iostreams::copy(inFile, out);
+- cout << "Compression of \"" << inputFilePath.directory_string() << "\" to \"" << outputFilePath.directory_string() << "\" was successful." << endl;
++ cout << "Compression of \"" << inputFilePath.string() << "\" to \"" << outputFilePath.string() << "\" was successful." << endl;
+ } catch (...)
+ {
+ cerr << "Compression failed." << endl;
Modified: packages/trunk/pokerth/debian/patches/series
===================================================================
--- packages/trunk/pokerth/debian/patches/series 2011-04-25 08:55:07 UTC (rev 12163)
+++ packages/trunk/pokerth/debian/patches/series 2011-04-26 12:34:44 UTC (rev 12164)
@@ -2,3 +2,6 @@
02_use_dejavu_fonts.patch
#03_use_--as-needed.patch
05_disable_gnu++0x.patch
+06_fix_gcc46_ftbfs.patch
+07_boost146_ftbfs.patch
+
More information about the Pkg-games-commits
mailing list