rpms/coccinelle/F-10 coccinelle-0.1.4-python26.patch, NONE, 1.1 coccinelle.spec, NONE, 1.1 import.log, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
Richard W.M. Jones
rjones at fedoraproject.org
Wed Mar 18 09:33:42 UTC 2009
- Previous message (by thread): rpms/coccinelle/devel coccinelle-0.1.4-python26.patch, NONE, 1.1 coccinelle.spec, NONE, 1.1 import.log, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Next message (by thread): rpms/coccinelle/F-10 coccinelle.spec,1.1,1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: rjones
Update of /cvs/pkgs/rpms/coccinelle/F-10
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv30346/F-10
Modified Files:
.cvsignore sources
Added Files:
coccinelle-0.1.4-python26.patch coccinelle.spec import.log
Log Message:
Initial import.
coccinelle-0.1.4-python26.patch:
--- NEW FILE coccinelle-0.1.4-python26.patch ---
diff -ur /tmp/coccinelle-0.1.4/pycaml/pycaml.ml pycaml/pycaml.ml
--- /tmp/coccinelle-0.1.4/pycaml/pycaml.ml 2008-11-13 16:03:42.000000000 +0000
+++ pycaml/pycaml.ml 2009-01-26 15:40:17.000000000 +0000
@@ -381,8 +381,10 @@
(* 28 *)
let pyimport_addmodule = fmt28call (pnf ())
let pyimport_importmodule = fmt28call (pnf ())
+(* - disabled, see comment in pycaml_ml.c. - RWMJ
(* 51 *)
let pyimport_importmoduleex = fmt51call (pnf ())
+*)
(* 28 *)
let pyimport_import = fmt28call (pnf ())
(* 14 *)
diff -ur /tmp/coccinelle-0.1.4/pycaml/pycaml_ml.c pycaml/pycaml_ml.c
--- /tmp/coccinelle-0.1.4/pycaml/pycaml_ml.c 2008-03-29 20:25:26.000000000 +0000
+++ pycaml/pycaml_ml.c 2009-01-26 15:40:02.000000000 +0000
@@ -173,7 +173,7 @@
int fd;
int x;
int ret_int;
- char *rvs;
+ const char *rvs;
int fmt = Int_val(Field(format,1));
PyObject *ob1,*ob2,*ob3;
void *func = getcustom(Field(format,0));
@@ -1184,7 +1184,12 @@
{ (void *)PyImport_AddModule, 28, "PyImport_AddModule" },
{ (void *)PyImport_ImportModule, 28, "PyImport_ImportModule" },
/* 51 */
+#if 0
+ /* In Python 2.6, this because a #define so we cannot take
+ * the address of the function. - RWMJ.
+ */
{ (void *)PyImport_ImportModuleEx, 51, "PyImport_ImportModuleEx" },
+#endif
/* 28 */
{ (void *)PyImport_Import, 28, "PyImport_Import" },
/* 14 */
--- NEW FILE coccinelle.spec ---
%define opt %(test -x %{_bindir}/ocamlopt && echo 1 || echo 0)
%define debug_package %{nil}
%if !%opt
# Prevent RPM from stripping bytecode /usr/bin/spatch.
%define __strip /bin/true
%endif
Name: coccinelle
Version: 0.1.5
Release: 3%{?dist}
Summary: Semantic patching for Linux (spatch)
Group: Development/Libraries
License: GPLv2
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
URL: http://www.emn.fr/x-info/coccinelle/
Source0: http://www.emn.fr/x-info/coccinelle/distrib/%{name}-%{version}.tgz
# Patch for Python 2.6, sent upstream on 2009-03-17.
Patch0: coccinelle-0.1.4-python26.patch
BuildRequires: ocaml >= 3.10.0
BuildRequires: ocaml-findlib-devel
BuildRequires: ocaml-ocamldoc
BuildRequires: python-devel
%{!?python_sitelib: %define python_sitelib %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")}
BuildRequires: chrpath
%description
Coccinelle is a tool to utilize semantic patches for manipulating C
code. It was originally designed to ease maintenance of device
drivers in the Linux kernel.
%package doc
Summary: Documentation for %{name}
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
%description doc
The %{name}-doc package contains documentation for %{name}.
%package examples
Summary: Examples for %{name}
Group: Development/Libraries
Requires: %{name} = %{version}-%{release}
%description examples
The %{name}-examples package contains examples for %{name}.
%prep
%setup -q
%patch0 -p0
# Remove .cvsignore files.
find -name .cvsignore -delete
# Convert a few files to UTF-8 encoding.
for f in demos/demo_rule9/sym53c8xx.res demos/demo_rule9/sym53c8xx.c; do
mv $f $f.orig
iconv -f iso-8859-1 -t utf-8 < $f.orig > $f
rm $f.orig
done
%build
./configure --prefix=%{_prefix}
%{__sed} -i \
-e 's,LIBDIR=.*,LIBDIR=%{_libdir},' \
-e 's,MANDIR=.*,MANDIR=%{_mandir},' \
-e 's,SHAREDIR=.*,SHAREDIR=%{_datadir}/%{name},' \
Makefile.config
# Note that _smp_mflags breaks the build.
%if !%opt
make all
%else
make all opt
%endif
%install
rm -rf $RPM_BUILD_ROOT
make DESTDIR=$RPM_BUILD_ROOT install
%if %opt
# Install the native code version.
rm $RPM_BUILD_ROOT%{_bindir}/spatch
install -m 0755 spatch.opt $RPM_BUILD_ROOT%{_bindir}/spatch
strip $RPM_BUILD_ROOT%{_bindir}/spatch
%else
# Else prevent prelink from buggering about with the bytecode binary.
mkdir -p $RPM_BUILD_ROOT/etc/prelink.conf.d
echo '-b %{_bindir}/spatch' \
> $RPM_BUILD_ROOT/etc/prelink.conf.d/%{name}.conf
%endif
strip $RPM_BUILD_ROOT%{_libdir}/*.so
chrpath --delete $RPM_BUILD_ROOT%{_libdir}/*.so
# Remove bogus Makefiles from Python directory.
find $RPM_BUILD_ROOT%{_datadir}/%{name} -name Makefile -delete
# Move Python libraries to python lib directory.
mkdir -p $RPM_BUILD_ROOT%{python_sitelib}
mv $RPM_BUILD_ROOT%{_datadir}/%{name}/python/coccilib \
$RPM_BUILD_ROOT%{python_sitelib}
rmdir $RPM_BUILD_ROOT%{_datadir}/%{name}/python
%check
LD_LIBRARY_PATH=. \
./spatch.opt -cocci_file demos/simple.cocci demos/simple.c
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root,-)
%doc authors.txt bugs.txt changes.txt copyright.txt
%doc credits.txt install.txt license.txt readme.txt
%{_bindir}/spatch
%{_datadir}/%{name}/
%{python_sitelib}/coccilib/
%{_mandir}/man1/*.1.gz
%{_libdir}/*.so
%if !%opt
%config(noreplace) /etc/prelink.conf.d/%{name}.conf
%endif
%files doc
%defattr(-,root,root,-)
%doc docs
%files examples
%defattr(-,root,root,-)
%doc demos
%changelog
* Tue Mar 17 2009 Richard W.M. Jones <rjones at redhat.com> - 0.1.5-3
- Make the documentation subpackage "-doc" not "-docs".
- Comment about patch0 and send upstream.
* Mon Mar 16 2009 Richard W.M. Jones <rjones at redhat.com> - 0.1.5-2
- BR python-devel.
* Mon Mar 16 2009 Richard W.M. Jones <rjones at redhat.com> - 0.1.5-1
- New upstream version 0.1.5.
- Use the correct method to get Python sitelib (Michal Schmidt).
* Wed Jan 28 2009 Richard W.M. Jones <rjones at redhat.com> - 0.1.4-8
- Remove useless Makefiles from python/coccilib.
- License is GPLv2 (not GPLv2+).
- Include documentation and demos in subpackages.
- Move python library to a more sensible path.
- Add a check section.
* Mon Jan 26 2009 Richard W.M. Jones <rjones at redhat.com> - 0.1.4-6
- Install the shared library in _libdir.
- Install the native code version if we have the optimizing compiler.
* Wed Jan 21 2009 Richard W.M. Jones <rjones at redhat.com> - 0.1.4-3
- Patch for Python 2.6.
* Wed Jan 21 2009 Richard W.M. Jones <rjones at redhat.com> - 0.1.4-2
- Initial RPM release.
--- NEW FILE import.log ---
coccinelle-0_1_5-3_fc11:F-10:coccinelle-0.1.5-3.fc11.src.rpm:1237368817
Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/coccinelle/F-10/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore 18 Mar 2009 03:30:15 -0000 1.1
+++ .cvsignore 18 Mar 2009 09:33:11 -0000 1.2
@@ -0,0 +1 @@
+coccinelle-0.1.5.tgz
Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/coccinelle/F-10/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources 18 Mar 2009 03:30:15 -0000 1.1
+++ sources 18 Mar 2009 09:33:11 -0000 1.2
@@ -0,0 +1 @@
+c6a8cdb9bb2bd22cb48cca456be63837 coccinelle-0.1.5.tgz
- Previous message (by thread): rpms/coccinelle/devel coccinelle-0.1.4-python26.patch, NONE, 1.1 coccinelle.spec, NONE, 1.1 import.log, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2
- Next message (by thread): rpms/coccinelle/F-10 coccinelle.spec,1.1,1.2
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list