vim 5.3 PLD i man

Marcin Wołyniak marcin w marcin.heban.com.pl
Nie, 27 Gru 1998, 12:15:21 CET


Ziemek Borowski wrote:
> >spec file  i przebudujesz sobie pakiet.
> a może podesłałbyś i na pld-list w mailbox.tuniv.szczecin.pl
> 
> --
> Ziemek Borowski ZB137-RIPE http://faq-bot.ziembor.waw.pl/zmb/
 OK. przesylam na podany adres, ale jest to wersja robocza napisana
dla mojej konfiguracji systemu. Aby byla``uniwersalna'', to
trzeba wrocic z libncurses, na libtermcap (dla prostych termow)
oraz dodac wrappera na wersje lesstif-vim aby wywolywala sie
z GUI. Ma zmieniona nazwe na xmgvim, ale program sprawdza
tylko czy jest wywolywany jako vim, vi czy gvim. U mnie jest alias
systemowy. Mozna wrappera, albo grzebac w kodzie.

Pozdrowka

Marcin Wolyniak
-- 
+-------------------------------------------------------------+
|               WHERE MICROSOFT WILL DRAG YOU TODAY?          |
|                        Eric S. Raymond!                     |
+-------------------------------------------------------------+
-------------- następna część ---------
Summary:     Vim 5.3 static
Summary(pl): Vim 5.3a skompilowany statycznie
Name:        vim
Version:     5.3
Release:     3
Source:      ftp://ftp.nl.vim.org/pub/vim/unix/%{name}-%{version}-src.tar.gz
Source1:     ftp://ftp.nl.vim.org/pub/vim/unix/%{name}-%{version}-rt.tar.gz
Source2:     gvim.wmconfig
Copyright:   GPL
Group:       Applications/Editors
URL:         http://www.vim.org/
Buildroot:   /var/tmp/%{name}-%{version}-%{release}-root
Requires:    pgcc , perl >= 5.004 , tk >=8.0 , tcl >= 8.0 , python >=1.4 , python-devel >= 1.4

%description
The classic Unix text editor. This version is build with minimal
feature and is installed in /bin as a rescue tool. The installation of
this package is STRONGLY recommended.

%description -l pl
Pakiet zawiera vim - klasyczny (unixowy) edytor tekstowy skompilowany 
statycznie. Instalacja tego pakietu jest MOCNO zalecana, może on pomóc
Tobie uratować system w czasie awarii.

%package rt 
Summary:     Vim 5.3 runtime files
Summary(pl): Pliki przydatne edytorowi vim 
Group:       Applications/Editors

%description rt
This package contains macros, documentation, syntax configuration and
manual pages for vim. If you want to take advantage of vim more powerful
features, you should install this package.

%description rt -l pl
W tym pakiecie znajdziesz dokumentację, makra, pliki konfiguracyjne i strony
podręcznika edytora vim. Jeżeli zamierzasz korzystać z vim-a, powinieneś
zainstalować ten pakiet.

#%package slang
#Summary: Vim 5.3 built with slang
#Summary(pl): Vim 5.3 korzystający z bibliotek Slang
#Group: Applications/Editors
#Obsoletes: vim-ncurses

#%description slang
#The classic Unix text editor build with slang library. It adds
#multiple windows, multi-level undo, block highliting, and many other
#features to the standard vi program.

#%description slang -l pl
#Wersja edytora vim skompilowana z biblioteką slang. W porownaniu z
#edytorem vi, ta wersja oferuje dodatkowo pracę z wieloma plikami,
#wielopoziomowe operacje cofnij, bloki, podświetlanie składni i wiele
#innych usprawnień.

%package ncurses 
Summary:     Vim 5.3 built with ncurses
Summary(pl): Vim 5.3 korzystający z bibliotek ncurses
Group:       Applications/Editors
Obsoletes:   vim-slang

%description ncurses
The classic Unix text editor build with ncurses library. It adds
multiple windows, multi-level undo, block highliting, and many other
features to the standard vi program.
This is fully featured version but with no perl, tcl, and python interfaces.

%description ncurses -l pl
Wersja edytora vim skompilowana z biblioteką ncurses. W porownaniu z
edytorem vi, ta wersja oferuje dodatkowo pracę z wieloma plikami,
wielopoziomowe operacje cofnij, bloki, podświetlanie składni i wiele
innych usprawnień.
Wersja ze wszystkimi rozszerzeniami ale bez interfejsów do perla, tcl i pythona.

