diff --git a/.gitignore b/.gitignore index 4ecaf70..eeea1c7 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ BibTool-2.48.tar.gz +/BibTool-2.51.tar.gz diff --git a/BibTool-2.48-regex_DESTDIR.patch b/BibTool-2.48-regex_DESTDIR.patch deleted file mode 100644 index fbaf731..0000000 --- a/BibTool-2.48-regex_DESTDIR.patch +++ /dev/null @@ -1,109 +0,0 @@ -diff -up BibTool-2.48/rewrite.c.regex_DESTDIR BibTool-2.48/rewrite.c ---- BibTool-2.48/rewrite.c.regex_DESTDIR 2004-02-08 10:41:52.000000000 +0100 -+++ BibTool-2.48/rewrite.c 2008-02-14 21:40:13.000000000 +0100 -@@ -24,7 +24,8 @@ - #include - - #ifdef REGEX --#include -+#define __USE_GNU -+#include - #endif - - typedef struct rULE -diff -up BibTool-2.48/AutoConf/makefile.in.regex_DESTDIR BibTool-2.48/AutoConf/makefile.in ---- BibTool-2.48/AutoConf/makefile.in.regex_DESTDIR 2004-02-08 10:46:11.000000000 +0100 -+++ BibTool-2.48/AutoConf/makefile.in 2008-02-14 21:43:58.000000000 +0100 -@@ -208,9 +208,9 @@ NON_ANSI_DEFS = @DEFS@ - REGEX_DIR = regex-0.12 - # - --REGEX_DEF = -DREGEX -I$(REGEX_DIR) -I.. -+REGEX_DEF = -DREGEX - --REGEX = regex$(OBJ) -+REGEX = - - # ------------------------------------------------------- - # Kpathsea Library support. -@@ -460,8 +460,8 @@ $(OFILES): $(MAKEFILE) - # __________________________________________________________________ - # Targets from the GNU Regular Expression Library. - --regex$(OBJ): $(REGEX_DIR)$(DIR_SEP)regex.c $(MAKEFILE) -- $(CC) $(C_FLAGS) -I$(REGEX_DIR) -I.. $(NON_ANSI_DEFS) $(REGEX_DIR)$(DIR_SEP)regex.c $(DONT_LINK) -o $@ -+#regex$(OBJ): $(REGEX_DIR)$(DIR_SEP)regex.c $(MAKEFILE) -+# $(CC) $(C_FLAGS) -I$(REGEX_DIR) -I.. $(NON_ANSI_DEFS) $(REGEX_DIR)$(DIR_SEP)regex.c $(DONT_LINK) -o $@ - - - bibtcl: -@@ -490,7 +490,7 @@ test check: - (cd Test; $(MAKE)) - - libbib.a: $(OLIBFILES) -- $(AR) $@ $(OLIBFILES) regex.o -+ $(AR) $@ $(OLIBFILES) - $(RANLIB) $@ - - depend: -@@ -499,46 +499,46 @@ depend: - install: install.bin install.lib - - install.bin install-exec: bibtool$(EXT) -- -$(INSTALL_DIR) $(BINDIR) -- $(INSTALL) bibtool$(EXT) $(BINDIR) -+ -$(INSTALL_DIR) $(DESTDIR)$(BINDIR) -+ $(INSTALL) bibtool$(EXT) $(DESTDIR)$(BINDIR) - - INSTALL_LIB_FILES = Lib$(DIR_SEP)*.* - - install.lib install-data: -- -$(INSTALL_DIR) $(LIBDIR) -+ -$(INSTALL_DIR) $(DESTDIR)$(LIBDIR) - for lib in $(INSTALL_LIB_FILES); do \ -- $(INSTALL_DATA) $$lib $(LIBDIR); \ -+ $(INSTALL_DATA) $$lib $(DESTDIR)$(LIBDIR); \ - done - - INSTALL_INCLUDE_FILES = $(HFILES) - - install.include install-include: -- -$(INSTALL_DIR) $(INCLUDEDIR) -+ -$(INSTALL_DIR) $(DESTDIR)$(INCLUDEDIR) - for inc in $(INSTALL_INCLUDE_FILES); do \ -- $(INSTALL_DATA) $$inc $(INCLUDEDIR); \ -+ $(INSTALL_DATA) $$inc $(DESTDIR)$(INCLUDEDIR); \ - done - - install.man install-man: -- -$(INSTALL_DIR) $(MANDIR)$(DIR_SEP)man$(MANSECT) -- $(INSTALL) Doc$(DIR_SEP)bibtool.1 \ -- $(MANDIR)$(DIR_SEP)man$(MANSECT)$(DIR_SEP)bibtool.$(MANSECT) -+ -$(INSTALL_DIR) $(DESTDIR)$(MANDIR)$(DIR_SEP)man$(MANSECT) -+ $(INSTALL_DATA) Doc$(DIR_SEP)bibtool.1 \ -+ $(DESTDIR)$(MANDIR)$(DIR_SEP)man$(MANSECT)$(DIR_SEP)bibtool.$(MANSECT) - - uninstall: uninstall.bin uninstall.lib - - uninstall.bin uninstall-exec: -- -$(RM) $(BINDIR)$(DIR_SEP)bibtool$(EXT) -+ -$(RM) $(DESTDIR)$(BINDIR)$(DIR_SEP)bibtool$(EXT) - - uninstall.lib uninstall-data: -- -$(RM) $(LIBDIR) -+ -$(RM) $(DESTDIR)$(LIBDIR) - - uninstall.include uninstall-include: -- -$(RM) $(INCLUDEDIR) -+ -$(RM) $(DESTDIR)$(INCLUDEDIR) - - uninstall.man uninstall-man: -- -$(RM) $(MANDIR)$(DIR_SEP)man$(MANSECT)$(DIR_SEP)bibtool.$(MANSECT) -+ -$(RM) $(DESTDIR)$(MANDIR)$(DIR_SEP)man$(MANSECT)$(DIR_SEP)bibtool.$(MANSECT) - - status: -- @echo $(LIBDIR) -+ @echo $(DESTDIR)$(LIBDIR) - - # ============================================================================= - # DO NOT DELETE THIS LINE -- make depend depends on it. diff --git a/BibTool-2.51-cwdPATH.patch b/BibTool-2.51-cwdPATH.patch new file mode 100644 index 0000000..bc8ac76 --- /dev/null +++ b/BibTool-2.51-cwdPATH.patch @@ -0,0 +1,23 @@ +--- BibTool/Doc/Makefile.cwdPATH 2010-02-28 10:44:33.000000000 +0100 ++++ BibTool/Doc/Makefile 2011-05-18 09:26:29.000000000 +0200 +@@ -53,7 +53,7 @@ bibtool.pdf: bibtool.tex bibtool.bbl bib + bibtool.ind ind index: bibtool.idx + $(MAKEINDEX) -s bibtool.ist bibtool + +-config.tex: ..$(DIR_SEP)Makefile ..$(DIR_SEP)config.h ++config.tex: ..$(DIR_SEP)makefile ..$(DIR_SEP)config.h + cd ..; $(MAKE) Doc$(DIR_SEP)config.tex + + ##----------------------------------------------------------------------------- +@@ -139,9 +139,9 @@ c_lib.pdf: c_lib.tex c_main.tex c.tex co + $(PDFLATEX) c_lib.tex + + c_main.tex: $(CDIR)main.c c_get.pl +- c_get.pl $(CDIR)main.c > $@ ++ ./c_get.pl $(CDIR)main.c > $@ + c.tex: $(CFILES) c_get.pl +- c_get.pl $(CFILES) > $@ ++ ./c_get.pl $(CFILES) > $@ + + ##----------------------------------------------------------------------------- + diff --git a/BibTool-2.51-regex.patch b/BibTool-2.51-regex.patch new file mode 100644 index 0000000..e5cce0d --- /dev/null +++ b/BibTool-2.51-regex.patch @@ -0,0 +1,46 @@ +--- BibTool/rewrite.c.regex 2010-02-27 12:40:16.000000000 +0100 ++++ BibTool/rewrite.c 2011-05-18 08:40:54.000000000 +0200 +@@ -24,7 +24,8 @@ + #include + + #ifdef REGEX +-#include ++#define __USE_GNU ++#include + #endif + + typedef struct rULE +--- BibTool/AutoConf/makefile.in.regex 2010-04-02 17:47:35.000000000 +0200 ++++ BibTool/AutoConf/makefile.in 2011-05-18 08:40:54.000000000 +0200 +@@ -220,9 +220,9 @@ NON_ANSI_DEFS = @DEFS@ + REGEX_DIR = regex-0.12 + # + +-REGEX_DEF = -DREGEX -I$(REGEX_DIR) -I.. ++REGEX_DEF = -DREGEX + +-REGEX = regex$(OBJ) ++REGEX = + + # ------------------------------------------------------- + # Kpathsea Library support. +@@ -473,8 +473,8 @@ $(OFILES): $(MAKEFILE) + # __________________________________________________________________ + # Targets from the GNU Regular Expression Library. + +-regex$(OBJ): $(REGEX_DIR)$(DIR_SEP)regex.c $(MAKEFILE) +- $(CC) $(C_FLAGS) -I$(REGEX_DIR) -I.. $(NON_ANSI_DEFS) $(REGEX_DIR)$(DIR_SEP)regex.c $(DONT_LINK) -o $@ ++#regex$(OBJ): $(REGEX_DIR)$(DIR_SEP)regex.c $(MAKEFILE) ++# $(CC) $(C_FLAGS) -I$(REGEX_DIR) -I.. $(NON_ANSI_DEFS) $(REGEX_DIR)$(DIR_SEP)regex.c $(DONT_LINK) -o $@ + + + bibtcl: +@@ -503,7 +503,7 @@ test check: + (cd Test; $(MAKE)) + + libbib.a: $(OLIBFILES) +- $(AR) $@ $(OLIBFILES) regex.o ++ $(AR) $@ $(OLIBFILES) + $(RANLIB) $@ + + depend: diff --git a/BibTool.spec b/BibTool.spec index 27ba8ad..975cbb4 100644 --- a/BibTool.spec +++ b/BibTool.spec @@ -1,11 +1,12 @@ Summary: A Tool for manipulating BibTeX data bases Name: BibTool -Version: 2.48 -Release: 10%{?dist} +Version: 2.51 +Release: 1%{?dist} Group: Applications/Publishing Source: ftp://ftp.dante.de/tex-archive/biblio/bibtex/utils/bibtool/BibTool-%{version}.tar.gz -URL: http://www.gerd-neugebauer.de/software/TeX/BibTool.en.html -Patch0: BibTool-2.48-regex_DESTDIR.patch +URL: http://www.gerd-neugebauer.de/software/TeX/BibTool/ +Patch0: BibTool-2.51-regex.patch +Patch1: BibTool-2.51-cwdPATH.patch License: GPL+ BuildRequires: tetex-latex BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -18,8 +19,9 @@ fill this gap. BibTool allows the manipulation of BibTeX files which goes beyond the possibilities --- and intentions --- of BibTeX. %prep -%setup -q -%patch0 -p1 -b .regex_DESTDIR +%setup -q -n %{name} +%patch0 -p1 -b .regex +%patch1 -p1 -b .cwdPATH sed -i -e 's%^#!/usr/local/bin/tclsh%#! %{_bindir}/tclsh%' Tcl/bibtool.tcl sed -i -e 's%^#!/usr/local/bin/perl%#! %{_bindir}/perl%' Perl/bibtool.pl # configure will recreate the directory, but only with config.h within @@ -29,10 +31,17 @@ rm -rf regex-0.12 %configure --libdir=%{_datadir} make %{?_smp_mflags} CFLAGS="$RPM_OPT_FLAGS" make doc +# Convert to utf-8 +for file in INSTALL; do + iconv -f ISO-8859-1 -t UTF-8 -o $file.new $file && \ + touch -r $file $file.new && \ + mv $file.new $file +done %install rm -rf $RPM_BUILD_ROOT -make install install-man DESTDIR=$RPM_BUILD_ROOT INSTALL='install -p' +make install INSTALLPREFIX=$RPM_BUILD_ROOT INSTALL='install -p -m 755' +make install-man INSTALLPREFIX=$RPM_BUILD_ROOT INSTALL='install -p -m 644' %clean rm -rf $RPM_BUILD_ROOT @@ -40,13 +49,21 @@ rm -rf $RPM_BUILD_ROOT %files %defattr(-,root,root,-) %doc Changes.xml COPYING INSTALL README THANKS -%doc Doc/bibtool.dvi Doc/ref_card.dvi +%doc Doc/bibtool.pdf Doc/ref_card.pdf %doc Perl/ Tcl/ %{_bindir}/bibtool %{_datadir}/BibTool/ %{_mandir}/man1/bibtool.1* %changelog +* Wed May 18 2011 Michael J Gruber 2.51-1 +- rebase to BibTool 2.51 +- remove DESTDIR part of regex_DESTDIR patch (use INSTALLPREFIX from 2.51) +- fix Doc/Makefile +- follow switch from dvi doc to pdf doc +- remove exec bit for installed man +- convert latin1 file to UTF-8 + * Mon Feb 07 2011 Fedora Release Engineering - 2.48-10 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild diff --git a/sources b/sources index 4fc8923..5122a42 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -20ebb18ea55e5f64b67f5b8edaa0d6fa BibTool-2.48.tar.gz +0404647e6d1b2d4c2a34a6d1f4f9e375 BibTool-2.51.tar.gz