Importing epsilon debian dirs.
authoretrunko <eblima@gmail.com>
Sun, 9 Dec 2007 15:08:29 +0000 (15:08 +0000)
committeretrunko <eblima@gmail.com>
Sun, 9 Dec 2007 15:08:29 +0000 (15:08 +0000)
20 files changed:
trunk/epsilon/debian/changelog [new file with mode: 0644]
trunk/epsilon/debian/control [new file with mode: 0644]
trunk/epsilon/debian/copyright [new file with mode: 0644]
trunk/epsilon/debian/epsilon0-bin.install [new file with mode: 0644]
trunk/epsilon/debian/libepsilon0-dev.install [new file with mode: 0644]
trunk/epsilon/debian/libepsilon0.install [new file with mode: 0644]
trunk/epsilon/debian/patches/01_dont_overwrite_changelog [new file with mode: 0644]
trunk/epsilon/debian/patches/02_epsilon_thumb_canola [new file with mode: 0644]
trunk/epsilon/debian/patches/series [new file with mode: 0644]
trunk/epsilon/debian/rules [new file with mode: 0755]
trunk/epsilon/debian_gregale/changelog [new file with mode: 0644]
trunk/epsilon/debian_gregale/control [new file with mode: 0644]
trunk/epsilon/debian_gregale/copyright [new file with mode: 0644]
trunk/epsilon/debian_gregale/epsilon0-bin.install [new file with mode: 0644]
trunk/epsilon/debian_gregale/libepsilon0-dev.install [new file with mode: 0644]
trunk/epsilon/debian_gregale/libepsilon0.install [new file with mode: 0644]
trunk/epsilon/debian_gregale/patches/01_dont_overwrite_changelog [new file with mode: 0644]
trunk/epsilon/debian_gregale/patches/02_epsilon_thumb_canola [new file with mode: 0644]
trunk/epsilon/debian_gregale/patches/series [new file with mode: 0644]
trunk/epsilon/debian_gregale/rules [new file with mode: 0755]

