#!/bin/sh ## script for auto-making EB, eblook, Lookup RPM ## checked in RedHatLinux7.3 ## Time-stamp: ## get SourceCodes and Patches from net ## cd ~ && mkdir -p rpmdir/{RPMS,SRPMS,BUILD,SOURCES,SPECS} cd rpmdir/SOURCES if [ ! -s eb-3.3.4.tar.gz ] ; then wget ftp://ftp.sra.co.jp/pub/misc/eb/eb-3.3.4.tar.gz fi if [ ! -s eblook-1.5.1.tar.gz ] ; then wget http://openlab.jp/edict/eblook/dist/eblook-1.5.1.tar.gz fi if [ ! -s lookup-1.4devel-021115.tar.gz ] ; then wget http://openlab.jp/edict/lookup/lookup-1.4devel-021115.tar.gz fi ## prepare to make rpm ## cd ~ echo %_topdir $HOME/rpmdir > .rpmmacros cat >rpmdir/SPECS/eb.spec << END_OF_LINE Summary: EB Library - C Library for accessing CD-ROM books Name: eb Version: 3.3.4 Release: 2 License: GPL Group: Development/Libraries URL: http://www.sra.co.jp/people/m-kasahr/eb/ Source0: ftp://ftp.sra.co.jp/pub/misc/eb/%{name}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-buildroot %description EB Library is a C library for accessing CD-ROM books. It can be built on UNIX derived systems. EB Library supports to access CD-ROM books of EB, EBG, EBXA, EBXA-C, S-EBXA and EPWING formats. CD-ROM books of those formats are popular in Japan. Since CD-ROM books themseves are stands on the ISO 9660 format, you can mount the discs by the same way as other ISO 9660 discs. EB Library also provides some utility commands. %prep %setup -q %build ./configure --prefix=/usr --infodir=/usr/share/info make make check %install rm -rf %{buildroot} make install DESTDIR=%{buildroot} %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) /usr/lib/libeb.so.6.1.4 /usr/lib/libeb.la /usr/lib/libeb.a /usr/include/eb /usr/bin/ebappendix /usr/bin/ebfont /usr/bin/ebinfo /usr/bin/ebrefile /usr/bin/ebzip /usr/bin/ebunzip /usr/bin/ebzipinfo # /usr/share/locale/ja/LC_MESSAGES /usr/share/aclocal/eb3.m4 /usr/share/eb/appendix %doc /usr/share/info/ebfont.info* %doc /usr/share/info/ebinfo.info* %doc /usr/share/info/ebrefile.info* %doc /usr/share/info/ebzip.info* %doc /usr/share/info/eb-ja.info* %doc /usr/share/info/ebfont-ja.info* %doc /usr/share/info/ebinfo-ja.info* %doc /usr/share/info/ebrefile-ja.info* %doc /usr/share/info/ebzip-ja.info* %config /usr/etc/eb.conf %doc AUTHORS COPYING NEWS README README-ja %changelog * Sat Aug 2 2003 Itou Hiroki - change info-directory * Thu Jul 24 2003 Itou Hiroki - Initial build. END_OF_LINE cat >rpmdir/SPECS/eblook.spec << END_OF_LINE Summary: interactive searching tool for electric dictionary with EB Library Name: eblook Version: 1.5.1 Release: 2 License: GPL Group: Applications/Text URL: http://openlab.jp/edict/eblook/ Source0: %{name}-%{version}.tar.gz BuildRoot: %{_tmppath}/%{name}-buildroot BuildRequires: eb >= 3.0 %description ebbook is an interactive searching tool for electronic dictionary with EB Library. You can search EPWING-compatible dictionary with easy setting. %prep %setup -q %build ./configure \ --with-eb-conf=/usr/etc/eb.conf \ --prefix=/usr \ --infodir=/usr/share/info make %install rm -rf %{buildroot} make install DESTDIR=%{buildroot} %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) /usr/bin/eblook %doc /usr/share/info/eblook.info.gz %doc AUTHORS COPYING NEWS README %changelog * Sat Aug 2 2003 Itou Hiroki - change info-directory * Thu Jul 24 2003 Itou Hiroki - Initial build. END_OF_LINE cat >rpmdir/SPECS/lookup.spec << END_OF_LINE Summary: Lookup - a dictionary search interface with Emacs editor Name: lookup Version: 1.4devel Release: 021115_2 License: GPL Group: Applications/Text URL: http://openlab.jp/edict/lookup/ Source0: %{name}-%{version}-021115.tar.gz BuildRoot: %{_tmppath}/%{name}-buildroot Requires: eblook, emacs %description Lookup is a dictionary search interface with Emacs editor. %prep %setup -q -n lookup-1 %build ./autogen.sh \ --prefix=/usr \ --with-emacs=emacs \ --with-lispdir=/usr/share/emacs/site-lisp/lookup \ --infodir=/usr/share/info make %install rm -rf %{buildroot} make install DESTDIR=%{buildroot} %clean rm -rf %{buildroot} %files %defattr(-,root,root,-) /usr/share/emacs/site-lisp/lookup %doc /usr/share/info/lookup.info* %doc /usr/share/info/lookup-guide.info* %changelog * Sat Aug 2 2003 Itou Hiroki - change info-directory * Thu Jul 24 2003 Itou Hiroki - Initial build. END_OF_LINE ## make rpm ## rpmbuild -ba rpmdir/SPECS/eb.spec # sudo rpm -Uvh rpmdir/RPMS/i386/eb-3.3.4-2.i386.rpm # rpmbuild -bb rpmdir/SPECS/eblook.spec # rpmbuild -bb rpmdir/SPECS/lookup.spec # sudo rpm -Uvh rpmdir/RPMS/i386/eblook-1.5.1-2.i386.rpm # sudo rpm -Uvh rpmdir/RPMS/i386/lookup-1.4devel-021115_2.i386.rpm echo echo you should do... echo echo 1. install RPM \'EB\' echo 2. build RPM \'eblook\', \'Lookup\' echo 3. install RPM \'eblook\', \'Lookup\' echo 4. modify $HOME/.emacs echo