%package athena
Summary: Vim 5.3 built with X11 and athena support
Summary(pl): Vim 5.3 pod X-Window korzystający z Athena Widget Set
Group: Applications/Editors
Obsoletes: vim-lesstif

%description athena 
The classic Unix text editor now also under X Window System! 
This version is build with Athena Widget Set. 
This is fully featured version with perl, tcl, and python interfaces.

%description athena -l pl
Wersja edytora vim pracująca w graficznym środowisku X Window
z wykorzystaniem Athena Widget Set.
Wersja ze wszystkimi rozszerzeniami oraz interfejsami do perla, tcl i pythona.

%package lesstif
Summary: Vim 5.3 built with X11 and LessTif support
Summary(pl): Vim 5.3 pod X-Window korzystający z bibliotek LessTif
Group: Applications/Editors
Obsoletes: vim-athena

%description lesstif
The classic Unix text editor now also under X Window System! 
This version is build with LessTiff.
This is fully featured version with perl, tcl, and python interfaces.

%description lesstif -l pl
Wersja edytora vim pracująca w graficznym środowisku X Window
z wykorzystaniem LessTif.
Wersja ze wszystkimi rozszerzeniami oraz interfejsami do perla, tcl i pythona.

%prep
%setup -q  -b 1

%build
cd src
mv feature.h feature.h.original
sed 's/\/\* #define SYS_VIMRC_FILE	\"\/etc\/vimrc\" \*\//#define SYS_VIMRC_FILE	\"\/etc\/virc\"/' < feature.h.original > feature.h
cd ..
CC=gcc LDFLAGS=-static CFLAGS=-O ./configure --disable-gui --without-x \
--disable-perlinterp --disable-pythoninterp --disable-tclinterp \
--disable-cscope --enable-min-features --with-tlib=termcap --prefix=/usr
make
mv src/vim src/vim.termcap
mv src/xxd/xxd src/xxd.termcap
strip --strip-debug src/vim.termcap
strip --strip-debug src/xxd.termcap

#make distclean
#LDFLAGS=-s CFLAGS="$RPM_OPT_FLAGS" ./configure --disable-gui --without-x \
#--disable-perlinterp --disable-pythoninterp --disable-tclinterp \
#--disable-cscope --with-tlib=slang --prefix=/usr
#make
#mv src/vim src/vim.slang

make distclean
cd src
rm -f feature.h
mv feature.h.original feature.h
cd ..
CC=pgcc LDFLAGS=-s CFLAGS="-mpentium -O3 -Wmissing-prototypes" \
./configure --disable-gui --without-x --enable-max-features \
--disable-perlinterp --disable-pythoninterp --disable-tclinterp \
--disable-cscope --with-tlib=ncurses --prefix=/usr
make
mv src/vim src/vim.ncurses

make distclean
CC=pgcc LDFLAGS=-s CFLAGS="-mpentium -O3 -Wmissing-prototypes" \
./configure --enable-gui=athena --with-x --enable-max-features \
--enable-perlinterp --enable-pythoninterp --enable-tclinterp \
--disable-cscope --with-tlib=ncurses --prefix=/usr
make
mv src/vim src/vim.athena

make distclean
CC=pgcc LDFLAGS=-s CFLAGS="-mpentium -O3 -Wmissing-prototypes" \
./configure --enable-gui=motif --with-x --enable-max-features \
--enable-perlinterp --enable-pythoninterp --enable-tclinterp \
--disable-cscope --with-tlib=ncurses --prefix=/usr
make
mv src/vim src/vim.lesstif
cd doc
make
cd ..


%install
rm -rf $RPM_BUILD_ROOT

install -d $RPM_BUILD_ROOT/etc/X11/wmconfig
install -d $RPM_BUILD_ROOT/bin
install -d $RPM_BUILD_ROOT/usr/{bin,X11R6/bin,share/vim,man/man1}

make prefix=$RPM_BUILD_ROOT/usr install

install -s src/vim.termcap $RPM_BUILD_ROOT/bin/vi
install -s src/xxd.termcap $RPM_BUILD_ROOT/bin/xxd
#install -s src/vim.slang $RPM_BUILD_ROOT/usr/bin/vim.slang
install -s src/vim.ncurses $RPM_BUILD_ROOT/usr/bin/vim.ncurses
install -s src/vim.athena $RPM_BUILD_ROOT/usr/X11R6/bin/gvim.athena
install -s src/vim.lesstif $RPM_BUILD_ROOT/usr/X11R6/bin/gvim.lesstif

