Move all stuff from lib to contrib

Also added template in contrib/distr for some distro-related files (spec, deb, ebuild, etc)
This commit is contained in:
Mikhail S. Pobolovets 2009-02-13 22:09:16 +02:00 committed by Slava Zanko
parent 73159dbc32
commit a55a505160
28 changed files with 99 additions and 101 deletions

View File

@ -2,11 +2,10 @@
AUTOMAKE_OPTIONS = 1.5
SUBDIRS = intl po vfs edit src lib doc syntax contrib
SUBDIRS = intl po vfs edit src doc syntax contrib
EXTRA_DIST =
noinst_DATA = mc.spec mc.qpg pkginfo prototype
dist_noinst_SCRIPTS = build-glib2.sh
ACLOCAL_AMFLAGS = -I m4

View File

@ -554,19 +554,20 @@ Makefile
contrib/Makefile
contrib/dist/Makefile
contrib/dist/mc.spec
contrib/dist/debian/Makefile
contrib/dist/gentoo/Makefile
contrib/dist/redhat/Makefile
contrib/dist/redhat/mc.spec
contrib/dist/mc.qpg
contrib/dist/pkginfo
contrib/dist/prototype
lib/Makefile
contrib/mc.ext
src/Makefile
src/search/Makefile
edit/Makefile
syntax/Makefile
lib/mc.ext
vfs/Makefile
vfs/extfs/Makefile

View File

@ -1,3 +1,47 @@
## Process this file with automake to create Makefile.in.
SUBDIRS = dist
suppbindir = $(pkgdatadir)/bin
if CHARSET
LIBFILES_ADD = mc.charsets
else
LIBFILES_ADD =
endif
LIBFILES_OUT = mc.ext
LIBFILES_CONST = mc.lib mc.menu mc.menu.sr cedit.menu edit.indent.rc \
edit.spell.rc
noinst_DATA = README.xterm mcserv.init mcserv.pamd xterm.ad
SCRIPTS_IN = mc.csh.in mc.sh.in mc-wrapper.csh.in mc-wrapper.sh.in
SCRIPTS_OUT = mc.csh mc.sh mc-wrapper.csh mc-wrapper.sh
suppbin_SCRIPTS = $(SCRIPTS_OUT)
pkgdata_DATA = $(LIBFILES_CONST) $(LIBFILES_ADD) $(LIBFILES_OUT)
CLEANFILES = $(SCRIPTS_OUT)
# Files processed by configure don't need to be here
EXTRA_DIST = \
$(LIBFILES_CONST) \
$(SCRIPTS_IN) \
$(noinst_DATA) \
mc.charsets
mc.csh: $(srcdir)/mc.csh.in
sed "s%@""suppbindir@%$(suppbindir)%" $(srcdir)/mc.csh.in > mc.csh
mc.sh: $(srcdir)/mc.sh.in
sed "s%@""suppbindir@%$(suppbindir)%" $(srcdir)/mc.sh.in > mc.sh
mc-wrapper.csh: $(srcdir)/mc-wrapper.csh.in
sed "s%@""bindir@%$(bindir)%" $(srcdir)/mc-wrapper.csh.in > mc-wrapper.csh
mc-wrapper.sh: $(srcdir)/mc-wrapper.sh.in
sed "s%@""bindir@%$(bindir)%" $(srcdir)/mc-wrapper.sh.in > mc-wrapper.sh

View File

@ -1,9 +1,11 @@
SUBDIRS = debian gentoo redhat
AUTOMAKE_OPTIONS = 1.5
EXTRA_DIST = pkginfo.in prototype.in mc.qpg.in mc.spec.in
EXTRA_DIST = pkginfo.in prototype.in mc.qpg.in
noinst_DATA = mc.spec mc.qpg pkginfo prototype
noinst_DATA = mc.qpg pkginfo prototype
ACLOCAL_AMFLAGS = -I m4

1
contrib/dist/debian/Makefile.am vendored Normal file
View File

