git.iko.soy/typeable/nixpkgs
on master help sign in
stardict-3.0.3: removed abandoned codebase; use goldendict instead
commitf7446f69af341083db8db1bd5d1fca19465eeb76 authorJoachim Schiele <js@lastlog.de> dateWed 16 Mar 2016, 09:16 (11 years ago) parent9f944fb
7 files changed−175
pkgs/applications/misc/stardict/stardict-3.0.3-compositelookup_cpp.patch−19 pkgs/applications/misc/stardict/stardict-3.0.3-correct-glib-include.patch−13 pkgs/applications/misc/stardict/stardict-3.0.3-entry.patch−20 pkgs/applications/misc/stardict/stardict-3.0.3-gcc46.patch−13 pkgs/applications/misc/stardict/stardict-3.0.3-overflow.patch−26 pkgs/applications/misc/stardict/stardict-3.0.3-zlib-1.2.5.2.patch−39 pkgs/applications/misc/stardict/stardict.nix−45
pkgs/applications/misc/stardict/stardict-3.0.3-compositelookup_cpp.patchdeleted−19
@@ -1,19 +0,0 @@
1−This patch is from OpenSUSE .src.rpm for the following crash on startup:
2−
3−ERROR:compositelookup.cpp:53:void CompositeLookup::send_net_dict_request(const string&, const string&): assertion failed: (NetDictRequests.end() == std::find(NetDictRequests.begin(), NetDictRequests.end(), request))
4−
5−--- dict/src/lib/compositelookup.cpp
6−+++ dict/src/lib/compositelookup.cpp
7−@@ -50,8 +50,10 @@
8− void CompositeLookup::send_net_dict_request(const std::string& dict_id, const std::string& key)
9− {
10− NetDictRequest request(dict_id, key);
11−- g_assert(NetDictRequests.end() == std::find(NetDictRequests.begin(), NetDictRequests.end(), request));
12−- NetDictRequests.push_back(request);
13−+ if(NetDictRequests.end() == std::find(NetDictRequests.begin(), NetDictRequests.end(), request))
14−+ {
15−+ NetDictRequests.push_back(request);
16−+ }
17− }
18−
19− /* returns true if got expected response */
pkgs/applications/misc/stardict/stardict-3.0.3-correct-glib-include.patchdeleted−13
@@ -1,13 +0,0 @@
1−http://bugs.gentoo.org/396219
2−
3−--- dict/src/tomboykeybinder.h
4−+++ dict/src/tomboykeybinder.h
5−@@ -21,7 +21,7 @@
6− #ifndef __TOMBOY_KEY_BINDER_H__
7− #define __TOMBOY_KEY_BINDER_H__
8−
9−-#include <glib/gtypes.h>
10−+#include <glib.h>
11−
12− G_BEGIN_DECLS
13−
pkgs/applications/misc/stardict/stardict-3.0.3-entry.patchdeleted−20
@@ -1,20 +0,0 @@
1−warning: key "Encoding" in group "Desktop Entry" is deprecated
2−error: value "stardict.png" for key "Icon" in group "Desktop Entry" is an icon name with an extension, but there should be no extension
3−error: value "Dictionary" in key "Categories" in group "Desktop Entry" requires another category to be present among the following categories: Office;TextTools
4−
5−--- dict/data/stardict.desktop.in
6−+++ dict/data/stardict.desktop.in
7−@@ -1,11 +1,10 @@
8− [Desktop Entry]
9−-Encoding=UTF-8
10− _Name=StarDict
11− _Comment=Lookup words
12− Exec=stardict
13− Terminal=false
14− Type=Application
15−-Icon=stardict.png
16−+Icon=stardict
17− StartupNotify=true
18−-Categories=Utility;Dictionary;
19−+Categories=Utility;Office;TextTools;Dictionary;
20− X-GNOME-DocPath=stardict/stardict.xml
pkgs/applications/misc/stardict/stardict-3.0.3-gcc46.patchdeleted−13
@@ -1,13 +0,0 @@
1−http://bugs.gentoo.org/362299
2−
3−--- dict/stardict-plugins/stardict-wordnet-plugin/scene.h
4−+++ dict/stardict-plugins/stardict-wordnet-plugin/scene.h
5−@@ -25,6 +25,8 @@
6− #ifndef __PHYSICS_H__
7− #define __PHYSICS_H__
8−
9−+#include <cstddef>
10−+
11− #include "partic.h"
12− #include "spring.h"
13−
pkgs/applications/misc/stardict/stardict-3.0.3-overflow.patchdeleted−26
@@ -1,26 +0,0 @@
1−This patch is stardict-tools-3.0.3-destbufferoverflow.patch from OpenSUSE .src.rpm for:
2−
3−warning: call to ‘__fgets_chk_warn’ declared with attribute warning: fgets called with bigger size than length of destination buffer [enabled by default]
4−
5−--- tools/src/myspell2dic.c
6−+++ tools/src/myspell2dic.c
7−@@ -132,7 +132,7 @@ if (argc<3)
8−
9− fprintf(stderr, "Enter grammar language [Spanish]: ");
10− fflush(stderr);
11−-fgets(lang, 100, stdin);
12−+fgets(lang, 50, stdin);
13− if ((p=strchr(lang, '\n'))!=NULL) *p=0;
14− if (*lang==0) strcpy(lang, "Spanish");
15−
16−--- tools/src/ooo2dict.c
17−+++ tools/src/ooo2dict.c
18−@@ -71,7 +71,7 @@ current2=malloc(10000);
19−
20− fprintf(stderr, "Enter thesaurus language [WordNet_English]: ");
21− fflush(stderr);
22−-fgets(lang, 100, stdin);
23−+fgets(lang, 50, stdin);
24− if ((p=strchr(lang, '\n'))!=NULL) *p=0;
25− if (*lang==0) strcpy(lang, "WordNet_English");
26− F=fopen((argc>1)? argv[1]: "/usr/share/myspell/dicts/th_en_US_v2.dat", "rt");
pkgs/applications/misc/stardict/stardict-3.0.3-zlib-1.2.5.2.patchdeleted−39
@@ -1,39 +0,0 @@
1−http://bugs.gentoo.org/401887
2−
3−diff --git a/lib/src/libcommon.cpp b/lib/src/libcommon.cpp
4−index 16770a3..a4299e7 100644
5−--- a/lib/src/libcommon.cpp
6−+++ b/lib/src/libcommon.cpp
7−@@ -614,7 +614,7 @@ int unpack_zlib(const char* arch_file_name, const char* out_file_name)
8− return EXIT_FAILURE;
9− }
10− while(true) {
11−- len = gzread(get_impl(in), buf, buffer_size);
12−+ len = gzread((gzFile)get_impl(in), buf, buffer_size);
13− if(len < 0) {
14− g_critical(read_file_err, arch_file_name, "");
15− return EXIT_FAILURE;
16−@@ -871,3 +871,8 @@ int remove_recursive(const std::string& path)
17− return res;
18− }
19− }
20−+
21−+int gzclose_compat(void * file)
22−+{
23−+ return gzclose ((gzFile)file);
24−+}
25−diff --git a/lib/src/libcommon.h b/lib/src/libcommon.h
26−index 10f13b4..bdcbf2f 100644
27−--- a/lib/src/libcommon.h
28−+++ b/lib/src/libcommon.h
29−@@ -187,8 +187,9 @@ namespace clib {
30− typedef ResourceWrapper<FILE, FILE*, int, fclose> File;
31− }
32−
33−+extern int gzclose_compat(void * file);
34− namespace zip {
35−-typedef ResourceWrapper<void, void*, int, gzclose> gzFile;
36−+typedef ResourceWrapper<void, void*, int, gzclose_compat> gzFile;
37− }
38−
39− /* Create a new temporary file. Return file name in file name encoding.
pkgs/applications/misc/stardict/stardict.nixdeleted−45
@@ -1,45 +0,0 @@
1−{stdenv, fetchurl, pkgconfig, gtk, glib, zlib, libxml2, intltool, gnome_doc_utils, libgnomeui, scrollkeeper, mysql, pcre, which, libxslt}:
2−stdenv.mkDerivation rec {
3− name= "stardict-3.0.3";
4−
5− src = fetchurl {
6− url = "http://stardict-3.googlecode.com/files/${name}.tar.bz2";
7− sha256 = "0wrb8xqy6x9piwrn0vw5alivr9h3b70xlf51qy0jpl6d7mdhm8cv";
8− };
9−
10− buildInputs = [ pkgconfig gtk glib zlib libxml2 intltool gnome_doc_utils libgnomeui scrollkeeper mysql.lib pcre which libxslt];
11−
12− postPatch = ''
13− # mysql hacks: we need dynamic linking as there is no libmysqlclient.a
14− substituteInPlace tools/configure --replace '/usr/local/include/mysql' '${mysql.lib}/include/mysql/'
15− substituteInPlace tools/configure --replace 'AC_FIND_FILE([libmysqlclient.a]' 'AC_FIND_FILE([libmysqlclient.so]'
16− substituteInPlace tools/configure --replace '/usr/local/lib/mysql' '${mysql.lib}/lib/mysql/'
17− substituteInPlace tools/configure --replace 'for y in libmysqlclient.a' 'for y in libmysqlclient.so'
18− substituteInPlace tools/configure --replace 'libmysqlclient.a' 'libmysqlclient.so'
19−
20− # a list of p0 patches from gentoo devs
21− patch -p0 < ${./stardict-3.0.3-overflow.patch}
22− patch -p0 < ${./stardict-3.0.3-gcc46.patch}
23− patch -p0 < ${./stardict-3.0.3-compositelookup_cpp.patch}
24− patch -p0 < ${./stardict-3.0.3-correct-glib-include.patch}
25− patch -p0 < ${./stardict-3.0.3-entry.patch}
26−
27− # disable the xsltproc internet query
28− substituteInPlace dict/help/Makefile.am --replace 'xsltproc -o' 'xsltproc --nonet -o'
29− substituteInPlace dict/help/Makefile.in --replace 'xsltproc -o' 'xsltproc --nonet -o'
30− '';
31−
32− # another gentoo patch: a p1 patch
33− patches = [ ./stardict-3.0.3-zlib-1.2.5.2.patch ];
34−
35− configurePhase = ''
36− ./configure --disable-spell --disable-gucharmap --disable-festival --disable-espeak --disable-scrollkeeper --prefix=$out
37− '';
38−
39− meta = {
40− description = "An international dictionary supporting fuzzy and glob style matching";
41− license = stdenv.lib.licenses.lgpl3;
42− maintainers = with stdenv.lib.maintainers; [qknight];
43− broken = true;
44− };
45−}