Source: scim-pinyin
Version: 0.5.0-2
Tags: patch pending
Severity: serious
Justification: fails to build from source

I am reporting this bug against my own package, mainly to provide an 
example on how to make an SCIM module package adapt to the $(moduledir) 
change in the new scim 1.4.6-1.

The things SCIM module packages need to do:
    1.  Build-depend on libscim-dev (>= 1.4.6-1);
    2a. If already using a patch to change @SCIM_MODULEDIR@/* to
        @SCIM_MODULEDIR@/1.4.0/* in Makefile.{am,in}, drop such patch.
    2b. If not using such a patch, make necessary changes to deal with
        the move of installed module files from /usr/lib/scim-1.0/*/ to
        /usr/lib/scim-1.0/1.4.0/*/.
    3.  (Optional) Change all references to /usr/lib/scim-1.0/1.4.0/ to
        /usr/lib/scim-1.0/*/ so that binNMU is possible for the next SCIM
        module ABI change.

Ming
2007.05.07

Index: debian/control
===================================================================
--- debian/control      (revision 859)
+++ debian/control      (working copy)
@@ -3,7 +3,7 @@
 Priority: optional
 Maintainer: Ming Hua <[EMAIL PROTECTED]>
 Uploaders: Osamu Aoki <[EMAIL PROTECTED]>
-Build-Depends: debhelper (>= 4.0.0), dpatch, autotools-dev, libgtk2.0-dev, 
libscim-dev (>= 1.4.0)
+Build-Depends: debhelper (>= 4.0.0), dpatch, autotools-dev, libgtk2.0-dev, 
libscim-dev (>= 1.4.6-1)
 Standards-Version: 3.6.2
 
 Package: scim-pinyin
Index: debian/scim-pinyin.install
===================================================================
--- debian/scim-pinyin.install  (revision 859)
+++ debian/scim-pinyin.install  (working copy)
@@ -1,5 +1,5 @@
-usr/lib/scim-1.0/1.4.0/IMEngine/pinyin.so
-usr/lib/scim-1.0/1.4.0/SetupUI/pinyin-imengine-setup.so
+usr/lib/scim-1.0/*/IMEngine/pinyin.so
+usr/lib/scim-1.0/*/SetupUI/pinyin-imengine-setup.so
 
 usr/share/scim/pinyin/*
 usr/share/locale/*/LC_MESSAGES/scim-pinyin.mo
Index: debian/patches/00list
===================================================================
--- debian/patches/00list       (revision 859)
+++ debian/patches/00list       (working copy)
@@ -1,2 +1 @@
 01gcc-4.0.dpatch
