summaryrefslogtreecommitdiff
path: root/community/smc
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2012-07-19 00:01:52 +0000
committerroot <root@rshg054.dnsready.net>2012-07-19 00:01:52 +0000
commit6b87f8519dc037f4fd4c19d8f36b7d7565559bd3 (patch)
tree4c1b86f91ce9c742867b6eecd4857b20919cd713 /community/smc
parent63d179775e063452db6358e15b9847e7fc6c84b6 (diff)
Thu Jul 19 00:01:52 UTC 2012
Diffstat (limited to 'community/smc')
-rw-r--r--community/smc/PKGBUILD12
-rw-r--r--community/smc/boost_filesystem3.diff48
2 files changed, 56 insertions, 4 deletions
diff --git a/community/smc/PKGBUILD b/community/smc/PKGBUILD
index ca5620a04..e98a8c889 100644
--- a/community/smc/PKGBUILD
+++ b/community/smc/PKGBUILD
@@ -1,11 +1,11 @@
-# $Id: PKGBUILD 67212 2012-03-05 08:59:37Z ibiru $
+# $Id: PKGBUILD 74010 2012-07-18 01:09:00Z ibiru $
# Maintainer:
# Contributor: Juergen Hoetzel <juergen@archlinux.org>
# Contributor: Kritoke <typeolinux@yahoo.com>
pkgname=smc
pkgver=1.9
-pkgrel=15
+pkgrel=16
pkgdesc="Secret Maryo Chronicles"
arch=('i686' 'x86_64')
url="http://www.secretmaryo.org/"
@@ -14,10 +14,12 @@ depends=('sdl_image' 'sdl_ttf' 'sdl_mixer' 'cegui' 'boost-libs' 'smc-data')
makedepends=('autoconf' 'automake' 'boost')
source=(http://downloads.sourceforge.net/smclone/$pkgname-$pkgver.tar.bz2
smc-for-cegui-v0-7.diff
+ boost_filesystem3.diff
smc.desktop
smc.png)
md5sums=('75ab7826303c49aec25b052a8b90287f'
'51dfea21b741ad19df14e738df52f1cf'
+ '309a5a6d4b3c0b3dc5e1b7f4de84086f'
'80fe208132ff41dd7677a53ee429ecdb'
'efca7580e28748625eb676c9d24ee122')
@@ -26,8 +28,10 @@ build() {
# to remove when smc will be compatible with cegui-0.7.x
patch -Np1 -i "${srcdir}/smc-for-cegui-v0-7.diff"
- # fix for boost-1.46
- export CXXFLAGS="${CXXFLAGS} -DBOOST_FILESYSTEM_VERSION=2"
+ # fix compilation
+ export CXXFLAGS="${CXXFLAGS} -fpermissive"
+ # fix for boost >= 1.50
+ patch -Np1 -i "${srcdir}/boost_filesystem3.diff"
./autogen.sh
LIBS+="-lX11 -lboost_system" ./configure --prefix=/usr
diff --git a/community/smc/boost_filesystem3.diff b/community/smc/boost_filesystem3.diff
new file mode 100644
index 000000000..6786b98f5
--- /dev/null
+++ b/community/smc/boost_filesystem3.diff
@@ -0,0 +1,48 @@
+diff -rup smc-1.9/src/core/filesystem/filesystem.cpp smc-1.9.new/src/core/filesystem/filesystem.cpp
+--- smc-1.9/src/core/filesystem/filesystem.cpp 2009-07-04 12:11:18.000000000 +0200
++++ smc-1.9.new/src/core/filesystem/filesystem.cpp 2012-07-12 15:36:31.361941069 +0200
+@@ -142,27 +142,27 @@ vector<std::string> Get_Directory_Files(
+ if( fs::is_directory( *dir_itr ) )
+ {
+ // ignore hidden directories
+- if( dir_itr->path().leaf().find( "." ) == 0 )
++ if( dir_itr->path().filename().string().find( "." ) == 0 )
+ {
+ continue;
+ }
+
+ if( with_directories )
+ {
+- valid_files.push_back( dir + "/" + dir_itr->path().leaf() );
++ valid_files.push_back( dir + "/" + dir_itr->path().filename().string() );
+ }
+
+ // load all items from the sub-directory
+ if( search_in_sub_directories )
+ {
+- vector<std::string> new_valid_files = Get_Directory_Files( dir + "/" + dir_itr->path().leaf(), file_type, with_directories );
++ vector<std::string> new_valid_files = Get_Directory_Files( dir + "/" + dir_itr->path().filename().string(), file_type, with_directories );
+ valid_files.insert( valid_files.end(), new_valid_files.begin(), new_valid_files.end() );
+ }
+ }
+ // valid file
+- else if( file_type.empty() || dir_itr->path().leaf().rfind( file_type ) != std::string::npos )
++ else if( file_type.empty() || dir_itr->path().filename().string().rfind( file_type ) != std::string::npos )
+ {
+- valid_files.push_back( dir + "/" + dir_itr->path().leaf() );
++ valid_files.push_back( dir + "/" + dir_itr->path().filename().string() );
+ }
+ }
+ catch( const std::exception &ex )
+diff -rup smc-1.9/src/overworld/world_manager.cpp smc-1.9.new/src/overworld/world_manager.cpp
+--- smc-1.9/src/overworld/world_manager.cpp 2009-08-16 18:44:52.000000000 +0200
++++ smc-1.9.new/src/overworld/world_manager.cpp 2012-07-12 15:37:13.564660591 +0200
+@@ -118,7 +118,7 @@ void cOverworld_Manager :: Load_Dir( con
+ {
+ try
+ {
+- std::string current_dir = dir_itr->path().leaf();
++ std::string current_dir = dir_itr->path().filename().string();
+
+ // only directories with an existing description
+ if( fs::is_directory( *dir_itr ) && File_Exists( dir + "/" + current_dir + "/description.xml" ) )