summaryrefslogtreecommitdiff
path: root/comms/gammu-devel/files
diff options
context:
space:
mode:
authorPav Lucistnik <pav@FreeBSD.org>2003-12-13 20:39:49 +0000
committerPav Lucistnik <pav@FreeBSD.org>2003-12-13 20:39:49 +0000
commitcd5ded6a17d24a8f1c66eb3b5e61f43111c5a01d (patch)
tree03a4e27c904b0431fbe7788bbf342bf7e6ed06a0 /comms/gammu-devel/files
parentfix build on 4 and 5 (diff)
Add gammu, a command-line program to communicate with Nokia cell phones
over cable, infra and Bluetooth. PR: ports/60211 Submitted by: Kirill Bezzubets <kirill@solaris.ru>
Notes
Notes: svn path=/head/; revision=95744
Diffstat (limited to 'comms/gammu-devel/files')
-rw-r--r--comms/gammu-devel/files/patch-cfg-Makefile.glo14
-rw-r--r--comms/gammu-devel/files/patch-cfg-autoconf-configure.in28
-rw-r--r--comms/gammu-devel/files/patch-cfg-config.h46
-rw-r--r--comms/gammu-devel/files/patch-common-device-bluetoth-bluetoth.c66
-rw-r--r--comms/gammu-devel/files/patch-common-phone-at-sonyeric.c28
5 files changed, 182 insertions, 0 deletions
diff --git a/comms/gammu-devel/files/patch-cfg-Makefile.glo b/comms/gammu-devel/files/patch-cfg-Makefile.glo
new file mode 100644
index 000000000000..1160f5a799ee
--- /dev/null
+++ b/comms/gammu-devel/files/patch-cfg-Makefile.glo
@@ -0,0 +1,14 @@
+diff -ur /usr/Arch/Nokia/Gammu/gammu-0.90.0/cfg/Makefile.glo ./cfg/Makefile.glo
+--- /usr/Arch/Nokia/Gammu/gammu-0.90.0/cfg/Makefile.glo Tue Nov 25 18:58:33 2003
++++ ./cfg/Makefile.glo Tue Dec 9 17:30:45 2003
+@@ -45,9 +45,9 @@
+ $(TOPDIR)/common/protocol/obex/obex.o \
+ $(TOPDIR)/common/protocol/symbian/mrouter.o \
+ $(TOPDIR)/common/phone/pfunc.o \
++ $(TOPDIR)/common/phone/at/sonyeric.o \
+ $(TOPDIR)/common/phone/at/atgen.o \
+ $(TOPDIR)/common/phone/at/siemens.o \
+- $(TOPDIR)/common/phone/at/sonyeric.o \
+ $(TOPDIR)/common/phone/alcatel/alcatel.o \
+ $(TOPDIR)/common/phone/nokia/dct3/n6110.o \
+ $(TOPDIR)/common/phone/nokia/dct3/n7110.o \
diff --git a/comms/gammu-devel/files/patch-cfg-autoconf-configure.in b/comms/gammu-devel/files/patch-cfg-autoconf-configure.in
new file mode 100644
index 000000000000..c14bf93096a0
--- /dev/null
+++ b/comms/gammu-devel/files/patch-cfg-autoconf-configure.in
@@ -0,0 +1,28 @@
+diff -ur /usr/Arch/Nokia/Gammu/gammu-0.90.0/cfg/autoconf/configure.in ./cfg/autoconf/configure.in
+--- /usr/Arch/Nokia/Gammu/gammu-0.90.0/cfg/autoconf/configure.in Tue Nov 25 19:22:06 2003
++++ ./cfg/autoconf/configure.in Tue Dec 9 16:53:34 2003
+@@ -85,11 +85,8 @@
+ pthread="no"])
+ LDLIBS="$LDLIBS $PTHREAD_LIBS $PTHREAD_CFLAGS"
+ CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
+-AC_CACHE_CHECK([for the Bluez Bluetooth stack], ac_cv_have_sockaddr_rc,
+- [AC_TRY_COMPILE([#include <sys/socket.h>
+- #include <bluetooth/bluetooth.h>
+- #include <bluetooth/rfcomm.h>],
+- [struct sockaddr_rc rc;],
++AC_CACHE_CHECK([for FreeBSD Bluetooth stack], ac_cv_have_sockaddr_rc,
++[AC_CHECK_LIB(bluetooth, main,
+ ac_cv_have_sockaddr_rc=yes,
+ ac_cv_have_sockaddr_rc=no)])
+
+@@ -431,8 +428,8 @@
+ Nokia PHONET FBUS - $gsm_enable_irdaphonet
+ OBEX - $gsm_enable_irdaobex
+
+- Phone protocols with Bluez Bluetooth stack
+- ------------------------------------------
++ Phone protocols with FreeBSD Bluetooth stack
++ --------------------------------------------
+ AT commands - $gsm_enable_blueat
+ Nokia FBUS2 - $gsm_enable_bluefbus2
+ Nokia PHONET FBUS - $gsm_enable_bluephonet
diff --git a/comms/gammu-devel/files/patch-cfg-config.h b/comms/gammu-devel/files/patch-cfg-config.h
new file mode 100644
index 000000000000..55e1d4ef08af
--- /dev/null
+++ b/comms/gammu-devel/files/patch-cfg-config.h
@@ -0,0 +1,46 @@
+diff -ur /usr/Arch/Nokia/Gammu/gammu-0.90.0/cfg/config.h ./cfg/config.h
+--- /usr/Arch/Nokia/Gammu/gammu-0.90.0/cfg/config.h Tue Nov 25 19:24:12 2003
++++ ./cfg/config.h Tue Dec 9 16:59:39 2003
+@@ -1,4 +1,4 @@
+-/* config.h. Generated automatically by configure. */
++/* config.h. Generated by configure. */
+
+ #ifndef _config_h_
+ #define _config_h_
+@@ -45,20 +45,20 @@
+ #define GSM_ENABLE_ALCABUS 1
+
+ /* Infrared. PHONET FBUS */
+-#define GSM_ENABLE_IRDAPHONET 1
++/* #undef GSM_ENABLE_IRDAPHONET */
+ /* Infrared. AT commands */
+-#define GSM_ENABLE_IRDAAT 1
++/* #undef GSM_ENABLE_IRDAAT */
+ /* Infrared. OBEX */
+-#define GSM_ENABLE_IRDAOBEX 1
++/* #undef GSM_ENABLE_IRDAOBEX */
+
+ /* Bluetooth stack (like Bluez). FBUS2 (init done using AT commands) */
+-/* #undef GSM_ENABLE_BLUEFBUS2 */
++#define GSM_ENABLE_BLUEFBUS2 1
+ /* Bluetooth stack (like Bluez). PHONET FBUS */
+-/* #undef GSM_ENABLE_BLUEPHONET */
++#define GSM_ENABLE_BLUEPHONET 1
+ /* Blueooth stack (like Bluez). AT commands */
+-/* #undef GSM_ENABLE_BLUEAT */
++#define GSM_ENABLE_BLUEAT 1
+ /* Blueooth stack (like Bluez). OBEX */
+-/* #undef GSM_ENABLE_BLUEOBEX */
++#define GSM_ENABLE_BLUEOBEX 1
+
+ /* --------------------------- Phone modules (specific) ----------------- */
+
+@@ -93,7 +93,7 @@
+ #define GSM_ENABLE_ALCATEL 1
+
+ /* OBEX generic models */
+-#define GSM_ENABLE_OBEXGEN 1
++/* #undef GSM_ENABLE_OBEXGEN */
+
+ /* Symbian with m-router generic models */
+ #define GSM_ENABLE_MROUTERGEN 1
diff --git a/comms/gammu-devel/files/patch-common-device-bluetoth-bluetoth.c b/comms/gammu-devel/files/patch-common-device-bluetoth-bluetoth.c
new file mode 100644
index 000000000000..729cc7c15a41
--- /dev/null
+++ b/comms/gammu-devel/files/patch-common-device-bluetoth-bluetoth.c
@@ -0,0 +1,66 @@
+diff -ur /usr/Arch/Nokia/Gammu/gammu-0.90.0/common/device/bluetoth/bluetoth.c ./common/device/bluetoth/bluetoth.c
+--- /usr/Arch/Nokia/Gammu/gammu-0.90.0/common/device/bluetoth/bluetoth.c Sun Nov 2 11:43:28 2003
++++ ./common/device/bluetoth/bluetoth.c Tue Dec 9 17:19:59 2003
+@@ -11,11 +11,10 @@
+ #include <string.h>
+
+ #ifndef WIN32
+-# include <sys/socket.h>
+-# include <sys/time.h>
+-# include <unistd.h>
+-# include <bluetooth/bluetooth.h>
+-# include <bluetooth/rfcomm.h>
++#include <sys/socket.h>
++#include <sys/time.h>
++#include <unistd.h>
++#include <bluetooth.h>
+ #else
+ # include <windows.h>
+ # include <io.h>
+@@ -25,6 +24,11 @@
+ #include "../devfunc.h"
+ #include "bluetoth.h"
+
++#define BTPROTO_RFCOMM BLUETOOTH_PROTO_RFCOMM
++#define BDADDR_ANY NG_HCI_BDADDR_ANY
++
++#undef WIN32
++
+ #ifdef WIN32
+ static GSM_Error bluetooth_connect(GSM_StateMachine *s, int port)
+ {
+@@ -80,7 +84,7 @@
+ static GSM_Error bluetooth_connect(GSM_StateMachine *s, int port)
+ {
+ GSM_Device_BlueToothData *d = &s->Device.Data.BlueTooth;
+- struct sockaddr_rc laddr, raddr;
++ struct sockaddr_rfcomm laddr, raddr;
+ bdaddr_t bdaddr;
+ int fd;
+
+@@ -89,9 +93,9 @@
+ return GE_DEVICENODRIVER;
+ }
+
+- bacpy(&laddr.rc_bdaddr, BDADDR_ANY);
+- laddr.rc_family = AF_BLUETOOTH;
+- laddr.rc_channel = 0;
++ bacpy(&laddr.rfcomm_bdaddr, BDADDR_ANY);
++ laddr.rfcomm_family = AF_BLUETOOTH;
++ laddr.rfcomm_channel = 0;
+
+ if (bind(fd, (struct sockaddr *)&laddr, sizeof(laddr)) < 0) {
+ dbgprintf("Can't bind socket\n");
+@@ -100,9 +104,9 @@
+ }
+
+ str2ba(s->CurrentConfig->Device, &bdaddr);
+- bacpy(&raddr.rc_bdaddr, &bdaddr);
+- raddr.rc_family = AF_BLUETOOTH;
+- raddr.rc_channel = port;
++ bacpy(&raddr.rfcomm_bdaddr, &bdaddr);
++ raddr.rfcomm_family = AF_BLUETOOTH;
++ raddr.rfcomm_channel = port;
+
+ if (connect(fd, (struct sockaddr *)&raddr, sizeof(raddr)) < 0) {
+ dbgprintf("Can't connect\n");
diff --git a/comms/gammu-devel/files/patch-common-phone-at-sonyeric.c b/comms/gammu-devel/files/patch-common-phone-at-sonyeric.c
new file mode 100644
index 000000000000..2dcbc3b6083d
--- /dev/null
+++ b/comms/gammu-devel/files/patch-common-phone-at-sonyeric.c
@@ -0,0 +1,28 @@
+diff -ur /usr/Arch/Nokia/Gammu/gammu-0.90.0/common/phone/at/sonyeric.c ./common/phone/at/sonyeric.c
+--- /usr/Arch/Nokia/Gammu/gammu-0.90.0/common/phone/at/sonyeric.c Sun Nov 2 11:45:40 2003
++++ ./common/phone/at/sonyeric.c Tue Dec 9 17:36:22 2003
+@@ -1,7 +1,6 @@
+
+ #include "../../gsmstate.h"
+
+-#ifdef GSM_ENABLE_ATGEN
+
+ #include <string.h>
+ #include <time.h>
+@@ -13,7 +12,6 @@
+ extern GSM_Reply_Function ATGENReplyFunctions[];
+ extern GSM_Error ATGEN_DispatchMessage (GSM_StateMachine *s);
+
+-#ifdef GSM_ENABLE_OBEXGEN
+
+ extern GSM_Reply_Function OBEXGENReplyFunctions[];
+ extern GSM_Error OBEXGEN_GetFilePart (GSM_StateMachine *s, GSM_File *File);
+@@ -403,8 +401,6 @@
+ #endif
+ }
+
+-#endif
+-#endif
+
+ /* How should editor hadle tabs in this file? Add editor commands here.
+ * vim: noexpandtab sw=8 ts=8 sts=8: