diff options
Diffstat (limited to 'graphics')
-rw-r--r-- | graphics/photoprint/photoprint.SlackBuild | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/graphics/photoprint/photoprint.SlackBuild b/graphics/photoprint/photoprint.SlackBuild index 387d6db42965b..565187bdedc08 100644 --- a/graphics/photoprint/photoprint.SlackBuild +++ b/graphics/photoprint/photoprint.SlackBuild @@ -63,8 +63,6 @@ rm -rf $PRGNAM-$SRCVERSION tar xvf $CWD/$PRGNAM-$SRCVERSION.tar.gz cd $PRGNAM-$SRCVERSION -find . -name "*.cpp" | xargs sed -i 's%glib/.*.h%glib.h%g' - chown -R root:root . find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 -o -perm 511 \) \ @@ -72,6 +70,24 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ -exec chmod 644 {} \; +# sed magic thanks to archlinux +sed -i 's|^#include <glib/[^>]*>|#include <glib.h>|' \ + gp_cppsupport/gprintersettings.cpp \ + gp_cppsupport/gprinter.cpp \ + pixbufthumbnail/egg-pixbuf-thumbnail.c +# netpbm-typedef collides with std::tuple +for __file in imagesource/*.{h,cpp}; do + sed -i \ + -e 's|^\(using namespace std;\)|// \1|' \ + -e 's|<<[[:blank:]]*\(endl[[:blank:];]*\)|<< std::\1|g' \ + -e 's|^[^#]\([[:blank:]]\)*\([io]*fstream[[:blank:]]\)|\1std::\2|g' \ + -e 's#\([[:blank:]|&~^,()=+-]\)\(ios::\)#\1std::\2#g' \ + $__file +done +sed -i '116s|false|NULL|' effects/ppeffect.cpp +# limit use of 'g_type_init()' to GLIB<2.35 (deprecated use) +sed -i 's/^\([[:blank:]]*g_type_init();[[:blank:]]*\)$/#if !GLIB_CHECK_VERSION(2,35,0)\n\1\n#endif/' photoprint.cpp + LDFLAGS="-lX11" \ CFLAGS="$SLKCFLAGS" \ CXXFLAGS="$SLKCFLAGS" \ |