2003-02-20 20:45:22 +00:00
|
|
|
%define frontend @RPM_FRONTEND@
|
|
|
|
%define frontdep @RPM_FRONTEND_DEPS@
|
|
|
|
|
2001-08-08 08:26:09 +00:00
|
|
|
Summary: A WYSIWYM (What You See Is What You Mean) frontend to LaTeX
|
1999-10-13 21:39:32 +00:00
|
|
|
Name: @PACKAGE@
|
|
|
|
Version: @VERSION@
|
2003-02-20 20:45:22 +00:00
|
|
|
Release: 1_%{frontend}
|
1999-10-02 14:01:04 +00:00
|
|
|
Copyright: see COPYING file
|
2003-02-20 20:45:22 +00:00
|
|
|
Group: Applications/Publishing
|
|
|
|
URL: http://www.lyx.org/
|
1999-10-02 14:01:04 +00:00
|
|
|
Packager: Kayvan A. Sylvan <kayvan@sylvan.com>
|
2003-02-20 20:45:22 +00:00
|
|
|
Source: ftp://ftp.lyx.org/pub/lyx/stable/%{name}-%{version}.tar.gz
|
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-root
|
|
|
|
Icon: %{name}.xpm
|
|
|
|
Prefix: %{_prefix}
|
|
|
|
Requires: %{frontdep}, tetex-xdvi, tetex, tetex-latex
|
2001-08-05 22:15:41 +00:00
|
|
|
Obsoletes: tetex-lyx
|
1999-10-02 14:01:04 +00:00
|
|
|
|
1999-09-27 18:44:28 +00:00
|
|
|
%description
|
2001-08-08 08:26:09 +00:00
|
|
|
LyX is a modern approach to writing documents which breaks with the
|
|
|
|
obsolete "typewriter paradigm" of most other document preparation
|
|
|
|
systems.
|
|
|
|
|
|
|
|
It is designed for people who want professional quality output
|
|
|
|
with a minimum of time and effort, without becoming specialists in
|
|
|
|
typesetting.
|
|
|
|
|
|
|
|
The major innovation in LyX is WYSIWYM (What You See Is What You Mean).
|
|
|
|
That is, the author focuses on content, not on the details of formatting.
|
|
|
|
This allows for greater productivity, and leaves the final typesetting
|
|
|
|
to the backends (like LaTeX) that are specifically designed for the task.
|
|
|
|
|
|
|
|
With LyX, the author can concentrate on the contents of his writing,
|
|
|
|
and let the computer take care of the rest.
|
1999-09-27 18:44:28 +00:00
|
|
|
|
2003-02-20 20:45:22 +00:00
|
|
|
This is LyX built with the %{frontend} frontend.
|
|
|
|
|
1999-10-02 14:01:04 +00:00
|
|
|
%prep
|
1999-09-27 18:44:28 +00:00
|
|
|
%setup
|
|
|
|
|
|
|
|
%build
|
2000-03-15 01:15:13 +00:00
|
|
|
unset LINGUAS || true
|
2003-02-20 20:45:22 +00:00
|
|
|
./configure --with-frontend=%{frontend} --prefix=%{_prefix} \
|
|
|
|
--mandir=%{_mandir} --bindir=%{_bindir} --datadir=%{_datadir} \
|
|
|
|
--without-warnings --disable-debug --enable-optimization=-O2
|
2001-09-21 12:11:24 +00:00
|
|
|
make
|
1999-09-27 18:44:28 +00:00
|
|
|
|
|
|
|
%install
|
2000-03-15 01:15:13 +00:00
|
|
|
unset LINGUAS || true
|
1999-10-02 14:01:04 +00:00
|
|
|
rm -rf ${RPM_BUILD_ROOT}
|
|
|
|
install -d -m 755 ${RPM_BUILD_ROOT}
|
2001-09-20 09:27:22 +00:00
|
|
|
make DESTDIR=${RPM_BUILD_ROOT} install
|
|
|
|
gzip -f9 ${RPM_BUILD_ROOT}%{_mandir}/man?/*
|
1999-09-27 18:44:28 +00:00
|
|
|
|
1999-10-02 14:01:04 +00:00
|
|
|
#
|
2001-09-20 09:27:22 +00:00
|
|
|
# Set up the lyx-specific class files where TeX can see them
|
1999-10-02 14:01:04 +00:00
|
|
|
#
|
2001-09-20 09:27:22 +00:00
|
|
|
TEXMF=%{_datadir}/texmf
|
1999-10-02 14:01:04 +00:00
|
|
|
mkdir -p ${RPM_BUILD_ROOT}${TEXMF}/tex/latex
|
2003-02-20 20:45:22 +00:00
|
|
|
mv ${RPM_BUILD_ROOT}%{_datadir}/%{name}/tex \
|
|
|
|
${RPM_BUILD_ROOT}/${TEXMF}/tex/latex/%{name}
|
1999-09-27 18:44:28 +00:00
|
|
|
|
1999-10-02 14:01:04 +00:00
|
|
|
#
|
|
|
|
# Miscellaneous files
|
|
|
|
#
|
2003-02-20 20:45:22 +00:00
|
|
|
cp -a lib/images/%{name}.xpm ${RPM_BUILD_ROOT}%{_datadir}/%{name}/images/
|
1999-10-02 14:01:04 +00:00
|
|
|
cp lib/reLyX/README README.reLyX
|
|
|
|
|
|
|
|
%clean
|
|
|
|
rm -rf ${RPM_BUILD_ROOT}
|
1999-09-27 18:44:28 +00:00
|
|
|
|
|
|
|
%post
|
2001-08-05 22:15:41 +00:00
|
|
|
# Make TeX understand where LyX-specific packages are
|
|
|
|
texhash
|
|
|
|
|
1999-09-27 18:44:28 +00:00
|
|
|
# Before configuring lyx for the local system
|
|
|
|
# PATH needs to be imported
|
1999-10-02 14:01:04 +00:00
|
|
|
if [ -f /etc/profile ]; then
|
1999-09-27 18:44:28 +00:00
|
|
|
. /etc/profile
|
1999-10-02 14:01:04 +00:00
|
|
|
fi
|
|
|
|
#
|
1999-09-27 18:44:28 +00:00
|
|
|
# Now configure LyX
|
1999-10-02 14:01:04 +00:00
|
|
|
#
|
1999-09-27 18:44:28 +00:00
|
|
|
echo "Configuring LyX for your system..."
|
2003-02-20 20:45:22 +00:00
|
|
|
cd %{_datadir}/%{name}
|
1999-09-27 18:44:28 +00:00
|
|
|
./configure --srcdir
|
|
|
|
|
2001-04-05 12:35:38 +00:00
|
|
|
# Fix reLyX perl program if the prefix is non-standard
|
2001-09-20 09:27:22 +00:00
|
|
|
if [ "%{_prefix}" != "/usr" ]
|
2001-04-05 12:35:38 +00:00
|
|
|
then
|
2003-02-20 20:45:22 +00:00
|
|
|
perl -pi -e "s!/usr/share/%{name}!%{_datadir}/%{name}!" %{_bindir}/reLyX
|
2001-04-05 12:35:38 +00:00
|
|
|
fi
|
|
|
|
|
2001-08-05 22:15:41 +00:00
|
|
|
%postun
|
1999-10-02 14:01:04 +00:00
|
|
|
# Fix the TeX file hash
|
|
|
|
#
|
|
|
|
texhash
|
1999-09-27 18:44:28 +00:00
|
|
|
|
|
|
|
%files
|
2001-11-04 07:29:40 +00:00
|
|
|
%defattr(-,root,root)
|
2001-09-20 09:27:22 +00:00
|
|
|
%doc ABOUT-NLS ANNOUNCE COPYING
|
|
|
|
%doc README UPGRADING ChangeLog NEWS
|
|
|
|
%doc lib/CREDITS README.reLyX
|
|
|
|
%{_bindir}/*
|
|
|
|
%{_mandir}/man?/*
|
|
|
|
%{_datadir}/locale/*/LC_MESSAGES/*
|
|
|
|
%{_datadir}/%{name}
|
|
|
|
%{_datadir}/texmf/tex/latex/%{name}
|