diff options
author | obache <obache> | 2009-11-26 12:30:12 +0000 |
---|---|---|
committer | obache <obache> | 2009-11-26 12:30:12 +0000 |
commit | c396be840d7522a906f40dd921c94114e3c1d3de (patch) | |
tree | f879ab1193497129008165b0014a023464162c9b /inputmethod | |
parent | 4fe14177969724f3df26bc5eb03cffb6da2bf684 (diff) | |
download | pkgsrc-c396be840d7522a906f40dd921c94114e3c1d3de.tar.gz |
* adjust short option as described in long option and source code (patch-af)
* fixes unportable, broken socket connect/bind (patch-ae, patch-ag)
Bump PKGREVISION.
Diffstat (limited to 'inputmethod')
-rw-r--r-- | inputmethod/scim-bridge/Makefile | 3 | ||||
-rw-r--r-- | inputmethod/scim-bridge/distinfo | 5 | ||||
-rw-r--r-- | inputmethod/scim-bridge/patches/patch-ae | 33 | ||||
-rw-r--r-- | inputmethod/scim-bridge/patches/patch-af | 13 | ||||
-rw-r--r-- | inputmethod/scim-bridge/patches/patch-ag | 24 |
5 files changed, 76 insertions, 2 deletions
diff --git a/inputmethod/scim-bridge/Makefile b/inputmethod/scim-bridge/Makefile index fc80ed6d56b..8a7b1ec54b4 100644 --- a/inputmethod/scim-bridge/Makefile +++ b/inputmethod/scim-bridge/Makefile @@ -1,7 +1,8 @@ -# $NetBSD: Makefile,v 1.1.1.1 2009/11/24 11:49:44 obache Exp $ +# $NetBSD: Makefile,v 1.2 2009/11/26 12:30:12 obache Exp $ # DISTNAME= scim-bridge-0.4.16 +PKGREVISION= 1 CATEGORIES= inputmethod MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=scim/} diff --git a/inputmethod/scim-bridge/distinfo b/inputmethod/scim-bridge/distinfo index f358d60fc7e..fcdbe292074 100644 --- a/inputmethod/scim-bridge/distinfo +++ b/inputmethod/scim-bridge/distinfo @@ -1,4 +1,4 @@ -$NetBSD: distinfo,v 1.1.1.1 2009/11/24 11:49:44 obache Exp $ +$NetBSD: distinfo,v 1.2 2009/11/26 12:30:12 obache Exp $ SHA1 (scim-bridge-0.4.16.tar.gz) = 6a7a714592dbecc9a1f44794f37319bafe2bdfae RMD160 (scim-bridge-0.4.16.tar.gz) = 37aed056fb880358b013f104f08b2e58c3de4188 @@ -7,3 +7,6 @@ SHA1 (patch-aa) = e4d0803a8d572e2efb79128c307d25bd867007ac SHA1 (patch-ab) = 7c103b3da298e8ed72e84c239a3fc4617a647ce5 SHA1 (patch-ac) = e7dd5f64e3fcd9cdc03199d041fefb09fce9ff8f SHA1 (patch-ad) = cc87a5c24af8c066482d164b2805602ed90e2acb +SHA1 (patch-ae) = 2e8f264da95760b90d40355202fe21b81e0f12c8 +SHA1 (patch-af) = 3db943f7180838a475d4a0c2fca9c52d6dc3cd43 +SHA1 (patch-ag) = 45915bc63fd6228fe2033336fe3313f7ce639ef6 diff --git a/inputmethod/scim-bridge/patches/patch-ae b/inputmethod/scim-bridge/patches/patch-ae new file mode 100644 index 00000000000..c1fb33d3251 --- /dev/null +++ b/inputmethod/scim-bridge/patches/patch-ae @@ -0,0 +1,33 @@ +$NetBSD: patch-ae,v 1.1 2009/11/26 12:30:12 obache Exp $ + +--- agent/scim-bridge-agent-accept-listener.cpp.orig 2009-04-19 03:42:18.000000000 +0000 ++++ agent/scim-bridge-agent-accept-listener.cpp +@@ -30,6 +30,10 @@ + #include <sys/types.h> + #include <sys/un.h> + ++#ifndef SUN_LEN ++#define SUN_LEN(x) (sizeof(*(x)) - sizeof((x)->sun_path + strlen ((x)->sun_path)) ++#endif ++ + #include "scim-bridge-output.h" + #include "scim-bridge-path.h" + +@@ -111,7 +115,7 @@ retval_t ScimBridgeAgentAcceptListenerIm + const int MAX_TRIAL = 5; + for (int i = 0; i < MAX_TRIAL; ++i) { + scim_bridge_pdebugln (8, "Pinging for the another agent process..."); +- if (connect (socket_fd, (struct sockaddr*)&socket_addr, sizeof (socket_addr.sun_family) + strlen (socket_addr.sun_path))) { ++ if (connect (socket_fd, (struct sockaddr*)&socket_addr, SUN_LEN(&socket_addr))) { + if (i == MAX_TRIAL - 1) { + scim_bridge_pdebugln (6, "It seems like there is no other agent for the old socket."); + break; +@@ -163,7 +167,7 @@ retval_t ScimBridgeAgentAcceptListenerIm + return RETVAL_FAILED; + } + +- if (bind (socket_fd, (struct sockaddr*)&socket_addr, strlen (socket_addr.sun_path) + sizeof (socket_addr.sun_family)) != 0) { ++ if (bind (socket_fd, (struct sockaddr*)&socket_addr, SUN_LEN(&socket_addr)) != 0) { + scim_bridge_perrorln ("Cannot bind the socket: %s", strerror (errno)); + close (socket_fd); + socket_fd = -1; diff --git a/inputmethod/scim-bridge/patches/patch-af b/inputmethod/scim-bridge/patches/patch-af new file mode 100644 index 00000000000..785d05ebb19 --- /dev/null +++ b/inputmethod/scim-bridge/patches/patch-af @@ -0,0 +1,13 @@ +$NetBSD: patch-af,v 1.1 2009/11/26 12:30:12 obache Exp $ + +--- agent/scim-bridge-agent-application.cpp.orig 2009-01-18 02:04:20.000000000 +0900 ++++ agent/scim-bridge-agent-application.cpp +@@ -60,7 +60,7 @@ int main (int argc, char *argv[]) + {0, 0, NULL, 0} + }; + +- char short_options[] = "vhqdls:b:"; ++ char short_options[] = "vhql:sn"; + + unsigned int tmp_uint; + diff --git a/inputmethod/scim-bridge/patches/patch-ag b/inputmethod/scim-bridge/patches/patch-ag new file mode 100644 index 00000000000..ae562913cff --- /dev/null +++ b/inputmethod/scim-bridge/patches/patch-ag @@ -0,0 +1,24 @@ +$NetBSD: patch-ag,v 1.1 2009/11/26 12:30:12 obache Exp $ + +--- client-common/scim-bridge-client.c.orig 2008-11-02 06:44:34.000000000 +0000 ++++ client-common/scim-bridge-client.c +@@ -29,6 +29,10 @@ + #include <sys/un.h> + #include <sys/wait.h> + ++#ifndef SUN_LEN ++#define SUN_LEN(x) (sizeof(*(x)) - sizeof((x)->sun_path + strlen ((x)->sun_path)) ++#endif ++ + #include "scim-bridge-client.h" + #include "scim-bridge-client-imcontext.h" + #include "scim-bridge-client-protected.h" +@@ -1052,7 +1056,7 @@ retval_t scim_bridge_client_open_messeng + socket_addr.sun_family = AF_UNIX; + strcpy (socket_addr.sun_path, scim_bridge_path_get_socket ()); + +- if (connect (socket_fd, (struct sockaddr*)&socket_addr, sizeof (socket_addr.sun_family) + strlen (socket_addr.sun_path))) { ++ if (connect (socket_fd, (struct sockaddr*)&socket_addr, SUN_LEN(&socket_addr))) { + if (i == 5 && launch_agent ()) { + scim_bridge_perrorln ("Cannot launch the agent"); + return RETVAL_FAILED; |