From: "Cyprien Nicolas" <c.nicolas+gentoo@gmail.com>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] proj/lisp:master commit in: app-admin/eselect-guile/files/, app-admin/eselect-guile/, ...
Date: Fri, 19 Apr 2013 09:38:10 +0000 (UTC) [thread overview]
Message-ID: <1366364271.9a5970422cab53c52f27ec6e6c3fb8e941cf02ec.fulax@gentoo> (raw)
commit: 9a5970422cab53c52f27ec6e6c3fb8e941cf02ec
Author: Cyprien Nicolas (fulax) <gentoo <AT> fulax <DOT> fr>
AuthorDate: Fri Apr 19 09:32:30 2013 +0000
Commit: Cyprien Nicolas <c.nicolas+gentoo <AT> gmail <DOT> com>
CommitDate: Fri Apr 19 09:37:51 2013 +0000
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/lisp.git;a=commit;h=9a597042
app-admin/eselect-guile-1.2-r1: Add a call to 'clean' on pkg_prerm
Package-Manager: portage-2.2.01.21890-prefix
Manifest-Sign-Key: 0x3D79478FBE63A96F
---
app-admin/eselect-guile/ChangeLog | 11 +-
app-admin/eselect-guile/eselect-guile-1.1.ebuild | 30 ---
...uile-1.2.ebuild => eselect-guile-1.2-r1.ebuild} | 15 +-
app-admin/eselect-guile/files/1.2/guile.eselect | 247 --------------------
app-admin/eselect-guile/files/1.2/guile.eselect.5 | 94 --------
app-admin/eselect-guile/files/guile.eselect | 28 ++-
app-admin/eselect-guile/files/guile.eselect.5 | 6 +-
7 files changed, 39 insertions(+), 392 deletions(-)
diff --git a/app-admin/eselect-guile/ChangeLog b/app-admin/eselect-guile/ChangeLog
index b75ff67..d7de2d2 100644
--- a/app-admin/eselect-guile/ChangeLog
+++ b/app-admin/eselect-guile/ChangeLog
@@ -1,7 +1,15 @@
# ChangeLog for app-admin/eselect-guile
-# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
+# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
# $Header: $
+*eselect-guile-1.2-r1 (19 Apr 2013)
+
+ 19 Apr 2013; Cyprien Nicolas (fulax) <c.nicolas+gentoo@gmail.com>
+ +eselect-guile-1.2-r1.ebuild, -eselect-guile-1.1.ebuild,
+ -eselect-guile-1.2.ebuild, -files/1.2/guile.eselect,
+ -files/1.2/guile.eselect.5, files/guile.eselect, files/guile.eselect.5:
+ app-admin/eselect-guile-1.2-r1: Add a call to 'clean' on pkg_prerm
+
*eselect-guile-1.2 (02 Oct 2012)
02 Oct 2012; Cyprien Nicolas <c.nicolas+bugs@gmail.com> +files/1.2/guile.eselect,
@@ -9,4 +17,3 @@
version bump: EAPI 4, fix 'update ifunset' bug (it was ignored currently).
Remove 'GUILE_LOAD_PATH' from env.d file, as it breaks the not eselect'd
guile version. Drop pkg_prerm phase.
-
diff --git a/app-admin/eselect-guile/eselect-guile-1.1.ebuild b/app-admin/eselect-guile/eselect-guile-1.1.ebuild
deleted file mode 100644
index 7877a19..0000000
--- a/app-admin/eselect-guile/eselect-guile-1.1.ebuild
+++ /dev/null
@@ -1,30 +0,0 @@
-# Copyright 1999-2012 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: $
-
-DESCRIPTION="Manage multiple Guile versions on one system"
-HOMEPAGE="http://www.gentoo.org/proj/en/lisp/scheme/"
-#SRC_URI="mirror://gentoo/${P}.tar.bz2"
-
-LICENSE="GPL-2"
-SLOT="0"
-KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~ppc-aix ~sparc-fbsd ~x86-fbsd ~x86-freebsd ~ia64-hpux ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~sparc-solaris ~x86-solaris"
-IUSE=""
-
-# Versions prior to guile-1.8.8-r2 aren't properly slotted
-DEPEND=""
-RDEPEND=">=app-admin/eselect-1.2.6
- !<dev-scheme/guile-1.8.8-r2"
-
-src_install() {
- insinto /usr/share/eselect/modules
- doins "${FILESDIR}"/guile.eselect || die
- doman "${FILESDIR}"/guile.eselect.5 || die
- #dodoc ChangeLog || die
-}
-
-src_test() { :; }
-
-pkg_prerm() {
- eselect guile clean
-}
diff --git a/app-admin/eselect-guile/eselect-guile-1.2.ebuild b/app-admin/eselect-guile/eselect-guile-1.2-r1.ebuild
similarity index 76%
rename from app-admin/eselect-guile/eselect-guile-1.2.ebuild
rename to app-admin/eselect-guile/eselect-guile-1.2-r1.ebuild
index b633d45..2186cfb 100644
--- a/app-admin/eselect-guile/eselect-guile-1.2.ebuild
+++ b/app-admin/eselect-guile/eselect-guile-1.2-r1.ebuild
@@ -1,8 +1,8 @@
-# Copyright 1999-2012 Gentoo Foundation
+# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $
-EAPI=4
+EAPI=5
DESCRIPTION="Manage multiple Guile versions on one system"
HOMEPAGE="http://www.gentoo.org/proj/en/lisp/scheme/"
@@ -16,14 +16,19 @@ IUSE=""
# Versions prior to guile-1.8.8-r2 aren't properly slotted
DEPEND=""
RDEPEND=">=app-admin/eselect-1.2.6
- !<dev-scheme/guile-1.8.8-r2"
+ !<dev-scheme/guile-1.8.8-r3"
# We don't have any source directory to work on.
S="${T}"
src_install() {
insinto /usr/share/eselect/modules
- doins "${FILESDIR}"/${PV}/guile.eselect
- doman "${FILESDIR}"/${PV}/guile.eselect.5
+ doins "${FILESDIR}"/guile.eselect
+ doman "${FILESDIR}"/guile.eselect.5
#dodoc ChangeLog
}
+
+pkg_prerm() {
+ # Cleanup remaining symlinks
+ eselect guile clean
+}
diff --git a/app-admin/eselect-guile/files/1.2/guile.eselect b/app-admin/eselect-guile/files/1.2/guile.eselect
deleted file mode 100644
index 9242070..0000000
--- a/app-admin/eselect-guile/files/1.2/guile.eselect
+++ /dev/null
@@ -1,247 +0,0 @@
-# Copyright 1999-2012 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Id: $
-#
-# DOCUMENTATION
-# Following actions possible
-# * show do_show()
-# * list do_list()
-# * set do_set()
-# * update do_update()
-# * clean do_clean()
-#
-# Behaviour:
-# do_show():
-# Checks if /usr/bin/guile is a link and if the target exists,
-# if yes, it outputs the currently linked Guile version.
-# If it is no symlink, the user is told so, the same if there is
-# no /usr/bin/guile or the target does not exist.
-# do_list(): List all available versions of GNU Guile
-# do_set(): Set a version to be target of the symlink.
-# do_update(): Set the target to the highest version available
-# (optionally: only if not set)
-# do_clean(): Remove all set symlinks (for pkg_prerm)
-
-DESCRIPTION="Manage /usr/bin/guile* versions"
-MAINTAINER="scheme@gentoo.org"
-SVN_DATE='$Date: $'
-VERSION=$(svn_date_to_version "${SVN_DATE}")
-
-BINARYLIST="guile-snarf guile-config guile-tools guile guild"
-MANPAGELIST="guile"
-
-find_targets() {
- # Return the list of available Guile binaries
- local j
- for j in "${EROOT}"/usr/bin/guile-[0-9]*; do
- [[ -f ${j} ]] && basename ${j}
- done
-}
-
-remove_envfile() {
- # When cleaning symlinks this takes care of the info documentation settings
- rm -f "${EROOT}/etc/env.d/50guile"
-}
-
-set_envfile() {
- # Define INFOPATH environment variable in env file
- [[ -d ${EROOT}/usr/share/info/guile-$1 ]] || return 1
- echo "INFOPATH=${EPREFIX}/usr/share/info/guile-$1" >"${EROOT}/etc/env.d/50guile"
-}
-
-remove_symlinks() {
- # Remove existing symlinks to binaries, man pages,
- # m4 file, and the env file (own function)
- local f
- for f in ${BINARYLIST}; do
- rm -f "${EROOT}/usr/bin/${f}"
- done
- for f in ${MANPAGELIST}; do
- rm -f "${EROOT}"/usr/share/man/man1/${f}.1*
- done
- rm -f "${EROOT}"/usr/share/aclocal/guile.m4
- remove_envfile
-}
-
-set_bin_symlinks() {
- # Set symlinks to binaries in /usr/bin/
- local target=${1} f
- for f in ${BINARYLIST}; do
- # set symlink only if target binary actually exists
- if [[ -f ${EROOT}/usr/bin/${f}-${target} ]]; then
- ln -s "${f}-${target}" "${EROOT}/usr/bin/${f}" || die \
- "Couldn't set ${f}-${target} ${EROOT}/usr/bin/${f} symlink"
- fi
- done
-}
-
-set_m4_symlinks() {
- # Set symlink to guile.m4
- local target=${1}
- if [[ -f ${EROOT}/usr/share/aclocal/guile-${target}.m4 ]]; then
- ln -s "guile-${target}.m4" "${EROOT}"/usr/share/aclocal/guile.m4 \
- || die "Couldn't set guile-${target}.m4 guile.m4 symlink"
- fi
-}
-
-set_man_symlinks() {
- # Set symlinks to man pages
- local target=${1} extension f i
- for f in ${MANPAGELIST}; do
- for i in "${EROOT}"/usr/share/man/man1/${f}-${target}.1*; do
- if [[ -f ${i} ]]; then
- # target file exists; determine compress extension
- extension=${i##*/${f}-${target}.1}
- ln -s "${f}-${target}.1${extension}" \
- "${EROOT}/usr/share/man/man1/${f}.1${extension}"
- fi
- done
- done
-}
-
-set_symlinks() {
- # Set symlinks to binaries and man pages, update info path
- local target=$1 targets major
- # target may be specified by its name or its index
- if is_number "${target}"; then
- # numeric index, find the target's name
- targets=( $(find_targets) )
- [[ ${target} -ge 1 && ${target} -le ${#targets[@]} ]] \
- || die -q "Number out of range: ${1}"
- target=${targets[target-1]}
- fi
-
- # is the target valid, i.e. does a Guile binary with this name exist?
- [[ -f ${EROOT}/usr/bin/${target} ]] \
- || die -q "Target \"${1}\" doesn't appear to be valid!"
-
- echo "Switching guile to ${target} ..."
- remove_symlinks || die -q "Couldn't remove existing symlink"
-
- major=${target#guile-}
- set_bin_symlinks "${major}"
- set_m4_symlinks "${major}"
- set_man_symlinks "${major}"
- set_envfile "${major}"
-
- # update /etc/profile.env from /etc/env.d files
- do_action env update noldconfig
-
- return 0
-}
-
-test_for_root() {
- # checks if the user has rights to modify /usr/bin/
- [[ -w ${EROOT}/usr/bin ]] || die -q "You need root privileges!"
-}
-
-### show action ###
-
-describe_show() {
- echo "Show the current target of the Guile symlink"
-}
-
-do_show() {
- [[ $# -gt 0 ]] && die -q "Too many parameters"
-
- write_list_start "Current target of Guile symlink:"
- if [[ -L ${EROOT}/usr/bin/guile && -e ${EROOT}/usr/bin/guile ]]; then
- write_kv_list_entry \
- "$(basename "$(readlink "${EROOT}/usr/bin/guile")")" ""
- elif [[ -e ${EROOT}/usr/bin/guile ]]; then
- write_kv_list_entry \
- "(not a symlink or target of symlink does not exist)" ""
- else
- write_kv_list_entry "(unset)" ""
- fi
-}
-
-### list action ###
-
-describe_list() {
- echo "List available Guile symlink targets"
-}
-
-do_list() {
- [[ $# -gt 0 ]] && die -q "Too many parameters"
-
- local i targets
- targets=( $(find_targets) )
-
- for (( i = 0; i < ${#targets[@]}; i++ )); do
- # Highlight the currently chosen version
- [[ ${targets[i]} = \
- $(basename "$(readlink "${EROOT}/usr/bin/guile")") ]] \
- && targets[i]=$(highlight_marker "${targets[i]}")
- done
- write_list_start "Available Guile symlink targets:"
- write_numbered_list -m "(none found)" "${targets[@]}"
-}
-
-### set action ###
-
-describe_set() {
- echo "Set a new Guile symlink"
-}
-
-describe_set_options() {
- echo "target : Target name or number (from 'list' action)"
-}
-
-describe_set_parameters() {
- echo "<target>"
-}
-
-do_set() {
- [[ -z $1 ]] && die -q "You didn't tell me what to set the symlink to"
- [[ $# -gt 1 ]] && die -q "Too many parameters"
- test_for_root
-
- if [[ -e ${EROOT}/usr/bin/guile && ! -L ${EROOT}/usr/bin/guile ]]; then
- die -q "${EROOT}/usr/bin/guile exists but is not a symlink"
- fi
-
- set_symlinks "${1}" || die -q "Couldn't set a new symlink"
-}
-
-### update action ###
-
-describe_update() {
- echo "Automatically update the Guile symlink"
-}
-
-describe_update_options() {
- echo "ifunset : Do not override currently set version"
-}
-
-do_update() {
- [[ -z $1 || $1 = ifunset || $1 = --if-unset ]] || die -q "Usage error"
- [[ $# -gt 1 ]] && die -q "Too many parameters"
-
- [[ $# -eq 1 && -L ${EROOT}/usr/bin/guile ]] && return 0
-
- test_for_root
-
- if [[ -L ${EROOT}/usr/bin/guile ]]; then
- # this is not redundant: "update" is called in pkg_postrm() of guile
- # and should clean up any dead symlinks if no valid target exists
- remove_symlinks || die -q "Couldn't remove existing symlink"
- elif [[ -e ${EROOT}/usr/bin/guile ]]; then
- die -q "${EROOT}/usr/bin/guile exists but is not a symlink"
- fi
-
- local targets=( $(find_targets) )
- if [[ ${#targets[@]} -gt 0 ]]; then
- set_symlinks "${targets[${#targets[@]}-1]}" \
- || die -q "Couldn't set a new symlink"
- fi
-}
-
-### Clean action
-describe_clean() {
- echo "Remove any existing symlinks"
-}
-
-do_clean() {
- remove_symlinks
-}
diff --git a/app-admin/eselect-guile/files/1.2/guile.eselect.5 b/app-admin/eselect-guile/files/1.2/guile.eselect.5
deleted file mode 100644
index 86dbe13..0000000
--- a/app-admin/eselect-guile/files/1.2/guile.eselect.5
+++ /dev/null
@@ -1,94 +0,0 @@
-.\" Copyright 2007-2011 Gentoo Foundation
-.\" Distributed under the terms of the GNU General Public License v2
-.\" $Id: $
-.\"
-.TH guile.eselect 5 "August 2011" "Gentoo Linux" eselect
-.SH NAME
-guile.eselect \- The Guile management module for Gentoo's eselect
-.SH SYNOPSIS
-.B eselect guile
-.RB [ help | usage | version ]
-.br
-.B eselect guile list
-.br
-.B eselect guile set
-.I target
-.br
-.B eselect guile show
-.br
-.B eselect guile update
-.RB [ ifunset ]
-.SH DESCRIPTION
-.B eselect
-is Gentoo's configuration and management tool. It features modules
-that care for the individual administrative tasks.
-.SH ACTION: LIST
-.B eselect guile list
-.br
-List all installed Guile versions
-
-# eselect guile list
-.br
-Available Guile symlink targets:
-.br
- [1] guile-1.8
- [2] guile-2.0 *
-.SH ACTION: SET
-.B eselect guile set
-.I target
-.br
-Activate the selected Guile version.
-.I target
-can be either an identification number given by
-.B eselect guile list
-or the name of one installed version.
-.\" To avoid runtime issues with
-.\" incompatible byte-code from the previously selected Emacs version, run
-.\" .B emacs-updater -a rebuild
-.\" to remerge all needed packages.
-
-# eselect guile set 1
-.br
-Switching guile to guile-1.8 ...
-.SH ACTION: SHOW
-.B eselect guile show
-.br
-Print the currently activated Guile version.
-
-# eselect guile show
-.br
-Current target of Guile symlink:
-.br
- emacs-1.8
-.SH ACTION: UPDATE
-.B eselect guile update
-.RB [ ifunset ]
-.br
-Update the guile symlink to the last available version. If option
-.B ifunset
-is given, an existing implementation is not overridden.
-
-The update process consists in creating symlinks for guile's binaries,
-man page and aclocal.m4. It also generates an environment file.
-The symlinks concerns:
-.br
-* /usr/bin/guil[de] and /usr/bin/guile-{config,snarf,tools} binaries;
-.br
-* /usr/share/aclocal/guile.m4;
-.br
-* guile(1) man page.
-.br
-The environment file (/etc/env.d/50guile) defines INFOPATH and
-GUILE_LOAD_PATH.
-
-# eselect guile update
-.br
-Switching guile to guile-2.0 ...
-.SH AUTHORS
-Christian Faulhammer <fauli@gentoo.org>
-.br
-Ulrich Mueller <ulm@gentoo.org>
-.SH SEE ALSO
-.BR eselect (1)
-.SH REVISION
-$Id: $
diff --git a/app-admin/eselect-guile/files/guile.eselect b/app-admin/eselect-guile/files/guile.eselect
index 6376562..5f323a7 100644
--- a/app-admin/eselect-guile/files/guile.eselect
+++ b/app-admin/eselect-guile/files/guile.eselect
@@ -1,25 +1,25 @@
-# Copyright 2005-2012 Gentoo Foundation
+# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id: $
#
# DOCUMENTATION
# Following actions possible
-# * show do_show()
-# * list do_list()
-# * set do_set()
-# * update do_update()
+# * show do_show()
+# * list do_list()
+# * set do_set()
+# * update do_update()
# * clean do_clean()
#
# Behaviour:
# do_show():
-# Checks if /usr/bin/guile is a link and if the target exists,
-# if yes, it outputs the currently linked Guile version.
-# If it is no symlink, the user is told so, the same if there is
-# no /usr/bin/guile or the target does not exist.
+# Checks if /usr/bin/guile is a link and if the target exists,
+# if yes, it outputs the currently linked Guile version.
+# If it is no symlink, the user is told so, the same if there is
+# no /usr/bin/guile or the target does not exist.
# do_list(): List all available versions of GNU Guile
# do_set(): Set a version to be target of the symlink.
# do_update(): Set the target to the highest version available
-# (optionally: only if not set)
+# (optionally: only if not set)
# do_clean(): Remove all set symlinks (for pkg_prerm)
DESCRIPTION="Manage /usr/bin/guile* versions"
@@ -43,11 +43,10 @@ remove_envfile() {
rm -f "${EROOT}/etc/env.d/50guile"
}
-# Define GUILE_LOAD_PATH environment variable in env file
set_envfile() {
- echo "GUILE_LOAD_PATH=${EPREFIX}/usr/share/guile/$1" >"${EROOT}/etc/env.d/50guile"
+ # Define INFOPATH environment variable in env file
[[ -d ${EROOT}/usr/share/info/guile-$1 ]] || return 1
- echo "INFOPATH=${EPREFIX}/usr/share/info/guile-$1" >>"${EROOT}/etc/env.d/50guile"
+ echo "INFOPATH=${EPREFIX}/usr/share/info/guile-$1" >"${EROOT}/etc/env.d/50guile"
}
remove_symlinks() {
@@ -218,6 +217,9 @@ describe_update_options() {
do_update() {
[[ -z $1 || $1 = ifunset || $1 = --if-unset ]] || die -q "Usage error"
[[ $# -gt 1 ]] && die -q "Too many parameters"
+
+ [[ $# -eq 1 && -L ${EROOT}/usr/bin/guile ]] && return 0
+
test_for_root
if [[ -L ${EROOT}/usr/bin/guile ]]; then
diff --git a/app-admin/eselect-guile/files/guile.eselect.5 b/app-admin/eselect-guile/files/guile.eselect.5
index 86dbe13..c2be858 100644
--- a/app-admin/eselect-guile/files/guile.eselect.5
+++ b/app-admin/eselect-guile/files/guile.eselect.5
@@ -1,4 +1,4 @@
-.\" Copyright 2007-2011 Gentoo Foundation
+.\" Copyright 2007-2013 Gentoo Foundation
.\" Distributed under the terms of the GNU General Public License v2
.\" $Id: $
.\"
@@ -85,6 +85,10 @@ GUILE_LOAD_PATH.
.br
Switching guile to guile-2.0 ...
.SH AUTHORS
+Cyprien Nicolas <cyp@fulax.fr>
+.br
+This man page is based on eselect-emacs man-page whose authors are:
+.br
Christian Faulhammer <fauli@gentoo.org>
.br
Ulrich Mueller <ulm@gentoo.org>
reply other threads:[~2013-04-19 9:38 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1366364271.9a5970422cab53c52f27ec6e6c3fb8e941cf02ec.fulax@gentoo \
--to=c.nicolas+gentoo@gmail.com \
--cc=gentoo-commits@lists.gentoo.org \
--cc=gentoo-dev@lists.gentoo.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox