[packages/obexftp] missing includes, types and more ruby fixes
atler
atler at pld-linux.org
Wed Jul 30 20:26:24 CEST 2025
commit f2c9bc46f6e08e86b9898ba7fbb80f196e48fd0c
Author: Jan Palus <atler at pld-linux.org>
Date: Wed Jul 30 20:19:49 2025 +0200
missing includes, types and more ruby fixes
- include common.h, which includes config.h, before macros from config.h
are used (HAVE_SYS_TIMES_H)
- hack: include bluetooth.h before including obex.h. as a matter of fact
it's obex.h which should include it but then it starts to conflict
with ruby headers due to conflicting symbol names so let's just settle
for this hack
includes.patch | 30 ++++++++++++++++++++++++++++++
obexftp-ruby1.9.patch | 23 +++++++++++++++++++++++
obexftp.spec | 4 ++++
types.patch | 11 +++++++++++
4 files changed, 68 insertions(+)
---
diff --git a/obexftp.spec b/obexftp.spec
index 34baa5f..32e6bd7 100644
--- a/obexftp.spec
+++ b/obexftp.spec
@@ -13,6 +13,8 @@ Patch2: %{name}-nostress.patch
Patch3: %{name}-ruby1.9.patch
Patch4: am.patch
Patch5: format-security.patch
+Patch6: includes.patch
+Patch7: types.patch
URL: http://triq.net/obex/
BuildRequires: autoconf
BuildRequires: automake
@@ -148,6 +150,8 @@ Wiązanie Tcl-a dla biblioteki ObexFTP.
%patch -P3 -p1
%patch -P4 -p1
%patch -P5 -p1
+%patch -P6 -p1
+%patch -P7 -p1
# hack for -L/usr/%{_lib} before -L../../obexftp/.libs
ln -sf ../../obexftp/.libs/libobexftp.so swig/ruby
diff --git a/includes.patch b/includes.patch
new file mode 100644
index 0000000..6a96f39
--- /dev/null
+++ b/includes.patch
@@ -0,0 +1,30 @@
+--- obexftp-0.23/apps/obexftp.c.orig 2009-02-17 19:27:48.000000000 +0100
++++ obexftp-0.23/apps/obexftp.c 2025-07-30 00:46:18.286246386 +0200
+@@ -29,6 +29,8 @@
+
+ #include <sys/types.h>
+
++#include <common.h>
++
+ #ifdef HAVE_SYS_TIMES_H
+ #include <sys/times.h>
+ #endif
+@@ -45,8 +49,6 @@
+ #define EINPROGRESS WSAEINPROGRESS
+ #endif /* _WIN32 */
+
+-#include <common.h>
+-
+ // perhaps this scheme would be better?
+ // IRDA irda://[nick?]
+ // CABLE tty://path
+--- obexftp-0.23/apps/obexftpd.c.orig 2025-07-30 00:46:56.685477113 +0200
++++ obexftp-0.23/apps/obexftpd.c 2025-07-30 00:52:51.008951056 +0200
+@@ -56,6 +56,7 @@
+ #include <netdb.h>
+ #endif
+
++#include <bluetooth/bluetooth.h>
+ /* just until there is a server layer in obexftp */
+ #include <openobex/obex.h>
+
diff --git a/obexftp-ruby1.9.patch b/obexftp-ruby1.9.patch
index 8ff300f..6a012fd 100644
--- a/obexftp-ruby1.9.patch
+++ b/obexftp-ruby1.9.patch
@@ -9,3 +9,26 @@
+--- obexftp-0.23/swig/ruby/ruby_wrap.c.orig 2025-07-30 00:53:47.459228395 +0200
++++ obexftp-0.23/swig/ruby/ruby_wrap.c 2025-07-30 01:10:12.116355514 +0200
+@@ -2106,7 +2106,7 @@
+ arg1 = (obexftp_client_t *)(argp1);
+ {
+ arg2 = proxy_info_cb;
+- arg3 = argv[0];
++ arg3 = (void*) argv[0];
+ }
+ obexftp_client_t_callback(arg1,arg2,arg3);
+ return Qnil;
+@@ -2579,7 +2579,11 @@
+
+
+ /* VALUE str = StringValue(argv[0]); // perhaps better? */
++ #if defined(StringValuePtr)
++ arg2 = StringValuePtr(argv[0]);
++ #else
+ arg2 = STR2CSTR(argv[0]);
++ #endif
+ arg3 = (int) RSTRING_LEN(argv[0]);
+
+
diff --git a/types.patch b/types.patch
new file mode 100644
index 0000000..4387472
--- /dev/null
+++ b/types.patch
@@ -0,0 +1,11 @@
+--- obexftp-0.23/swig/tcl/tcl_wrap.c.orig 2009-02-17 19:30:40.000000000 +0100
++++ obexftp-0.23/swig/tcl/tcl_wrap.c 2025-07-30 20:15:35.292978909 +0200
+@@ -2488,7 +2488,7 @@
+ _wrap_client_put_data(ClientData clientData SWIGUNUSED, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[]) {
+ obexftp_client_t *arg1 = (obexftp_client_t *) 0 ;
+ char *arg2 = (char *) 0 ;
+- size_t arg3 ;
++ int arg3 ;
+ char *arg4 = (char *) NULL ;
+ int result;
+ void *argp1 = 0 ;
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/obexftp.git/commitdiff/f2c9bc46f6e08e86b9898ba7fbb80f196e48fd0c
More information about the pld-cvs-commit
mailing list