#install doc/vim.1 $RPM_BUILD_ROOT/usr/man/man1
# These echoed manpages are absolutely unnecesary! Installation routine
# instals them as symlinks to the vim main manpage.
# More, they erse the contents of vim manpage with stupid ``so vim.1''.

#install -m644 doc/xxd.1 $RPM_BUILD_ROOT/usr/man/man1
#echo "so vim.1" >$RPM_BUILD_ROOT/usr/man/man1/ex.1
#echo "so vim.1" >$RPM_BUILD_ROOT/usr/man/man1/view.1
#echo "so vim.1" >$RPM_BUILD_ROOT/usr/man/man1/gvim.1
#echo "so vim.1" >$RPM_BUILD_ROOT/usr/man/man1/gview.1
#echo "so vim.1" >$RPM_BUILD_ROOT/usr/man/man1/rvim.1
#echo "so vim.1" >$RPM_BUILD_ROOT/usr/man/man1/rview.1
#echo "so vim.1" >$RPM_BUILD_ROOT/usr/man/man1/rgvim.1
#echo "so vim.1" >$RPM_BUILD_ROOT/usr/man/man1/rgview.1

# Install the vim manpage once again to prevent erasing its contents
# in the prevoius step of stupid echoing links and to make the paths
# in manpage correct for the installation dirs.
sed -e s+/usr/local/lib/vim+/usr/share/vim+ \
-e s+/tmp/vim-tmp/share/vim/doc+/usr/share/vim/doc+ \
-e s+/tmp/vim-tmp/share/vim/syntax+/usr/share/vim/syntax+ \
-e s+/tmp/vim-tmp/share/vim/vimrc+/usr/share/vim/vimrc+ \
-e s+/tmp/vim-tmp/share/vim/gvimrc+/usr/share/vim/gvimrc+ \
-e s+/tmp/vim-tmp/share/vim/menu.vim+/usr/share/vim/menu.vim+ \
-e s+/tmp/vim-tmp/share/vim/bugreport.vim+/usr/share/vim/bugreport.vim+ \
doc/vim.1 > $RPM_BUILD_ROOT/usr/man/man1/vim.1
chmod 644 $RPM_BUILD_ROOT/usr/man/man1/vim.1

# Symlink additional manpages (with changed name of gvim linked with
# Motif/Lesstif) to the main vim manpage.
cd $RPM_BUILD_ROOT/usr/man/man1
ln -s vim.1 vi.1
ln -s vim.1 rxmgvim.1
ln -s vim.1 rxmgview.1
ln -s vim.1 xmgvim.1
ln -s vim.1 xmgview.1
cd -

