diff --git a/djvulibre-3.5.23-gcc46.patch b/djvulibre-3.5.23-gcc46.patch deleted file mode 100644 index 1cfb784..0000000 --- a/djvulibre-3.5.23-gcc46.patch +++ /dev/null @@ -1,69 +0,0 @@ ---- djvulibre-3.5.23/libdjvu/GSmartPointer.h~ 2011-03-29 12:35:05.000000000 +0400 -+++ djvulibre-3.5.23/libdjvu/GSmartPointer.h 2011-03-29 12:35:25.000000000 +0400 -@@ -58,6 +58,9 @@ - - #ifndef _GSMARTPOINTER_H_ - #define _GSMARTPOINTER_H_ -+ -+#include -+ - #ifdef HAVE_CONFIG_H - #include "config.h" - #endif -diff --git a/libdjvu/MMX.cpp b/libdjvu/MMX.cpp -index 528dab6..e70fdd8 100644 ---- a/libdjvu/MMX.cpp -+++ b/libdjvu/MMX.cpp -@@ -167,8 +167,23 @@ MMXControl::enable_mmx() - : "=m" (cpuflags) : - : "eax","ecx","edx"); - #endif -+#if defined(MMX) && defined(__GNUC__) && defined(__x86_64__) -+ // Detection of MMX for GCC -+ __asm__ volatile (// Check that CR0:EM is clear -+ "xorl %%edx,%%edx\n\t" -+ "smsw %%ax\n\t" -+ "andl $4,%%eax\n\t" -+ "jnz 1f\n\t" -+ // Execute CPUID -+ "movl $1,%%eax\n\t" -+ "cpuid\n" -+ // Finish -+ "1:\tmovl %%edx, %0" -+ : "=m" (cpuflags) : -+ : "eax","ebx","ecx","edx"); -+#endif - #if defined(MMX) && defined(_MSC_VER) && defined(_M_IX86) -- // Detection of MMX for MSVC -+ // Detection of MMX for MSVC 32 bits - __asm { pushfd - pop ecx - xor edx,edx -diff --git a/libdjvu/MMX.h b/libdjvu/MMX.h -index b0af5e5..f8780af 100644 ---- a/libdjvu/MMX.h -+++ b/libdjvu/MMX.h -@@ -143,17 +143,18 @@ class MMXControl - - #ifndef NO_MMX - --#if defined(__GNUC__) && defined(__i386__) -+#if defined(__GNUC__) && (defined(__i386__) || defined(__x86_64__)) -+typedef struct{ char c[8]; } MMX_t; - #define MMXemms \ - __asm__ volatile("emms" : : : "memory" ) - #define MMXrr(op,src,dst) \ -- __asm__ volatile( #op " %%" #src ",%%" #dst : : : "memory") -+ __asm__ volatile( #op " %%" #src ",%%" #dst : : : "memory" ) - #define MMXir(op,imm,dst) \ -- __asm__ volatile( #op " %0,%%" #dst : : "i" (imm) : "memory") -+ __asm__ volatile( #op " %0,%%" #dst : : "i" (imm) : "memory" ) - #define MMXar(op,addr,dst) \ -- __asm__ volatile( #op " %0,%%" #dst : : "m" (*(addr)) : "memory") -+ __asm__ volatile( #op " %0,%%" #dst : : "m" (*(MMX_t*)(addr)) : "memory" ) - #define MMXra(op,src,addr) \ -- __asm__ volatile( #op " %%" #src ",%0" : : "m" (*(addr)) : "memory") -+ __asm__ volatile( #op " %%" #src ",%0" : "=m" (*(MMX_t*)(addr)) : : "memory") - #define MMX 1 - #endif - diff --git a/djvulibre-3.5.24-nsdejavu.patch b/djvulibre-3.5.24-nsdejavu.patch deleted file mode 100644 index 6ebf82a..0000000 --- a/djvulibre-3.5.24-nsdejavu.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- gui/nsdejavu/Makefile.in 2003-01-06 15:09:56.000000000 +0100 -+++ gui/nsdejavu/Makefile.in 2003-09-30 12:24:14.000000000 +0200 -@@ -25,7 +25,7 @@ - datadir = @datadir@ - libdir = @libdir@ - mandir = @mandir@ --plugindir = ${libdir}/netscape/plugins -+plugindir = ${libdir}/browser-plugins - - CC = @CC@ - CXX = @CXX@ diff --git a/djvulibre-3.5.24.tar.bz2 b/djvulibre-3.5.24.tar.bz2 deleted file mode 100644 index 9c165e2..0000000 --- a/djvulibre-3.5.24.tar.bz2 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:761b799084bd7095f2e6d9fc3c35ec45e0977373a8b9f3e405e5dd8aa89e95ed -size 2695962 diff --git a/djvulibre-3.5.25.tar.bz2 b/djvulibre-3.5.25.tar.bz2 new file mode 100644 index 0000000..bea343b --- /dev/null +++ b/djvulibre-3.5.25.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:497e5823660139775780fa6339c57b33b46df8d606c815e4e6edae57d35e7f0c +size 2335628 diff --git a/djvulibre-3.5.24-filepath.patch b/djvulibre-filepath.patch similarity index 100% rename from djvulibre-3.5.24-filepath.patch rename to djvulibre-filepath.patch diff --git a/djvulibre-gcc47.patch b/djvulibre-gcc47.patch deleted file mode 100644 index c32f89a..0000000 --- a/djvulibre-gcc47.patch +++ /dev/null @@ -1,35 +0,0 @@ -Index: djvulibre-3.5.24/gui/indep/utils/execdir.cpp -=================================================================== ---- djvulibre-3.5.24.orig/gui/indep/utils/execdir.cpp -+++ djvulibre-3.5.24/gui/indep/utils/execdir.cpp -@@ -141,13 +141,13 @@ getDjViewDataFile(const char *fname) - { - GURL url = GURL(file, paths[pos]); - GUTF8String urls = (const char*)url; -- int pos = urls.search(osi); -- if (pos >= 0) -+ int pos2 = urls.search(osi); -+ if (pos2 >= 0) - { - GUTF8String urlx; -- urlx += urls.substr(0, pos); -+ urlx += urls.substr(0, pos2); - urlx += djview3; -- urlx += urls.substr(pos+strlen(osi), -1); -+ urlx += urls.substr(pos2+strlen(osi), -1); - GURL url = GURL::UTF8(urlx); - if (url.is_file()) - return url; -Index: djvulibre-3.5.24/libdjvu/GContainer.h -=================================================================== ---- djvulibre-3.5.24.orig/libdjvu/GContainer.h -+++ djvulibre-3.5.24/libdjvu/GContainer.h -@@ -962,7 +962,7 @@ public: - /** Inserts an element before the first element of the list. - The new element is initialized with a copy of argument #elt#. */ - void prepend(const TYPE &elt) -- { GListImpl::prepend(newnode((const TI&)elt)); } -+ { GListImpl::prepend(this->newnode((const TI&)elt)); } - /** Inserts a new element after the list element at position #pos#. When - position #pos# is null the element is inserted at the beginning of the - list. The new element is initialized with a copy of #elt#. */ diff --git a/djvulibre.changes b/djvulibre.changes index 792f87e..3cf3da2 100644 --- a/djvulibre.changes +++ b/djvulibre.changes @@ -1,3 +1,14 @@ +------------------------------------------------------------------- +Fri Mar 16 15:31:13 UTC 2012 - pgajdos@suse.com + +- updated to 3.5.25: + * Removed the deprecated djview3 code. + * Removed the deprecated cothreads code. + * Removed the unmaintained japanese man pages. + * Added ddjvu option to skip corrupted pages. + * Miniexp API is now reentrant. + * Bug fixes all around. + ------------------------------------------------------------------- Thu Mar 15 19:59:47 UTC 2012 - dimstar@opensuse.org diff --git a/djvulibre.spec b/djvulibre.spec index 3923739..523215a 100644 --- a/djvulibre.spec +++ b/djvulibre.spec @@ -16,28 +16,20 @@ # + Name: djvulibre BuildRequires: fdupes -BuildRequires: libdrm-devel +BuildRequires: gcc-c++ BuildRequires: libjpeg-devel BuildRequires: libtiff-devel -BuildRequires: qt3-devel -BuildRequires: qt3-devel-tools -BuildRequires: update-desktop-files -BuildRequires: xorg-x11-devel -Version: 3.5.24 +Version: 3.5.25 Release: 0 Url: http://djvu.sourceforge.net Summary: An Open Source Implementation of DjVu License: GPL-2.0+ Group: Productivity/Graphics/Other Source: %{name}-%{version}.tar.bz2 -Patch1: %{name}-%{version}-nsdejavu.patch -Patch2: %{name}-%{version}-filepath.patch -# PATCH-FIX-UPSTREAM djvulibre-3.5.23-gcc46.patch idoenmez@suse.de -- Fix gcc 4.6 compilation, upstream bug #3256513 -Patch3: djvulibre-3.5.23-gcc46.patch -# PATCH-FIX-UPSTREAM djvulibre-gcc47.patch sf#3505479 dimstar@opensuse.org -- Fix build with gcc 4.7. -Patch4: djvulibre-gcc47.patch +Patch0: %{name}-filepath.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build %description @@ -53,16 +45,6 @@ be smoothly zoomed and panned with no lengthy rerendering. DjVu is used by hundreds of academic, commercial, governmental, and noncommercial Web sites around the world. -%package djview3 -Summary: DjView3 is a portable DjVu Qt3 based viewer and browser plugin -Group: Productivity/Graphics/Other -Requires: djvulibre = %{version} -Conflicts: djvulibre-djview4 - -%description djview3 -DjView3 is a viewer and browser plugin for DjVu documents, based on the -DjVuLibre-3.5 library and the Qt3 toolkit. - %package -n libdjvulibre21 Summary: Libraries of Open Source Implementation of DjVu - djvulibre Group: Productivity/Graphics/Other @@ -88,29 +70,18 @@ This package contains the documentation for the DjVu - djvulibre %prep %setup -%patch1 -%patch2 -%patch3 -p1 -%patch4 -p1 -# removing cvsignore files in version 3.5.19 -rm -rf doc/minilisp/.cvsignore +%patch0 %build # specifying --x-libraries and -includes is needed due to new paths in X.org 7.x # delete them if builds against X.org 6.9 or lower -export QTDIR=/usr/%{_lib}/qt3 -CFLAGS="$RPM_OPT_FLAGS -I$QTDIR/include -Wall" \ -CXXFLAGS="$RPM_OPT_FLAGS -I$QTDIR/include -Wall -fmessage-length=0 -fno-strict-aliasing" \ -QT_LIBS="-L$QTDIR/%{_lib} -lqt-mt" \ +CFLAGS="$RPM_OPT_FLAGS" \ +CXXFLAGS="$RPM_OPT_FLAGS" \ ./configure \ --prefix=%{_prefix} \ --libdir=%{_libdir} \ - --mandir=%{_mandir} \ - --x-includes=/usr/include/ \ - --x-libraries=/usr/%{_lib}/ \ - --with-qt=/usr/%_lib/qt3 \ - --enable-djview -make OPTS="$RPM_OPT_FLAGS -Wall -fmessage-length=0 -DNO_DEBUG" %{?_smp_mflags} + --mandir=%{_mandir} +make OPTS="$RPM_OPT_FLAGS -DNO_DEBUG" %{?_smp_mflags} %install make install DESTDIR=$RPM_BUILD_ROOT @@ -124,12 +95,6 @@ mkdir -p $RPM_BUILD_ROOT/usr/share/pixmaps install -m 644 desktopfiles/hi22-djvu.png $RPM_BUILD_ROOT/usr/share/icons/hicolor/22x22/mimetypes/djvu.png install -m 644 desktopfiles/hi32-djvu.png $RPM_BUILD_ROOT/usr/share/icons/hicolor/32x32/mimetypes/djvu.png install -m 644 desktopfiles/hi48-djvu.png $RPM_BUILD_ROOT/usr/share/icons/hicolor/48x48/mimetypes/djvu.png -install -m 644 desktopfiles/hi32-djview3.png $RPM_BUILD_ROOT/usr/share/pixmaps/djvulibre-djview3.png -#fix wrong permissions -%__chmod 644 desktopfiles/djvulibre-djview3.desktop -#delete shebank from desktop file -%__sed -i '/#!\/usr\/bin\/env xdg-open/d' desktopfiles/djvulibre-djview3.desktop -%suse_update_desktop_file -r -i djvulibre-djview3 Graphics Viewer %fdupes $RPM_BUILD_ROOT %post -n libdjvulibre21 -p /sbin/ldconfig @@ -138,9 +103,8 @@ install -m 644 desktopfiles/hi32-djview3.png $RPM_BUILD_ROOT/usr/share/pixmaps/d %files %defattr(-,root,root) -%doc COPYING COPYRIGHT INSTALL NEWS README TODO +%doc COPYING COPYRIGHT INSTALL NEWS README %doc %{_mandir}/man1/* -%doc %{_mandir}/ja/* %{_datadir}/djvu %{_bindir}/* %dir %{_prefix}/share/icons/hicolor @@ -153,26 +117,6 @@ install -m 644 desktopfiles/hi32-djview3.png $RPM_BUILD_ROOT/usr/share/pixmaps/d %{_prefix}/share/icons/hicolor/22x22/mimetypes/djvu.png %{_prefix}/share/icons/hicolor/32x32/mimetypes/djvu.png %{_prefix}/share/icons/hicolor/48x48/mimetypes/djvu.png -# these go to djview3 subpackage -%exclude %{_prefix}/share/pixmaps/djvulibre-djview3.png -%exclude %{_libdir}/browser-plugins/nsdejavu.so -%exclude %{_datadir}/djvu/djview3 -%exclude %{_bindir}/djview* -%exclude %doc %{_mandir}/man1/djview* -%exclude %doc %{_mandir}/ja/man1/djview* -%exclude %doc %{_mandir}/man1/nsdejavu* -%exclude %doc %{_mandir}/ja/man1/nsdejavu* - -%files djview3 -%defattr(-,root,root) -%doc %{_mandir}/man1/djview* -%doc %{_mandir}/ja/man1/djview* -%doc %{_mandir}/man1/nsdejavu* -%doc %{_mandir}/ja/man1/nsdejav* -%{_prefix}/share/pixmaps/djvulibre-djview3.png -%{_libdir}/browser-plugins/nsdejavu.so -%{_bindir}/djview* -%{_prefix}/share/applications/djvulibre-djview3.desktop %files -n libdjvulibre21 %defattr(-,root,root)