added patch against flex 2.5.37 [release 0.7-2mamba;Mon Feb 04 2013]

This commit is contained in:
Silvan Calarco 2024-01-06 05:01:44 +01:00
parent 7eac4f60c7
commit aedb09ca08
4 changed files with 124 additions and 0 deletions

View File

@ -1,2 +1,7 @@
# libmcal # libmcal
mcal stands for Modular Calendar Access Library.
libmcal is a C library for accessing calendars, written to be very modular, with pluggable drivers.
One of the main drivers it handles is ICAP, an internet protocol that has very close ties with the IMAP protocol.
Using ICAP, you can access a calendar in very much the same way as you use IMAP to access a remote mailbox.

View File

@ -0,0 +1,14 @@
--- libmcal.orig/icalroutines.h 2003-01-28 18:45:21.000000000 +0100
+++ libmcal/icalroutines.h 2013-02-04 01:54:27.833995640 +0100
@@ -48,8 +48,10 @@
/* ICAL parser. */
+#ifndef ical_yytext
extern char *ical_yytext;
-extern int ical_yyleng;
+extern size_t ical_yyleng;
+#endif
int ical_yylex(void);
void ical_usebuf(const char *buf, size_t size);
void ical_preprocess(char *buf, size_t *size);

29
libmcal-0.7-flexfix.patch Normal file
View File

@ -0,0 +1,29 @@
--- libmcal/icalscanner.lex 2003-01-28 09:45:21.000000000 -0800
+++ libmcal/icalscanner.lex.new 2006-04-01 22:47:58.515410944 -0800
@@ -32,13 +32,6 @@
*/
#include "icalroutines.h"
-
-void
-ical_usebuf(const char *buf, size_t size)
-{
- BEGIN(INITIAL);
- yy_scan_bytes(buf, size);
-}
%}
@@ -68,3 +61,12 @@
{LF} BEGIN(INITIAL); return ICALTOK_LF;
. return ICALTOK_JUNK;
<<EOF>> return ICALTOK_EOF;
+
+%%
+
+void
+ical_usebuf(const char *buf, size_t size)
+{
+ BEGIN(INITIAL);
+ yy_scan_bytes(buf, size);
+}

76
libmcal.spec Normal file
View File

@ -0,0 +1,76 @@
Name: libmcal
Version: 0.7
Release: 2mamba
Summary: A C library for accessing calendars
Group: System/Libraries
Vendor: openmamba
Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: http://mcal.check.com
Source: http://downloads.sourceforge.net/sourceforge/libmcal/libmcal-%{version}.tar.gz
Patch0: libmcal-%{version}-flexfix.patch
Patch1: libmcal-0.7-flex-2.5.37.patch
## AUTOBUILDREQ-BEGIN
BuildRequires: glibc-devel
## AUTOBUILDREQ-END
License: GPL
BuildRoot: %{_tmppath}/%{name}-%{version}-root
%description
mcal stands for Modular Calendar Access Library.
libmcal is a C library for accessing calendars, written to be very modular, with pluggable drivers.
One of the main drivers it handles is ICAP, an internet protocol that has very close ties with the IMAP protocol.
Using ICAP, you can access a calendar in very much the same way as you use IMAP to access a remote mailbox.
%package devel
Summary: A C library for accessing calendars
Group: Development/Libraries
%description devel
mcal stands for Modular Calendar Access Library.
libmcal is a C library for accessing calendars, written to be very modular, with pluggable drivers.
One of the main drivers it handles is ICAP, an internet protocol that has very close ties with the IMAP protocol.
Using ICAP, you can access a calendar in very much the same way as you use IMAP to access a remote mailbox.
This package contains the mcal headers and static library.
%prep
%setup -q -n libmcal
%patch0 -p1
%patch1 -p1
%build
%configure
%ifarch x86_64
export OTHER_CFLAGS="-fPIC"
%endif
%make
%install
sed -i "s|/usr/local/mcal|%{buildroot}%{_libdir}/mcal|" Makefile
sed -i "s|/lib/|/%{_lib}/|" Makefile
mkdir -p %{buildroot}%{_libdir}/mcal/
mkdir -p %{buildroot}%{_libdir}/mcal/include/
#mkdir -p %{buildroot}/usr/lib/mcal/{lib,include}
#usr/{lib,include}
%makeinstall
cp {cal_misc.h,icalroutines.h} %{buildroot}%{_libdir}/mcal/include
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%files devel
%defattr(-,root,root)
%{_libdir}/mcal/include/*.h
%{_libdir}/mcal/*.a
%{_libdir}/mcal/*.so
%changelog
* Mon Feb 04 2013 Silvan Calarco <silvan.calarco@mambasoft.it> 0.7-2mamba
- added patch against flex 2.5.37
* Tue Jul 03 2007 Tiziana Ferro <tiziana.ferro@email.it> 0.7-1mamba
- update to 0.7
* Wed Sep 10 2003 Silvan Calarco <silvan.calarco@mambasoft.it> 0.6-1qilnx
- first build