# Installation of online help files in their proper location
# instead previous doc dir.
cp -a doc/*.txt $RPM_BUILD_ROOT/usr/share/vim/doc
cp -a doc/tags $RPM_BUILD_ROOT/usr/share/vim/doc

cp -a macros $RPM_BUILD_ROOT/usr/share/vim/macros
cp -a syntax $RPM_BUILD_ROOT/usr/share/vim/syntax
cp -a tutor $RPM_BUILD_ROOT/usr/share/vim/tutor

install -m644 menu.vim $RPM_BUILD_ROOT/usr/share/vim
install -m644 vimrc_example $RPM_BUILD_ROOT/usr/share/vim/vimrc
install -m644 gvimrc_example $RPM_BUILD_ROOT/usr/share/vim/gvimrc
install %{SOURCE2} $RPM_BUILD_ROOT/etc/X11/wmconfig/gvim
install %{SOURCE2} $RPM_BUILD_ROOT/etc/X11/wmconfig/xmgvim
touch $RPM_BUILD_ROOT/usr/bin/vim $RPM_BUILD_ROOT/usr/X11R6/bin/gvim $RPM_BUILD_ROOT/usr/X11R6/bin/xmgvim

cd $RPM_BUILD_ROOT/bin
ln -sf vi ex
ln -sf vi view
ln -sf vi rview
cd ../usr/bin
ln -sf vim rvim
cd ../X11R6/bin
ln -sf gvim rgvim
ln -sf gvim gview
ln -sf gvim rgview
ln -sf xmgvim rxmgvim
ln -sf xmgvim xmgview
ln -sf xmgvim rxmgview
# this conflicts badly with ctags ...
rm -f $RPM_BUILD_ROOT/usr/man/man1/ctags.1 
rm -f $RPM_BUILD_ROOT/usr/man/man1/etags.1

%clean
rm -rf $RPM_BUILD_ROOT

#%post slang
#ln -sf /usr/bin/vim.slang /usr/bin/vim

%post ncurses
ln -sf /usr/bin/vim.ncurses /usr/bin/vim

%post athena
ln -sf /usr/X11R6/bin/gvim.athena /usr/X11R6/bin/gvim

%post lesstif 
ln -sf /usr/X11R6/bin/gvim.lesstif /usr/X11R6/bin/xmgvim


%files
%defattr(0644, root, root, 755)
%attr(0711, root, root) /bin/*

#%files slang
#%attr(711, root, root) /usr/bin/vim.slang
#%attr(711, root, root) /usr/bin/rvim
#%attr(711, root, root) %ghost /usr/bin/vim

%files ncurses
%attr(711, root, root) /usr/bin/vim.ncurses
%attr(711, root, root) /usr/bin/rvim
%attr(711, root, root) %ghost /usr/bin/vim

%files athena
%attr(711, root, root) /usr/X11R6/bin/gvim.athena
%attr(711, root, root) /usr/X11R6/bin/rgvim
%attr(711, root, root) /usr/X11R6/bin/gview
%attr(711, root, root) /usr/X11R6/bin/rgview
%attr(644, root, root) /etc/X11/wmconfig/gvim
%attr(711, root, root) %ghost /usr/X11R6/bin/gvim

%files lesstif 
%attr(711, root, root) /usr/X11R6/bin/gvim.lesstif
%attr(711, root, root) /usr/X11R6/bin/rxmgvim
%attr(711, root, root) /usr/X11R6/bin/xmgview
%attr(711, root, root) /usr/X11R6/bin/rxmgview
%attr(644, root, root) /etc/X11/wmconfig/xmgvim
%attr(711, root, root) %ghost /usr/X11R6/bin/xmgvim

%files rt
%defattr(644, root, root, 755)
%doc README.txt bugreport.vim
%dir /usr/share/vim
%attr(444,root,root) /usr/share/vim/doc/*.txt
%attr(444,root,root) /usr/share/vim/doc/tags
%attr(644, root, man) /usr/man/man1/*
/usr/share/vim/macros
/usr/share/vim/syntax
/usr/share/vim/tutor
%config %verify(not size mtime md5) /usr/share/vim/menu.vim
%config %verify(not size mtime md5) /usr/share/vim/vimrc
%config %verify(not size mtime md5) /usr/share/vim/gvimrc

%changelog
* Mon Nov 16 1998 Marcin Wołyniak <marcin w heban.com.pl>
[5.3-3]
- changed to release 3.
- completly repaired and simplified installation of online help
  and man pages. Removed unnecessary echoing.
- compiled with gcc-2.81 and pgcc-1.1b against glibc-2.0.7, perl-5.004,
  python-1.4 and tcl/tk-8.0.
* Sun Nov 15 1998 Marcin Wołyniak <marcin w heban.com.pl>
[5.3-2]
- added, missing in the previous release, system-wide gvimrc.
- added, missing in the previous release, installation
  of on-line help files in the proper dir. Previously installed
  help files as docs in /usr/doc have been removed. README.txt
  and bugreport.vim were moved there instead.
- console library for vim-ncurses, vim-athena and vim-lesstif was
  changed from libtermcap to libncurses.
- the name of symlink from vim.lesstif was chenged from gvim to xmgvim
  to allow installation both X-gui packages simultaneously.
- changed hardwired location of system-wide rc file for static vi
  package from $VIM/vimrc to /etc/virc. It prevents very awfull
  error messages from parsing rcfile of the fully-featured version.
  The file /etc/virc is not installed itself. It can be created by
  admin - the vi static version is for him, isn't it?
- added second step of installing the vim manpage. The install routine
  changes paths in man page text to RPM_BUILD_ROOT path. It is not what
  we want and where we install the package! So tweak it with sed once again!
  More, echoing links to this manpage clears its contents! So,
  this secondary step regenarates the vim manpage too! Wow!!!
  People (read packagers), do you ever look through the log of compilation?
  Do you ever creates this one?
  
* Sun Oct 04 1998 Marcin Korzonek <mkorz w shadow.eu.org>
[5.3-1]
- completely rewritten spec, added 4 subpackages

* Thu Aug 13 1998 Wojtek Slusarczyk <wojtek w shadow.eu.org>
[5.0-1d]
- build against glibc-2.1,
- translation modified for pl,
- added build-root support,
- added %changelog,
- fixed permissions fo ELF binaries.


Więcej informacji o liście dyskusyjnej pld-devel-pl