@ -0,0 +1 @@

1
contrib/dist/gentoo/Makefile.am vendored Normal file
View File

@ -0,0 +1 @@

3
contrib/dist/redhat/Makefile.am vendored Normal file
View File

@ -0,0 +1,3 @@
EXTRA_DIST = mc.spec.in
noinst_DATA = mc.spec

View File

@ -10,23 +10,19 @@
%define ver @VERSION@
%define rpmver @RPM_VERSION@
%define RELEASE 1
%define rel %{?CUSTOM_RELEASE} %{!?CUSTOM_RELEASE:%RELEASE}
%define rel %{?CUSTOM_RELEASE} %{!?CUSTOM_RELEASE:%RELEASE}%{?dist}
Summary: Midnight Commander visual shell
Summary: User-friendly text console file manager and visual shell
Name: mc
Version: %rpmver
Release: %rel
Release: %rel%{?dist}
Epoch: 1
License: GPL/LGPL
Group: Applications/File
Source0: ftp://ftp.gnu.org/gnu/mc/mc-%{ver}.tar.gz
License: GPLv2
Group: System Environment/Shells
Source0: mc-%{ver}.tar.gz
URL: http://www.midnight-commander.org/
BuildRoot: /var/tmp/mc-%{PACKAGE_VERSION}-root
# Names of those packages are distribution specific
#BuildRequires: glib-devel
#%{!?_with_ncurses:BuildRequires: slang-devel}
#%{?_with_ncurses:BuildRequires: ncurses-devel}
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: glib2-devel e2fsprogs-devel slang-devel
%description
GNU Midnight Commander is a visual file manager. It's a feature rich
@ -35,69 +31,63 @@ delete files and whole directory trees, search for files and run
commands in the subshell. Internal viewer and editor are included.
Mouse is supported under X Window System and on Linux console. VFS
(Virtual Filesystem) allows you to view archives and files on remote
servers.
servers (via SAMBA, FTP or SSH).
%prep
%setup -q -n mc-%{ver}
%build
CFLAGS="$RPM_OPT_FLAGS" LDFLAGS="-s" ./configure \
--prefix=%{_prefix} \
--mandir=%{_mandir} \
%{?_with_ncurses: --with-screen=ncurses} \
%{?_with_charset: --enable-charset} \
%{?_with_samba: --with-samba} \
%{?_with_ext2undel: --with-ext2undel} \
%{?_without_x: --without-x}
make
%configure \
--with-screen=slang \
--enable-charset \
--with-samba \
--with-x \
--with-gpm-mouse
make %{?_smp_mflags}
%install
echo $RPM_BUILD_ROOT
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT/%{_sysconfdir}/profile.d
cp -f $RPM_BUILD_ROOT/%{_datadir}/mc/bin/mc.*sh \
$RPM_BUILD_ROOT/%{_sysconfdir}/profile.d
make install DESTDIR=$RPM_BUILD_ROOT
install -d -m 755 $RPM_BUILD_ROOT%{_sysconfdir}/profile.d
install contrib/{mc.sh,mc.csh} $RPM_BUILD_ROOT%{_sysconfdir}/profile.d
%find_lang %{name}
%clean
rm -rf $RPM_BUILD_ROOT
%files
%files -f %{name}.lang
%defattr(-, root, root)
%doc FAQ COPYING NEWS README
%doc doc/FAQ COPYING doc/NEWS doc/README
%{_bindir}/mc
%{_bindir}/mcedit
%{_bindir}/mcview
%{_bindir}/mcmfmt
%attr(4755, vcsa, tty) %{_libexecdir}/mc/cons.saver
%{_mandir}/man1/*
%{_mandir}/*/man1/*
%lang(es) %{_mandir}/es/man1/mc.1*
%lang(hu) %{_mandir}/hu/man1/mc.1*
%lang(it) %{_mandir}/it/man1/mc.1*
%lang(pl) %{_mandir}/pl/man1/mc.1*
%lang(ru) %{_mandir}/ru/man1/mc.1*
%lang(sr) %{_mandir}/sr/man1/mc.1*
%config %{_sysconfdir}/profile.d/*
%{_datadir}/mc/cedit.menu
%{_datadir}/mc/edit.indent.rc
%{_datadir}/mc/edit.spell.rc
%{_datadir}/mc/bin/*
%{_datadir}/mc/extfs/*
%{_datadir}/mc/mc.ext
%{_datadir}/mc/mc.lib
%{_datadir}/mc/mc.menu*
%{?_with_charset:%config %{_datadir}/mc/mc.charsets}
%{_sysconfdir}/profile.d/*
%{_datadir}/mc/mc.hint*
%{_datadir}/mc/mc.hlp*
%{_datadir}/mc/syntax/*
%{_datadir}/locale/*/LC_MESSAGES/*
%dir %{_datadir}/mc
%{_datadir}/mc/*
%dir %{_libexecdir}/mc
%dir %{_datadir}/mc
%dir %{_datadir}/mc/extfs
%dir %{_datadir}/mc/syntax
%changelog
* Fri May 8 2009 Slava Zanko <slavazanko@gmail.com>
- Review spec-file to build on the current distributions
- Change build rules
- Fix install pathes
* Fri Jun 22 2007 Pavel Roskin <proski@gnu.org>
- Make cons.saver suid vcsa, it's needed for Fedora 7

View File

@ -6,7 +6,7 @@ pkgdata_DATA = mc.hlp
EXTRA_DIST = xnc.hlp $(DX_CONFIG) doc/devel doxygen-include.am
CLEANFILES = $(pkgdata_DATA)
mc.hlp: mc.1 $(srcdir)/xnc.hlp $(top_builddir)/src/man2hlp
mc.hlp: man/mc.1 $(srcdir)/xnc.hlp $(top_builddir)/src/man2hlp
- $(top_builddir)/src/man2hlp man/mc.1 $(srcdir)/xnc.hlp mc.hlp
include doxygen-include.am

View File

@ -1,43 +0,0 @@
suppbindir = $(pkgdatadir)/bin
if CHARSET
LIBFILES_ADD = mc.charsets
else
LIBFILES_ADD =
endif
LIBFILES_OUT = mc.ext
LIBFILES_CONST = mc.lib mc.menu mc.menu.sr cedit.menu edit.indent.rc \
edit.spell.rc
noinst_DATA = README.xterm mcserv.init mcserv.pamd xterm.ad
SCRIPTS_IN = mc.csh.in mc.sh.in mc-wrapper.csh.in mc-wrapper.sh.in
SCRIPTS_OUT = mc.csh mc.sh mc-wrapper.csh mc-wrapper.sh
suppbin_SCRIPTS = $(SCRIPTS_OUT)
pkgdata_DATA = $(LIBFILES_CONST) $(LIBFILES_ADD) $(LIBFILES_OUT)
CLEANFILES = $(SCRIPTS_OUT)
# Files processed by configure don't need to be here
EXTRA_DIST = \
$(LIBFILES_CONST) \
$(SCRIPTS_IN) \
$(noinst_DATA) \
mc.charsets
mc.csh: $(srcdir)/mc.csh.in
sed "s%@""suppbindir@%$(suppbindir)%" $(srcdir)/mc.csh.in > mc.csh
mc.sh: $(srcdir)/mc.sh.in
sed "s%@""suppbindir@%$(suppbindir)%" $(srcdir)/mc.sh.in > mc.sh
mc-wrapper.csh: $(srcdir)/mc-wrapper.csh.in
sed "s%@""bindir@%$(bindir)%" $(srcdir)/mc-wrapper.csh.in > mc-wrapper.csh
mc-wrapper.sh: $(srcdir)/mc-wrapper.sh.in
sed "s%@""bindir@%$(bindir)%" $(srcdir)/mc-wrapper.sh.in > mc-wrapper.sh