diff --git a/trunk/epsilon/debian/changelog b/trunk/epsilon/debian/changelog
new file mode 100644 (file)
index 0000000..5f914c5
--- /dev/null
@@ -0,0 +1,5 @@
+epsilon (0.3.0.011-maemo.1) unstable; urgency=low
+
+  * Maemo build.
+
+ -- Eduardo Lima (Etrunko) <eduardo.lima@indt.org.br>  Sun, 09 Dec 2007 12:14:27 -0200
diff --git a/trunk/epsilon/debian/control b/trunk/epsilon/debian/control
new file mode 100644 (file)
index 0000000..9eef5cb
--- /dev/null
@@ -0,0 +1,38 @@
+Source: epsilon
+Section: libs
+Priority: optional
+Maintainer: Maemo-EFL Team <maemo-efl-devel@garage.maemo.org>
+Build-Depends: cdbs, debhelper, zlib1g-dev, libepeg-dev, libevas-dev, libecore-dev, libedje-dev, libimlib2-dev, libpng12-dev
+Standards-Version: 3.7.2
+
+Package: libepsilon0-dev
+Section: libdevel
+Architecture: any
+Depends: libepsilon0 (= ${Source-Version})
+Provides: libepsilon-dev
+Description: Enlightenment thumbnailing library development files
+ This is a small, display independent, and quick thumbnailing library.
+ .
+ This package contains headers and static libraries for development with
+ libepeg.
+
+Package: libepsilon0
+Section: libs
+Architecture: any
+Depends: ${shlibs:Depends}
+Recommends: epsilon-bin
+Provides: libepsilon
+Description: Enlightenment thumbnailing library API
+ This is a small, display independent, and quick thumbnailing library.
+ .
+ This package contains the shared library.
+
+Package: epsilon0-bin
+Section: libs
+Architecture: any
+Depends: ${shlibs:Depends}
+Provides: epsilon-bin
+Description: Enlightenment thumbnailing binary
+ This is a small, display independent, and quick thumbnailing library.
+ .
+ This package contains the Epsilon binary program.
diff --git a/trunk/epsilon/debian/copyright b/trunk/epsilon/debian/copyright
new file mode 100644 (file)
index 0000000..c62ceff
--- /dev/null
@@ -0,0 +1,34 @@
+This package was debianized by Sytse Wielinga <s.b.wielinga@student.utwente.nl> on
+Thu,  4 Mar 2004 22:41:20 +0100
+
+The source is downloaded from the e17/libs/epsilon module of the enlightenment CVS 
+tree. For more information, see:
+
+  http://www.enlightenment.org/cvs.html
+
+Upstream Authors: Enlightenment team <enlightenment-devel@lists.sourceforge.net>
+
+License:
+
+    Redistribution and use in source and binary forms, with or without
+    modification, are permitted under the terms of the BSD License.
+
+    THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+    ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+    IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+    ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+    FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+    DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+    OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+    HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+    LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+    OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+    SUCH DAMAGE.
+
+On Debian systems, the complete text of the BSD License can be
+found in `/usr/share/common-licenses/BSD'.
+
+
+The Debian packaging is (C) 2007, E17 Debian Team <debian@edevelop.org> and
+is licensed under the GPL, see `/usr/share/common-licenses/GPL'.
+
diff --git a/trunk/epsilon/debian/epsilon0-bin.install b/trunk/epsilon/debian/epsilon0-bin.install
new file mode 100644 (file)
index 0000000..a5504af
--- /dev/null
@@ -0,0 +1,2 @@
+debian/tmp/usr/bin/epsilon
+debian/tmp/usr/bin/epsilon_thumbd
diff --git a/trunk/epsilon/debian/libepsilon0-dev.install b/trunk/epsilon/debian/libepsilon0-dev.install
new file mode 100644 (file)
index 0000000..d33fb9b
--- /dev/null
@@ -0,0 +1,5 @@
+debian/tmp/usr/lib/pkgconfig/*
+debian/tmp/usr/include/*
+debian/tmp/usr/lib/lib*.a
+debian/tmp/usr/lib/lib*.so
+debian/tmp/usr/lib/lib*.la
diff --git a/trunk/epsilon/debian/libepsilon0.install b/trunk/epsilon/debian/libepsilon0.install
new file mode 100644 (file)
index 0000000..c45ebcf
--- /dev/null
@@ -0,0 +1 @@
+debian/tmp/usr/lib/lib*.so.*
diff --git a/trunk/epsilon/debian/patches/01_dont_overwrite_changelog b/trunk/epsilon/debian/patches/01_dont_overwrite_changelog
new file mode 100644 (file)
index 0000000..2e43b62
--- /dev/null
@@ -0,0 +1,25 @@
+diff --git epsilon.orig/Makefile.am epsilon/Makefile.am
+index aaa98b2..1128063 100644
+--- epsilon.orig/Makefile.am
++++ epsilon/Makefile.am
+@@ -9,7 +9,7 @@ MAINTAINERCLEANFILES = Makefile.in aclocal.m4 config.guess \
+                      epsilon.spec epsilon.pc depcomp
+ EXTRA_DIST = README AUTHORS COPYING epsilon.spec.in epsilon.spec gendoc \
+-           Doxyfile debian/changelog debian/changelog.in debian/rules \
++           Doxyfile debian/rules \
+            debian/copyright debian/control debian/epsilon0-bin.install \
+            debian/libepsilon0.install debian/libepsilon0-dev.install \
+            epsilon.pc.in
+diff --git epsilon.orig/configure.in epsilon/configure.in
+index 978a3b1..86fa444 100644
+--- epsilon.orig/configure.in
++++ epsilon/configure.in
+@@ -106,7 +106,6 @@ src/lib/Makefile
+ src/lib/exiftags/Makefile
+ src/bin/Makefile
+ src/plugins/Makefile
+-debian/changelog
+ ])
diff --git a/trunk/epsilon/debian/patches/02_epsilon_thumb_canola b/trunk/epsilon/debian/patches/02_epsilon_thumb_canola
new file mode 100644 (file)
index 0000000..9009ef5
--- /dev/null
@@ -0,0 +1,152 @@
+diff -upNr epsilon.orig/src/lib/Epsilon.c epsilon/src/lib/Epsilon.c
+--- epsilon.orig/src/lib/Epsilon.c     2007-12-05 20:26:23.000000000 -0200
++++ epsilon/src/lib/Epsilon.c  2007-12-09 12:15:21.000000000 -0200
+@@ -23,6 +23,9 @@
+ #ifdef HAVE_EPEG_H
+ #include <Epeg.h>
+ #endif
++#define THUMB_HEIGHT_CANOLA 96
++#define THUMB_WIDTH_CANOLA 192
++#define THUMB_SIZE_CANOLA 192
+ #define THUMB_SIZE_NORMAL 128
+ #define THUMB_SIZE_LARGE 256
+ #define THUMB_SIZE_FAIL -1
+@@ -38,9 +41,11 @@
+ static char *PATH_DIR_LARGE = NULL;
+ static char *PATH_DIR_NORMAL = NULL;
++static char *PATH_DIR_CANOLA = NULL;
+ static char *PATH_DIR_FAIL = NULL;
+ static unsigned LEN_DIR_LARGE = 0;
+ static unsigned LEN_DIR_NORMAL = 0;
++static unsigned LEN_DIR_CANOLA = 0;
+ static unsigned LEN_DIR_FAIL = 0;
+@@ -153,6 +158,11 @@ epsilon_init (void)
+      PATH_DIR_NORMAL = strdup(buf);
+      LEN_DIR_NORMAL = strlen(buf);
+   }
++  if (!PATH_DIR_CANOLA) {
++     strncpy(buf + base_len, "/canola", PATH_MAX - base_len);
++     PATH_DIR_CANOLA = strdup(buf);
++     LEN_DIR_CANOLA = strlen(buf);
++  }
+   if (!PATH_DIR_FAIL) {
+      strncpy(buf + base_len, "/fail/epsilon", PATH_MAX - base_len);
+      PATH_DIR_FAIL = strdup(buf);
+@@ -161,6 +171,7 @@ epsilon_init (void)
+   ecore_file_mkpath(PATH_DIR_LARGE);
+   ecore_file_mkpath(PATH_DIR_NORMAL);
++  ecore_file_mkpath(PATH_DIR_CANOLA);
+   ecore_file_mkpath(PATH_DIR_FAIL);
+   plugins_mime = ecore_hash_new(ecore_str_hash, ecore_str_compare);
+@@ -446,6 +457,11 @@ _epsilon_file_name(unsigned thumb_size, 
+       dir = PATH_DIR_NORMAL;
+       dir_len = LEN_DIR_NORMAL;
+      }
++   else if (thumb_size == THUMB_SIZE_CANOLA)
++     {
++      dir = PATH_DIR_CANOLA;
++      dir_len = LEN_DIR_CANOLA;
++     }
+    else
+      {
+       dir = PATH_DIR_FAIL;
+@@ -563,10 +579,10 @@ epsilon_generate (Epsilon * e)
+   if (!e || !e->src || !e->hash)
+     return (EPSILON_FAIL);
+-   
++
+   tw = e->tw;
+   th = e->th;
+-   
++
+ #ifdef HAVE_EPEG_H
+   len = strlen (e->src);
+   if ((len > 4) &&
+@@ -575,15 +591,16 @@ epsilon_generate (Epsilon * e)
+       _epsilon_file_name(e->tw, e->hash, "jpg", outfile, sizeof(outfile));
+       epeg_thumbnail_comments_get (im, &info);
+       epeg_size_get (im, &iw, &ih);
+-      if (iw > ih)
++      /* XXX - hack to force fixed height in case of tw != th (canola) */
++      if (iw > ih && tw == th)
+       {
+-        th = e->th * ((double) ih / (double) iw);
+-         if (th < 1) th = 1;
++        th = ((unsigned long) e->tw * ih) / iw;
++        if (th < 1) th = 1;
+       }
+       else
+       {
+-        tw = e->tw * ((double) iw / (double) ih);
+-         if (tw < 1) tw = 1;
++        tw = ((unsigned long) e->th *  iw) / ih;
++        if (tw < 1) tw = 1;
+       }
+       epeg_decode_size_set (im, tw, th);
+       epeg_quality_set (im, 100);
+@@ -738,7 +755,7 @@ void
+ epsilon_thumb_size(Epsilon *e, Epsilon_Thumb_Size size)
+ {
+    if (!e) return;
+-   
++
+    switch (size)
+      {
+       case EPSILON_THUMB_NORMAL:
+@@ -749,7 +766,11 @@ epsilon_thumb_size(Epsilon *e, Epsilon_T
+       e->tw = THUMB_SIZE_LARGE;
+       e->th = THUMB_SIZE_LARGE;
+       break;
+-     }   
++      case EPSILON_THUMB_CANOLA:
++      e->tw = THUMB_WIDTH_CANOLA;
++      e->th = THUMB_HEIGHT_CANOLA;
++    break;
++     }
+ }
+diff -upNr epsilon.orig/src/lib/Epsilon.h epsilon/src/lib/Epsilon.h
+--- epsilon.orig/src/lib/Epsilon.h     2007-12-05 20:26:23.000000000 -0200
++++ epsilon/src/lib/Epsilon.h  2007-12-09 12:15:21.000000000 -0200
+@@ -58,7 +58,8 @@ typedef struct _Epsilon_Info Epsilon_Inf
+ enum _Epsilon_Thumb_Size
+ {
+    EPSILON_THUMB_NORMAL,
+-   EPSILON_THUMB_LARGE
++   EPSILON_THUMB_LARGE,
++   EPSILON_THUMB_CANOLA
+ };
+ typedef enum _Epsilon_Thumb_Size Epsilon_Thumb_Size;
+diff -upNr epsilon.orig/src/lib/epsilon_thumb.c epsilon/src/lib/epsilon_thumb.c
+--- epsilon.orig/src/lib/epsilon_thumb.c       2007-12-05 20:26:23.000000000 -0200
++++ epsilon/src/lib/epsilon_thumb.c    2007-12-09 12:15:21.000000000 -0200
+@@ -218,6 +218,9 @@ epsilon_cb_server_data(void *data, int t
+       if (e->server != epsilon_server)
+               return 1;
++      if (!(e && e->data))
++              return 1;
++
+       msg = e->data;
+       Epsilon_Request *thumb;
+diff -upNr epsilon.orig/src/lib/exiftags/canon.c epsilon/src/lib/exiftags/canon.c
+--- epsilon.orig/src/lib/exiftags/canon.c      2007-12-05 20:26:23.000000000 -0200
++++ epsilon/src/lib/exiftags/canon.c   2007-12-09 12:15:21.000000000 -0200
+@@ -52,7 +52,7 @@
+ struct ccstm {
+       int32_t val;
+       struct descrip *table;
+-      const char descr[];
++      const char *descr;
+ };
diff --git a/trunk/epsilon/debian/patches/series b/trunk/epsilon/debian/patches/series
new file mode 100644 (file)
index 0000000..bcc6b11
--- /dev/null
@@ -0,0 +1,2 @@
+01_dont_overwrite_changelog
+02_epsilon_thumb_canola
diff --git a/trunk/epsilon/debian/rules b/trunk/epsilon/debian/rules
new file mode 100755 (executable)
index 0000000..58a76e7
--- /dev/null
@@ -0,0 +1,11 @@
+#!/usr/bin/make -f
+
+include /usr/share/cdbs/1/rules/debhelper.mk
+include /usr/share/cdbs/1/class/autotools.mk
+
+DEB_BUILD_ARCH  ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)
+
+ifneq (,$(findstring armel,$(DEB_BUILD_ARCH)))
+       CFLAGS += -DNDEBUG=1 -fomit-frame-pointer -O2 -mfpu=vfp -mfloat-abi=softfp -mcpu=arm1136jf-s -ffast-math -funsafe-math-optimizations -fno-math-errno -fsingle-precision-constant
+endif
+
diff --git a/trunk/epsilon/debian_gregale/changelog b/trunk/epsilon/debian_gregale/changelog
new file mode 100644 (file)
index 0000000..5f914c5
--- /dev/null
@@ -0,0 +1,5 @@
+epsilon (0.3.0.011-maemo.1) unstable; urgency=low
+
+  * Maemo build.
+
+ -- Eduardo Lima (Etrunko) <eduardo.lima@indt.org.br>  Sun, 09 Dec 2007 12:14:27 -0200
diff --git a/trunk/epsilon/debian_gregale/control b/trunk/epsilon/debian_gregale/control
new file mode 100644 (file)
index 0000000..9eef5cb
--- /dev/null
@@ -0,0 +1,38 @@
+Source: epsilon
+Section: libs
+Priority: optional
+Maintainer: Maemo-EFL Team <maemo-efl-devel@garage.maemo.org>
+Build-Depends: cdbs, debhelper, zlib1g-dev, libepeg-dev, libevas-dev, libecore-dev, libedje-dev, libimlib2-dev, libpng12-dev
+Standards-Version: 3.7.2
+
+Package: libepsilon0-dev
+Section: libdevel
+Architecture: any
+Depends: libepsilon0 (= ${Source-Version})
+Provides: libepsilon-dev
+Description: Enlightenment thumbnailing library development files
+ This is a small, display independent, and quick thumbnailing library.
+ .
+ This package contains headers and static libraries for development with
+ libepeg.
+
+Package: libepsilon0
+Section: libs
+Architecture: any
+Depends: ${shlibs:Depends}
+Recommends: epsilon-bin
+Provides: libepsilon
+Description: Enlightenment thumbnailing library API
+ This is a small, display independent, and quick thumbnailing library.
+ .
+ This package contains the shared library.
+
+Package: epsilon0-bin
+Section: libs
+Architecture: any
+Depends: ${shlibs:Depends}
+Provides: epsilon-bin
+Description: Enlightenment thumbnailing binary
+ This is a small, display independent, and quick thumbnailing library.
+ .
+ This package contains the Epsilon binary program.
diff --git a/trunk/epsilon/debian_gregale/copyright b/trunk/epsilon/debian_gregale/copyright
new file mode 100644 (file)
index 0000000..c62ceff
--- /dev/null
@@ -0,0 +1,34 @@
+This package was debianized by Sytse Wielinga <s.b.wielinga@student.utwente.nl> on
+Thu,  4 Mar 2004 22:41:20 +0100
+
+The source is downloaded from the e17/libs/epsilon module of the enlightenment CVS 
+tree. For more information, see:
+
+  http://www.enlightenment.org/cvs.html
+
+Upstream Authors: Enlightenment team <enlightenment-devel@lists.sourceforge.net>
+
+License:
+
+    Redistribution and use in source and binary forms, with or without
+    modification, are permitted under the terms of the BSD License.
+
+    THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+    ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+    IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+    ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+    FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+    DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+    OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+    HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+    LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+    OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+    SUCH DAMAGE.
+
+On Debian systems, the complete text of the BSD License can be
+found in `/usr/share/common-licenses/BSD'.
+
+
+The Debian packaging is (C) 2007, E17 Debian Team <debian@edevelop.org> and
+is licensed under the GPL, see `/usr/share/common-licenses/GPL'.
+
diff --git a/trunk/epsilon/debian_gregale/epsilon0-bin.install b/trunk/epsilon/debian_gregale/epsilon0-bin.install
new file mode 100644 (file)
index 0000000..a5504af
--- /dev/null
@@ -0,0 +1,2 @@
+debian/tmp/usr/bin/epsilon
+debian/tmp/usr/bin/epsilon_thumbd
diff --git a/trunk/epsilon/debian_gregale/libepsilon0-dev.install b/trunk/epsilon/debian_gregale/libepsilon0-dev.install
new file mode 100644 (file)
index 0000000..d33fb9b
--- /dev/null
@@ -0,0 +1,5 @@
+debian/tmp/usr/lib/pkgconfig/*
+debian/tmp/usr/include/*
+debian/tmp/usr/lib/lib*.a
+debian/tmp/usr/lib/lib*.so
+debian/tmp/usr/lib/lib*.la
diff --git a/trunk/epsilon/debian_gregale/libepsilon0.install b/trunk/epsilon/debian_gregale/libepsilon0.install
new file mode 100644 (file)
index 0000000..c45ebcf
--- /dev/null
@@ -0,0 +1 @@
+debian/tmp/usr/lib/lib*.so.*
diff --git a/trunk/epsilon/debian_gregale/patches/01_dont_overwrite_changelog b/trunk/epsilon/debian_gregale/patches/01_dont_overwrite_changelog
new file mode 100644 (file)
index 0000000..2e43b62
--- /dev/null
@@ -0,0 +1,25 @@
+diff --git epsilon.orig/Makefile.am epsilon/Makefile.am
+index aaa98b2..1128063 100644
+--- epsilon.orig/Makefile.am
++++ epsilon/Makefile.am
+@@ -9,7 +9,7 @@ MAINTAINERCLEANFILES = Makefile.in aclocal.m4 config.guess \
+                      epsilon.spec epsilon.pc depcomp
+ EXTRA_DIST = README AUTHORS COPYING epsilon.spec.in epsilon.spec gendoc \
+-           Doxyfile debian/changelog debian/changelog.in debian/rules \
++           Doxyfile debian/rules \
+            debian/copyright debian/control debian/epsilon0-bin.install \
+            debian/libepsilon0.install debian/libepsilon0-dev.install \
+            epsilon.pc.in
+diff --git epsilon.orig/configure.in epsilon/configure.in
+index 978a3b1..86fa444 100644
+--- epsilon.orig/configure.in
++++ epsilon/configure.in
+@@ -106,7 +106,6 @@ src/lib/Makefile
+ src/lib/exiftags/Makefile
+ src/bin/Makefile
+ src/plugins/Makefile
+-debian/changelog
+ ])
diff --git a/trunk/epsilon/debian_gregale/patches/02_epsilon_thumb_canola b/trunk/epsilon/debian_gregale/patches/02_epsilon_thumb_canola
new file mode 100644 (file)
index 0000000..9009ef5
--- /dev/null
@@ -0,0 +1,152 @@
+diff -upNr epsilon.orig/src/lib/Epsilon.c epsilon/src/lib/Epsilon.c
+--- epsilon.orig/src/lib/Epsilon.c     2007-12-05 20:26:23.000000000 -0200
++++ epsilon/src/lib/Epsilon.c  2007-12-09 12:15:21.000000000 -0200
+@@ -23,6 +23,9 @@
+ #ifdef HAVE_EPEG_H
+ #include <Epeg.h>
+ #endif
++#define THUMB_HEIGHT_CANOLA 96
++#define THUMB_WIDTH_CANOLA 192
++#define THUMB_SIZE_CANOLA 192
+ #define THUMB_SIZE_NORMAL 128
+ #define THUMB_SIZE_LARGE 256
+ #define THUMB_SIZE_FAIL -1
+@@ -38,9 +41,11 @@
+ static char *PATH_DIR_LARGE = NULL;
+ static char *PATH_DIR_NORMAL = NULL;
++static char *PATH_DIR_CANOLA = NULL;
+ static char *PATH_DIR_FAIL = NULL;
+ static unsigned LEN_DIR_LARGE = 0;
+ static unsigned LEN_DIR_NORMAL = 0;
++static unsigned LEN_DIR_CANOLA = 0;
+ static unsigned LEN_DIR_FAIL = 0;
+@@ -153,6 +158,11 @@ epsilon_init (void)
+      PATH_DIR_NORMAL = strdup(buf);
+      LEN_DIR_NORMAL = strlen(buf);
+   }
++  if (!PATH_DIR_CANOLA) {
++     strncpy(buf + base_len, "/canola", PATH_MAX - base_len);
++     PATH_DIR_CANOLA = strdup(buf);
++     LEN_DIR_CANOLA = strlen(buf);
++  }
+   if (!PATH_DIR_FAIL) {
+      strncpy(buf + base_len, "/fail/epsilon", PATH_MAX - base_len);
+      PATH_DIR_FAIL = strdup(buf);
+@@ -161,6 +171,7 @@ epsilon_init (void)
+   ecore_file_mkpath(PATH_DIR_LARGE);
+   ecore_file_mkpath(PATH_DIR_NORMAL);
++  ecore_file_mkpath(PATH_DIR_CANOLA);
+   ecore_file_mkpath(PATH_DIR_FAIL);
+   plugins_mime = ecore_hash_new(ecore_str_hash, ecore_str_compare);
+@@ -446,6 +457,11 @@ _epsilon_file_name(unsigned thumb_size, 
+       dir = PATH_DIR_NORMAL;
+       dir_len = LEN_DIR_NORMAL;
+      }
++   else if (thumb_size == THUMB_SIZE_CANOLA)
++     {
++      dir = PATH_DIR_CANOLA;
++      dir_len = LEN_DIR_CANOLA;
++     }
+    else
+      {
+       dir = PATH_DIR_FAIL;
+@@ -563,10 +579,10 @@ epsilon_generate (Epsilon * e)
+   if (!e || !e->src || !e->hash)
+     return (EPSILON_FAIL);
+-   
++
+   tw = e->tw;
+   th = e->th;
+-   
++
+ #ifdef HAVE_EPEG_H
+   len = strlen (e->src);
+   if ((len > 4) &&
+@@ -575,15 +591,16 @@ epsilon_generate (Epsilon * e)
+       _epsilon_file_name(e->tw, e->hash, "jpg", outfile, sizeof(outfile));
+       epeg_thumbnail_comments_get (im, &info);
+       epeg_size_get (im, &iw, &ih);
+-      if (iw > ih)
++      /* XXX - hack to force fixed height in case of tw != th (canola) */
++      if (iw > ih && tw == th)
+       {
+-        th = e->th * ((double) ih / (double) iw);
+-         if (th < 1) th = 1;
++        th = ((unsigned long) e->tw * ih) / iw;
++        if (th < 1) th = 1;
+       }
+       else
+       {
+-        tw = e->tw * ((double) iw / (double) ih);
+-         if (tw < 1) tw = 1;
++        tw = ((unsigned long) e->th *  iw) / ih;
++        if (tw < 1) tw = 1;
+       }
+       epeg_decode_size_set (im, tw, th);
+       epeg_quality_set (im, 100);
+@@ -738,7 +755,7 @@ void
+ epsilon_thumb_size(Epsilon *e, Epsilon_Thumb_Size size)
+ {
+    if (!e) return;
+-   
++
+    switch (size)
+      {
+       case EPSILON_THUMB_NORMAL:
+@@ -749,7 +766,11 @@ epsilon_thumb_size(Epsilon *e, Epsilon_T
+       e->tw = THUMB_SIZE_LARGE;
+       e->th = THUMB_SIZE_LARGE;
+       break;
+-     }   
++      case EPSILON_THUMB_CANOLA:
++      e->tw = THUMB_WIDTH_CANOLA;
++      e->th = THUMB_HEIGHT_CANOLA;
++    break;
++     }
+ }
+diff -upNr epsilon.orig/src/lib/Epsilon.h epsilon/src/lib/Epsilon.h
+--- epsilon.orig/src/lib/Epsilon.h     2007-12-05 20:26:23.000000000 -0200
++++ epsilon/src/lib/Epsilon.h  2007-12-09 12:15:21.000000000 -0200
+@@ -58,7 +58,8 @@ typedef struct _Epsilon_Info Epsilon_Inf
+ enum _Epsilon_Thumb_Size
+ {
+    EPSILON_THUMB_NORMAL,
+-   EPSILON_THUMB_LARGE
++   EPSILON_THUMB_LARGE,
++   EPSILON_THUMB_CANOLA
+ };
+ typedef enum _Epsilon_Thumb_Size Epsilon_Thumb_Size;
+diff -upNr epsilon.orig/src/lib/epsilon_thumb.c epsilon/src/lib/epsilon_thumb.c
+--- epsilon.orig/src/lib/epsilon_thumb.c       2007-12-05 20:26:23.000000000 -0200
++++ epsilon/src/lib/epsilon_thumb.c    2007-12-09 12:15:21.000000000 -0200
+@@ -218,6 +218,9 @@ epsilon_cb_server_data(void *data, int t
+       if (e->server != epsilon_server)
+               return 1;
++      if (!(e && e->data))
++              return 1;
++
+       msg = e->data;
+       Epsilon_Request *thumb;
+diff -upNr epsilon.orig/src/lib/exiftags/canon.c epsilon/src/lib/exiftags/canon.c
+--- epsilon.orig/src/lib/exiftags/canon.c      2007-12-05 20:26:23.000000000 -0200
++++ epsilon/src/lib/exiftags/canon.c   2007-12-09 12:15:21.000000000 -0200
+@@ -52,7 +52,7 @@
+ struct ccstm {
+       int32_t val;
+       struct descrip *table;
+-      const char descr[];
++      const char *descr;
+ };
diff --git a/trunk/epsilon/debian_gregale/patches/series b/trunk/epsilon/debian_gregale/patches/series
new file mode 100644 (file)
index 0000000..bcc6b11
--- /dev/null
@@ -0,0 +1,2 @@
+01_dont_overwrite_changelog
+02_epsilon_thumb_canola
diff --git a/trunk/epsilon/debian_gregale/rules b/trunk/epsilon/debian_gregale/rules
new file mode 100755 (executable)
index 0000000..7822d49
--- /dev/null
@@ -0,0 +1,11 @@
+#!/usr/bin/make -f
+
+include /usr/share/cdbs/1/rules/debhelper.mk
+include /usr/share/cdbs/1/class/autotools.mk
+
+DEB_BUILD_ARCH  ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)
+
+ifneq (,$(findstring armel,$(DEB_BUILD_ARCH)))
+       CFLAGS += -DNDEBUG=1 -fomit-frame-pointer -O2 -mcpu=arm926ej-s -ffast-math -funsafe-math-optimizations -fno-math-errno -fsingle-precision-constant
+endif
+