-10scim-plugin-module-install-dir.dpatch
Index: debian/patches/10scim-plugin-module-install-dir.dpatch
===================================================================
--- debian/patches/10scim-plugin-module-install-dir.dpatch      (revision 859)
+++ debian/patches/10scim-plugin-module-install-dir.dpatch      (working copy)
@@ -1,76 +0,0 @@
-#! /bin/sh -e
-## 01_module-install-dir.dpatch by Ming Hua <[EMAIL PROTECTED]>
-##
-## All lines beginning with `## DP:' are a description of the patch.
-## DP: Change the scim module installation directory from /usr/lib/scim-1.0/ to
-## DP: /usr/lib/scim-1.0/1.2.0/.  When 1.0.0 was released, upstream claimed
-## DP: there is possibility that version 1.2.0 will change the native module
-## DP: directory but keep the compatibility with the external modules.  In my
-## DP: opinion this is broken design, and I changed the directory from
-## DP: /usr/lib/scim-1.0 to /usr/lib/scim/1.0.0 for Debian package.  It turned
-## DP: out that 1.2.0 indeed broke the ABI.  I am happy with my judgement and
-## DP: will continue to maintain a similar patch for all scim modules.  I am
-## DP: still not quite sure this design is technically correct or not, but it
-## DP: seems GTK IM module uses a similar design.  Oh well.
-
-if [ $# -lt 1 ]; then
-    echo "`basename $0`: script expects -patch|-unpatch as argument" >&2
-    exit 1
-fi
-
-[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts
-patch_opts="${patch_opts:--f --no-backup-if-mismatch} ${2:+-d $2}"
-
-case "$1" in
-    -patch) patch -p1 ${patch_opts} < $0;;
-    -unpatch) patch -R -p1 ${patch_opts} < $0;;
-    *)
-        echo "`basename $0`: script expects -patch|-unpatch as argument" >&2
-        exit 1;;
-esac
-
-exit 0
-
[EMAIL PROTECTED]@
-diff -urNad scim-pinyin-0.5.0/src/Makefile.am 
/tmp/dpep.VgYQu0/scim-pinyin-0.5.0/src/Makefile.am
---- scim-pinyin-0.5.0/src/Makefile.am  2005-05-09 19:58:02.775549776 -0500
-+++ /tmp/dpep.VgYQu0/scim-pinyin-0.5.0/src/Makefile.am 2005-05-09 
20:02:32.243584408 -0500
-@@ -51,7 +51,7 @@
- libpinyin_la_CXXFLAGS = @SCIM_CFLAGS@
- libpinyin_la_LDFLAGS  = @SCIM_LIBS@ 
- 
--moduledir             = @SCIM_MODULEDIR@/IMEngine
-+moduledir             = @SCIM_MODULEDIR@/1.4.0/IMEngine
- module_LTLIBRARIES    = pinyin.la
- 
- pinyin_la_SOURCES     = scim_pinyin_imengine.cpp
-@@ -72,7 +72,7 @@
- SETUP_MODULE = pinyin-imengine-setup.la
- endif
- 
--setupmoduledir           = @SCIM_MODULEDIR@/SetupUI
-+setupmoduledir           = @SCIM_MODULEDIR@/1.4.0/SetupUI
- setupmodule_LTLIBRARIES  = $(SETUP_MODULE)
- 
- pinyin_imengine_setup_la_SOURCES = scim_pinyin_imengine_setup.cpp
-diff -urNad scim-pinyin-0.5.0/src/Makefile.in 
/tmp/dpep.VgYQu0/scim-pinyin-0.5.0/src/Makefile.in
---- scim-pinyin-0.5.0/src/Makefile.in  2005-05-09 19:58:02.778549320 -0500
-+++ /tmp/dpep.VgYQu0/scim-pinyin-0.5.0/src/Makefile.in 2005-05-09 
20:03:16.510854760 -0500
-@@ -315,7 +315,7 @@
- libpinyin_la_CFLAGS = @SCIM_CFLAGS@
- libpinyin_la_CXXFLAGS = @SCIM_CFLAGS@
- libpinyin_la_LDFLAGS = @SCIM_LIBS@ 
--moduledir = @SCIM_MODULEDIR@/IMEngine
-+moduledir = @SCIM_MODULEDIR@/1.4.0/IMEngine
- module_LTLIBRARIES = pinyin.la
- pinyin_la_SOURCES = scim_pinyin_imengine.cpp
- pinyin_la_CFLAGS = @SCIM_CFLAGS@
-@@ -329,7 +329,7 @@
- 
- pinyin_la_LIBADD = libpinyin.la
- @[EMAIL PROTECTED] = pinyin-imengine-setup.la
--setupmoduledir = @SCIM_MODULEDIR@/SetupUI
-+setupmoduledir = @SCIM_MODULEDIR@/1.4.0/SetupUI
- setupmodule_LTLIBRARIES = $(SETUP_MODULE)
- pinyin_imengine_setup_la_SOURCES = scim_pinyin_imengine_setup.cpp
- pinyin_imengine_setup_la_CFLAGS = @SCIM_GTKUTILS_CFLAGS@ @SCIM_CFLAGS@
Index: debian/changelog
===================================================================
--- debian/changelog    (revision 859)
+++ debian/changelog    (working copy)
@@ -1,8 +1,13 @@
 scim-pinyin (0.5.0-2+SVN) UNRELEASED; urgency=low
 
-  * dummy entry
+  * Adapt to scim's $(moduledir) change:
+    - Bump build dependency to libscim-dev (>= 1.4.6-1).
+    - Drop 10scim-plugin-module-install-dir dpatch, no longer needed.
+    - Use /usr/lib/scim-1.0/*/ instead of /usr/lib/scim-1.0/1.4.0/ in
+      debian/rules and debian/scim-pinyin.install, so that scim-pinyin can be
+      binNMUed for the next SCIM module ABI change.
 
- -- Ming Hua <[EMAIL PROTECTED]>  Mon,  9 Jan 2006 18:04:47 -0600
+ -- Ming Hua <[EMAIL PROTECTED]>  Mon, 07 May 2007 18:47:29 -0500
 
 scim-pinyin (0.5.0-2) unstable; urgency=low
 
Index: debian/rules
===================================================================
--- debian/rules        (revision 859)
+++ debian/rules        (working copy)
@@ -92,7 +92,7 @@
        $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
 
        # Clean up unnecessary static libraries for modules
-       rm debian/tmp/usr/lib/scim-1.0/1.4.0/*/*.la
+       rm debian/tmp/usr/lib/scim-1.0/*/*/*.la
 
        # Prepare files for different packages to separate directories
        dh_install --sourcedir=debian/tmp --fail-missing


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to