pkg://FreeWnn-1.1.1-0.a017.13mdk.src.rpm:2887178/FreeWnn.spec
info downloads
%define _unpackaged_files_terminate_build 0
%define version 1.1.1
%define release 0.a017.13mdk
%define src_ver 1.1.1-a017
%define prefix %{_prefix}
Summary: Japanese Input System
Summary(ja): 仮名漢字変換システム
Name: FreeWnn
Version: %{version}
Release: %{release}
Source0: ftp://ftp.freewnn.org/pub/FreeWnn/alpha/FreeWnn-%{src_ver}.tar.bz2
Source1: jserver.init
#
# (fg) Makefiles are really screwy, they suppose that user wnn exists already -
# this patch fixes this.
#
# Also, this removes calls to wnntouch, as they're done in %post
#
Patch0: FreeWnn-st00pid-Makefile.in-fixes.patch.bz2
Patch1: FreeWnn-1.1.1-a017-listen-to-localhost.patch.bz2
Patch2: FreeWnn-1.1.1-a017-64bit-fixes.patch.bz2
License: GPL
Group: System/Internationalization
URL: http://www.freewnn.org/
BuildRequires: ncurses-devel
BuildRoot: %_tmppath/%name-%version-%release-root
Requires: locales-ja
Obsoletes: Wnn
Provides: Wnn
%description
Wnn is a network-extensible Kana-to-Kanji conversion system.
With it you can type in kana (or romaji) and easily convert to kanji.
WARNING: for security purposes, server listens to localhost only by
default; set FREEWNN_LISTEN_ANY environment variable to have it listen to
any network address (e.g. `FREEWNN_LISTEN_ANY=1 service jserver start' for
example).
# (gc) japanese description needs to add the previous WARNING, sorry to
# disable it in the meantime..
#
# %description -l ja
# Wnn はネットワーク仮名漢字変換システムです。
# このパッケージは日本語変換システムのみ含みます。
%package devel
Summary: development library and header file for Wnn
Group: Development/C
Requires: FreeWnn = %version-%release
Obsoletes: Wnn-devel
Provides: Wnn-devel
%description devel
This package contains the header file and library for building programs
with use Wnn.
%description devel -l ja
このパッケージには Wnn を利用したプログラムをコンパイルするために必要
なヘッダファイルとライブラリを含んでいます。
%prep
%setup -q -n FreeWnn-%{src_ver}
%patch0 -p1
%patch1 -p0
%patch2 -p1 -b .64bit-fixes
%build
%serverbuild
cd Xsi
#
# (fg) 20000517: moved ./configure here, as I need to patch the st00pid
# Makefile.ins before...
./configure \
--prefix=%{_prefix} \
--libdir=%{_libdir} \
--localstatedir=/var --sysconfdir=%{_sysconfdir} \
--mandir=%{_mandir}/ja
make
%install
rm -rf $RPM_BUILD_ROOT
cd Xsi
make install DESTDIR=$RPM_BUILD_ROOT
( cd Wnn ; make install.man DESTDIR=$RPM_BUILD_ROOT )
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d
install -m 755 $RPM_SOURCE_DIR/jserver.init \
$RPM_BUILD_ROOT%{_sysconfdir}/rc.d/init.d/jserver
# var stuff must go to var; use a symlink
mkdir -p $RPM_BUILD_ROOT/var/lib/wnn/ja_JP/dic/usr
ln -s /var/lib/wnn/ja_JP/dic/usr $RPM_BUILD_ROOT%{_prefix}/lib/wnn/ja_JP/dic
#
# (fg) Completely redone this part: previous scripts were ugly
#
(
cd $RPM_BUILD_ROOT%{_mandir}/ja && \
{
find -type f |xargs perl -pi -e "s,/usr/local,%{_prefix},g"
for i in $(find -type l); do
dest = $(readlink $i)
rm $i
ln $dest $i
done
}
)
mkdir -p $RPM_BUILD_ROOT/usr/local/lib
( cd $RPM_BUILD_ROOT/usr/local/lib && ln -s %{_libdir}/wnn )
%clean
rm -fr $RPM_BUILD_ROOT
%post
%_post_service jserver
cd %{_libdir}/wnn && \
{
(
cd ja_JP/dic && \
%{_bindir}/Wnn4/wnntouch {pubdic,wnncons,gerodic}/*
);
#
# (fg) 20000518 This stuff should be uncommented when Korean and Chinese
# clients use Wnn... Thanks Pablo
#
# (
# cd zh_CN && \
# %{_bindir}/cWnn4/cwnntouch sys/*
# );
# (
# cd zh_TW && \
# %{_bindir}/cWnn4/cwnntouch sys/*
# );
# (
# cd ko_KR && \
# %{_bindir}/kWnn4/kwnntouch sys/*
# );
}
%preun
%_preun_service jserver
if [ $1 = 0 ]; then
# if FreeWnn is removed, remove its user data file too
rm -rf /var/lib/wnn/ja_JP/dic/usr/*
fi
%files
%defattr (-,root,root,755)
%doc Xsi/COPYRIGHT* Xsi/CONTRIBUTORS Xsi/PubdicPlus/PUBDICPLUS* Xsi/olddoc
%config %attr(755,root,root) %{_sysconfdir}/rc.d/init.d/jserver
%defattr (-,root,wnn,755)
# arch-independent dictionaries, better move to /usr/share/FreeWnn?
%{_prefix}/lib/wnn/
%dir %{_bindir}/Wnn4/
%{_bindir}/Wnn4/atod
%{_bindir}/Wnn4/atof
%{_bindir}/Wnn4/dtoa
%attr(4711,root,wnn) %{_bindir}/Wnn4/jserver
%{_bindir}/Wnn4/oldatonewa
%{_bindir}/Wnn4/wddel
%{_bindir}/Wnn4/wdreg
%{_bindir}/Wnn4/wnnkill
%{_bindir}/Wnn4/wnnstat
%{_bindir}/Wnn4/wnntouch
%attr(644,root,root) %{_mandir}/ja/man[145]/*
%dir /var/lib/wnn
%dir /var/lib/wnn/ja_JP
%dir /var/lib/wnn/ja_JP/dic/usr
# compatibility symlink; to remove sometime in the future
# kinput2 still looks there... (pablo)
%{_prefix}/local/lib/wnn
%files devel
%defattr(-,root,root,755)
%{_libdir}/libjd.a
%{_libdir}/libwnn.a
%{_includedir}/wnn/
%{_mandir}/ja/man3/*
%changelog
* Wed Oct 8 2003 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 1.1.1-0.a017.13mdk
- lib64 & 64-bit fixes
* Thu Sep 18 2003 Guillaume Cottenceau <gc@mandrakesoft.com> 1.1.1-0.a017.12mdk
- server listens to localhost only by default, set FREEWNN_LISTEN_ANY
environment variable to have it listen to any address (since there is
no config file support to change that)
* Tue Feb 17 2003 Pablo Saratxaga <pablo@mandrakesoft.com> 1.1.1-0.a017.11mdk
- rebuilt to link with new libraries
* Mon Jul 23 2001 Stefan van der Eijk <stefan@eijk.nu> 1.1.1-0.a017.10mdk
- BuildRequires: ncurses-devel
* Fri Apr 06 2001 David BAUDENS <baudens@mandrakesoft.com> 1.1.1-0.a017.9mdk
- devel: Requires: %%version-%%release and not only %%version
- Use %%_tmppath for BuildRoot (so, allow build as user)
* Wed Apr 4 2001 Frederic Lepied <flepied@mandrakesoft.com> 1.1.1-0.a017.8mdk
- use server macros
* Tue Mar 06 2001 Pablo Saratxaga <pablo@mandrakesoft.com> 1.1.1-0.a017.7mdk
- rebuild with new environment
- added %preun to clean data files
- converted Japanese description to UTF-8
* Fri Sep 22 2000 Stefan van der Eijk <s.vandereijk@chello.nl> 1.1.1-0.a017.6mdk
- BM
- some macro's
* Thu May 18 2000 Francis Galiegue <fg@mandrakesoft.com> 1.1.1-0.a017.5mdk
- Put back %config in front of /etc/rc.d/init.d/jserver
* Wed May 17 2000 Francis Galiegue <fg@mandrakesoft.com> 1.1.1-0.a017.4mdk
- Spec cleanup
- Makefile.in patches - were badly needed
- Now %defattr(-,root,wnn,755) and not %defattr(-,wnn,wnn,-)
- /etc/rc.d/init.d/jserver should not be %config
* Mon May 15 2000 Chmouel Boudjnah <chmouel@mandrakesoft.com> 1.1.1-0.a017.3mdk
- Fix build.
- Remove some stupid %pre.
* Fri Apr 15 2000 Pablo Saratxaga <pablo@mandrakesoft.com> 1.1.1-0.a017.2mdk
- changed %%pre section to add a 'jserver' entry to /etc/services
- improved /etc/rc.d/init.d/jserver script (it now uses wnnstatus for
status, and displays [OK] or [FAILED] properly)
* Wed Mar 29 2000 Pablo Saratxaga <pablo@mandrakesoft.com> 1.1.1-0.a017.1mdk
- first Mandrake version
- spec file losely adapted from previous 'Wnn' package