Репозитории ALT
S: | 0.6.31-alt3 |
5.1: | 0.6.27-alt1 |
4.1: | 0.6.22-alt1 |
4.0: | 0.6.18-alt1 |
3.0: | 0.6.5-alt1 |
Другие репозитории
Upstream: | 0.6.23 |
Группа :: Коммуникации
Пакет: gnokii
Главная Изменения Спек Патчи Sources Загрузить Gear Bugs and FR Repocop
Патч: gnokii-0.6.22-alt1.patch
Скачать
Скачать
.gear-rules | 3 +
.../b4e9a73045ae2502614560950925e06b11513f4c | 4 +
.../cf463c8f081cd6dfca43bb393b477dae09b54f7e | 6 +
.gear-tags/list | 1 +
autogen.sh | 1 -
common/gnokii.pc.in | 4 +-
common/links/fbus-phonet.c | 23 ++-
common/misc.c | 2 +-
gnokii.spec | 243 ++++++++++++++++++++
gnokii/gnokii-settings.c | 18 +-
include/links/fbus-phonet.h | 2 +-
xgnokii/xgnokii.pc.in | 2 +-
12 files changed, 287 insertions(+), 22 deletions(-)
diff --git a/.gear-rules b/.gear-rules
new file mode 100644
index 0000000..985447b
--- /dev/null
+++ b/.gear-rules
@@ -0,0 +1,3 @@
+spec: gnokii.spec
+tar: @name@-@version@:.
+diff: @name@-@version@:. .
diff --git a/.gear-tags/b4e9a73045ae2502614560950925e06b11513f4c b/.gear-tags/b4e9a73045ae2502614560950925e06b11513f4c
new file mode 100644
index 0000000..7caaa98
--- /dev/null
+++ b/.gear-tags/b4e9a73045ae2502614560950925e06b11513f4c
@@ -0,0 +1,4 @@
+object 90f659efd26ba20d8e6e04d410cca1a7d8e2589d
+type commit
+tag rel_0_6_22
+tagger pkot <pkot>
diff --git a/.gear-tags/cf463c8f081cd6dfca43bb393b477dae09b54f7e b/.gear-tags/cf463c8f081cd6dfca43bb393b477dae09b54f7e
new file mode 100644
index 0000000..35fce2e
--- /dev/null
+++ b/.gear-tags/cf463c8f081cd6dfca43bb393b477dae09b54f7e
@@ -0,0 +1,6 @@
+object b4e9a73045ae2502614560950925e06b11513f4c
+type tag
+tag gnokii-0.6.22
+tagger Sir Raorn <raorn@altlinux.ru> 1195992778 +0300
+
+gnokii 0.6.22
diff --git a/.gear-tags/list b/.gear-tags/list
new file mode 100644
index 0000000..e76a6c4
--- /dev/null
+++ b/.gear-tags/list
@@ -0,0 +1 @@
+cf463c8f081cd6dfca43bb393b477dae09b54f7e gnokii-0.6.22
diff --git a/autogen.sh b/autogen.sh
index 95db380..68dd8de 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -9,4 +9,3 @@ fi
aclocal ${AC_LOCAL_FLAGS}
autoheader
autoconf
-./configure "$@"
diff --git a/common/gnokii.pc.in b/common/gnokii.pc.in
index 7293945..56ada27 100644
--- a/common/gnokii.pc.in
+++ b/common/gnokii.pc.in
@@ -6,5 +6,5 @@ includedir=@includedir@
Name: gnokii
Description: Gnokii library interface
Version: @VERSION@
-Libs: -L${libdir} -lgnokii @LIBS@ @XPM_LIBS@ @LIBICONV@
-Cflags: -I${includedir} @XPM_CFLAGS@
+Libs: -L${libdir} -lgnokii
+Cflags: -I${includedir}
diff --git a/common/links/fbus-phonet.c b/common/links/fbus-phonet.c
index f2126c7..3036ed4 100644
--- a/common/links/fbus-phonet.c
+++ b/common/links/fbus-phonet.c
@@ -168,18 +168,22 @@ static void phonet_rx_statemachine(unsigned char rx_byte, struct gn_statemachine
i->message_length = i->message_length + rx_byte;
i->state = FBUS_RX_GetMessage;
i->buffer_count = 0;
- break;
- case FBUS_RX_GetMessage:
- i->message_buffer[i->buffer_count] = rx_byte;
- i->buffer_count++;
+ if (i->message_buffer)
+ free(i->message_buffer);
- if (i->buffer_count > PHONET_FRAME_MAX_LENGTH) {
- dprintf("PHONET: Message buffer overun - resetting\n");
+ if ((i->message_buffer = malloc(i->message_length)) == NULL) {
+ dprintf("PHONET: Not enough memory for message buffer\n");
i->state = FBUS_RX_Sync;
break;
}
+ break;
+
+ case FBUS_RX_GetMessage:
+ i->message_buffer[i->buffer_count] = rx_byte;
+ i->buffer_count++;
+
/* Is that it? */
if (i->buffer_count == i->message_length) {
sm_incoming_function(i->message_type, i->message_buffer, i->message_length, state);
@@ -224,14 +228,15 @@ static gn_error phonet_loop(struct timeval *timeout, struct gn_statemachine *sta
static gn_error phonet_send_message(unsigned int messagesize, unsigned char messagetype, unsigned char *message, struct gn_statemachine *state)
{
- u8 out_buffer[PHONET_TRANSMIT_MAX_LENGTH + 5];
+ u8 *out_buffer;
int current = 0;
int total, sent;
if (!state)
return GN_ERR_FAILED;
- /* FIXME - we should check for the message length ... */
+ if ((out_buffer = malloc(messagesize + 6)) == NULL)
+ return GN_ERR_MEMORYFULL;
/* Now construct the message header. */
@@ -278,6 +283,8 @@ static gn_error phonet_send_message(unsigned int messagesize, unsigned char mess
else current += sent;
} while (current < total);
+ free(out_buffer);
+
sm_incoming_acknowledge(state);
return GN_ERR_NONE;
diff --git a/common/misc.c b/common/misc.c
index 862631a..fc5f462 100644
--- a/common/misc.c
+++ b/common/misc.c
@@ -429,7 +429,7 @@ GNOKII_API void gn_elog_write(const char *fmt, ...)
#if defined (__svr4__)
# define lock_path "/var/run/LCK.."
#else
-# define lock_path "/var/lock/LCK.."
+# define lock_path "/var/lock/serial/LCK.."
#endif
/* Lock the device. Return allocated string with a lock name */
diff --git a/gnokii.spec b/gnokii.spec
new file mode 100644
index 0000000..7d59735
--- /dev/null
+++ b/gnokii.spec
@@ -0,0 +1,243 @@
+# vim: set ft=spec: -*- rpm-spec -*-
+
+%define xname x%name
+%define artworkver 1.1
+%define _customdocdir %_defaultdocdir/%name-%version
+
+Name: gnokii
+Version: 0.6.22
+Release: alt1
+
+Summary: Unix tool suite for Nokia mobile phones
+Group: Communications
+License: GPL
+Url: http://www.gnokii.org/
+
+Packager: Sir Raorn <raorn@altlinux.ru>
+
+Source: %name-%version.tar
+Patch: %name-%version-%release.patch
+
+Requires: lib%name = %version-%release
+
+# Automatically added by buildreq on Tue Jul 31 2007
+BuildRequires: cvs flex libbluez-devel libgtk+2-devel libusb-devel libXpm-devel
+
+%description
+Gnokii is a Unix tool suite for Nokia mobile phones.
+
+You should be in 'uucp' group to use it with serial cables.
+
+%package -n %xname
+Summary: Unix tool suite for Nokia mobile phones
+Group: Communications
+Requires: %name = %version-%release
+Requires: gnokii-artwork
+
+%description -n %xname
+xgnokii is a graphical tool for Nokia mobile phones
+
+%package -n lib%name
+Summary: Library for gnokii
+Group: System/Libraries
+
+%description -n lib%name
+You will need lib%name to run %name.
+
+%package -n lib%name-devel
+Summary: Development files for gnokii
+Group: Development/C
+Requires: lib%name = %version-%release
+
+%description -n lib%name-devel
+Install %name-devel if you want to develop or compile applications using
+gnokii API.
+
+%prep
+%setup
+%patch -p1
+
+%build
+# SMP-incompatible
+%define __nprocs 1
+%add_optflags %optflags_shared
+export lt_cv_prog_cc_static_works=no
+
+./autogen.sh
+%configure \
+ --disable-static \
+ --disable-rpath \
+ --with-x \
+ --enable-nls \
+ --enable-security \
+ --enable-libusb \
+ --enable-irda \
+ --enable-bluetooth \
+ --with-xgnokiidir=%_prefix
+%make_build
+
+%install
+%make_install DESTDIR=%buildroot \
+ docdir=%_defaultdocdir/%name-%version \
+ xmandir=%_man1dir \
+ install install-docs install-devel
+
+%__mkdir_p %buildroot%_sysconfdir
+%__sed 's,/usr/local/sbin,%_sbindir,g' \
+ < Docs/sample/gnokiirc \
+ > %buildroot%_sysconfdir/gnokiirc
+
+%find_lang %name
+
+%post -n lib%name -p %post_ldconfig
+%postun -n lib%name -p %postun_ldconfig
+
+%post -n %xname
+%update_menus
+
+%postun -n %xname
+%clean_menus
+
+%files -f %name.lang
+%dir %doc %_defaultdocdir/%name-%version
+%doc %_defaultdocdir/%name-%version/*
+%config(noreplace) %_sysconfdir/gnokiirc
+%_bindir/%name
+%_bindir/sendsms
+%_sbindir/%{name}d
+%_sbindir/mgnokiidev
+%_man1dir/%name.1*
+%_man1dir/sendsms.1*
+%_man8dir/%{name}d.8*
+%_man8dir/mgnokiidev.8*
+
+%files -n %xname
+%_bindir/%xname
+%dir %_datadir/%xname
+%_datadir/%xname/*
+%_desktopdir/%xname.desktop
+%_man1dir/%xname.1*
+
+%files -n lib%name
+%_libdir/lib%name.so.*
+
+%files -n lib%name-devel
+%dir %_includedir/%name
+%_includedir/gnokii.h
+%_includedir/%name/*
+%_libdir/lib%name.so
+%_pkgconfigdir/gnokii.pc
+
+%changelog
+* Sun Nov 25 2007 Sir Raorn <raorn@altlinux.ru> 0.6.22-alt1
+- [0.6.22]
+
+* Sun Oct 28 2007 Sir Raorn <raorn@altlinux.ru> 0.6.20-alt1
+- [0.6.20]
+
+* Mon Oct 08 2007 Sir Raorn <raorn@altlinux.ru> 0.6.19-alt1
+- [0.6.19]
+
+* Tue Jul 31 2007 Sir Raorn <raorn@altlinux.ru> 0.6.18-alt1
+- [0.6.18]
+ + todologo, ppm2nokia and waitcall removed by upstream
+- gnokii-artwork packaged separately
+- Cleaned up pkgconfig file
+- Fixed ldif export (closes: #9994)
+
+* Mon Sep 11 2006 Sir Raorn <raorn@altlinux.ru> 0.6.14-alt2
+- Fixed --setdatetime argument parsing
+
+* Tue Aug 29 2006 Sir Raorn <raorn@altlinux.ru> 0.6.14-alt1
+- [0.6.14]
+ + new utility - waitcall
+
+* Thu Jul 13 2006 Sir Raorn <raorn@altlinux.ru> 0.6.13-alt1
+- [0.6.13]
+ + new libusb driver for DKU-2 cable (connection = dku2libusb)
+ + SONAME changed for libgnokii
+- Updated build requires
+- Use %%update_menus in xgnokii
+
+* Fri May 19 2006 Sir Raorn <raorn@altlinux.ru> 0.6.12-alt1
+- [0.6.12]
+
+* Tue Feb 28 2006 Sir Raorn <raorn@altlinux.ru> 0.6.11-alt1
+- [0.6.11]
+- spec **cleanup**
+- Really enable bluetooth support
+- Fix some 6310i problems (closes: #9161)
+
+* Sun Dec 11 2005 Michael Shigorin <mike@altlinux.org> 0.6.10-alt1
+- 0.6.10
+- spec *cleanup*
+
+* Mon May 02 2005 Denis Smirnov <mithraen@altlinux.ru> 0.6.5-alt1
+- 0.6.5 (major feature enhancements)
+- bluetooth support
+
+* Fri Apr 16 2004 Michael Shigorin <mike@altlinux.ru> 0.6.1-alt1
+- 0.6.1 (major feature enhancements)
+- removed patch0
+
+* Fri Jan 02 2004 Michael Shigorin <mike@altlinux.ru> 0.5.8-alt1
+- 0.5.8 (minor bugfixes)
+- fixed manpage installation
+- seperated xgnokii
+
+* Tue Nov 11 2003 Michael Shigorin <mike@altlinux.ru> 0.5.5-alt2
+- %optflags_shared
+
+* Wed Oct 08 2003 Michael Shigorin <mike@altlinux.ru> 0.5.5-alt1
+- 0.5.5 (minor feature enhancements)
+
+* Tue Sep 23 2003 Michael Shigorin <mike@altlinux.ru> 0.5.4-alt1
+- 0.5.4 (major bugfixes)
+- enabled security options (e.g. PIN change)
+- spec cleanup
+
+* Tue Jul 08 2003 Michael Shigorin <mike@altlinux.ru> 0.5.2-alt1
+- built for ALT Linux
+- adapted from ASPLinux contribs (incl. patch and .desktop)
+- package libification
+- lockdir patch
+- spec cleanup
+
+* Mon Jun 16 2003 Leonid Kanter <leon@asplinux.ru>
+- 0.5.2
+
+* Wed Jun 11 2003 Leonid Kanter <leon@asplinux.ru>
+- 0.5.1
+- add gnokii-devel package
+- build with bluetooth support
+
+* Wed Mar 05 2003 Leonid Kanter <leon@asplinux.ru>
+- rewrote spec (fix permissions)
+- create desktop file
+
+* Fri Feb 07 2003 Hugo Monteiro <hmmm@fct.unl.pt>
+- rebuilt for version 0.5.0pre5
+- spec file cleanup
+
+* Fri Sep 06 2002 Hugo Monteiro <hmmm@fct.unl.pt>
+- rebuilt for version 0.4.3
+
+* Wed Aug 02 2000 Than Ngo <than@redhat.de>
+- update to 0.3.2
+- fix non-standard-gid (Bug #15041)
+
+* Mon Jul 24 2000 Prospector <prospector@redhat.com>
+- rebuilt
+
+* Wed Jul 12 2000 Than Ngo <than@redhat.de>
+- rebuilt
+
+* Mon Jul 03 2000 Prospector <bugzilla@redhat.com>
+- automatic rebuild
+
+* Sat May 27 2000 Ngo Than <than@redhat.de>
+- rebuild for 7.0
+
+* Wed Jan 05 2000 Ngo Than <than@redhat.de>
+- initial RPM for powertools 6.2
+
diff --git a/gnokii/gnokii-settings.c b/gnokii/gnokii-settings.c
index 80a1410..81ba345 100644
--- a/gnokii/gnokii-settings.c
+++ b/gnokii/gnokii-settings.c
@@ -55,7 +55,7 @@ void settings_usage(FILE *f)
{
fprintf(f, _("Phone settings:\n"
" --reset [soft|hard]\n"
- " --setdatetime [YYYY [MM [DD [HH [MM]]]]]\n"
+ " --setdatetime [YYYY [MM [DD [HH [MM] [SS]]]]]\n"
" --getdatetime\n"
" --setalarm [HH MM]\n"
" --getalarm\n"
@@ -81,17 +81,19 @@ int setdatetime(int argc, char *argv[], gn_data *data, struct gn_statemachine *s
date.minute = now->tm_min;
date.second = now->tm_sec;
- switch (argc - optind - 1) {
- case 4:
+ switch (argc - optind) {
+ case 6:
+ date.second = atoi(argv[optind+5]);
+ case 5:
date.minute = atoi(argv[optind+4]);
- case 3:
+ case 4:
date.hour = atoi(argv[optind+3]);
- case 2:
+ case 3:
date.day = atoi(argv[optind+2]);
- case 1:
+ case 2:
date.month = atoi(argv[optind+1]);
- case 0:
- date.year = atoi(argv[optind]);
+ case 1:
+ date.year = atoi(argv[optind+0]);
break;
default:
break;
diff --git a/include/links/fbus-phonet.h b/include/links/fbus-phonet.h
index daaad05..0ced94a 100644
--- a/include/links/fbus-phonet.h
+++ b/include/links/fbus-phonet.h
@@ -63,7 +63,7 @@ typedef struct {
int message_destination;
int message_type;
int message_length;
- char message_buffer[PHONET_FRAME_MAX_LENGTH];
+ char *message_buffer;
} phonet_incoming_message;
#endif /* #ifndef _gnokii_links_fbus_phonet_h */
diff --git a/xgnokii/xgnokii.pc.in b/xgnokii/xgnokii.pc.in
index 40221ae..08b2509 100644
--- a/xgnokii/xgnokii.pc.in
+++ b/xgnokii/xgnokii.pc.in
@@ -7,5 +7,5 @@ xgnokiidir=@XGNOKIIDIR@/share/@XPACKAGE@
Name: xgnokii
Description: GTK2 gnokii library interface
Version: @XVERSION@
-Libs: -L${libdir} -lgnokii @LIBS@ @XPM_LIBS@ @LIBICONV@
+Libs: -L${libdir} -lgnokii
Cflags: -I${includedir} @XPM_CFLAGS@