summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Volkov <pva@gentoo.org>2013-05-11 21:29:22 +0000
committerPeter Volkov <pva@gentoo.org>2013-05-11 21:29:22 +0000
commit657c57c93bb7ed8dbfa04d6f970f49f22b0d63b5 (patch)
treef7dbaeb8adbe6ce41a24d5085d5fc61fa171f3f7 /www-apps
parentInitial commit. (diff)
downloadgentoo-2-657c57c93bb7ed8dbfa04d6f970f49f22b0d63b5.tar.gz
gentoo-2-657c57c93bb7ed8dbfa04d6f970f49f22b0d63b5.tar.bz2
gentoo-2-657c57c93bb7ed8dbfa04d6f970f49f22b0d63b5.zip
Version bump (thank Coacher): fixes incorrect dependencies reported in bug #451078, stop creating /var/run/redmine (create it in init script) #444936. Drop ldap authentification in case ldap was disabled, bug #413779 wrt Chris Murtagh and Diego Augusto Molina. Fixes trace in case openid is disabled. Fixes multiple security vulnerabilities, #418925 thank Manuel Rüger for report. Added fastercsv dependency reported in bug #453966. Drop old and vulnerable versions.
(Portage version: 2.1.11.62/cvs/Linux x86_64, signed Manifest commit with key F1989B07)
Diffstat (limited to 'www-apps')
-rw-r--r--www-apps/redmine/ChangeLog18
-rw-r--r--www-apps/redmine/files/redmine-2.initd8
-rw-r--r--www-apps/redmine/files/redmine-rubytree-r8214.patch261
-rw-r--r--www-apps/redmine/metadata.xml4
-rw-r--r--www-apps/redmine/redmine-1.3.2.ebuild180
-rw-r--r--www-apps/redmine/redmine-1.3.3.ebuild180
-rw-r--r--www-apps/redmine/redmine-1.4.1.ebuild203
-rw-r--r--www-apps/redmine/redmine-1.4.3.ebuild203
-rw-r--r--www-apps/redmine/redmine-1.4.7.ebuild (renamed from www-apps/redmine/redmine-1.4.5.ebuild)110
-rw-r--r--www-apps/redmine/redmine-2.1.5.ebuild215
-rw-r--r--www-apps/redmine/redmine-2.2.4.ebuild (renamed from www-apps/redmine/redmine-2.2.0.ebuild)127
11 files changed, 145 insertions, 1364 deletions
diff --git a/www-apps/redmine/ChangeLog b/www-apps/redmine/ChangeLog
index c201fa382961..6489772c4f09 100644
--- a/www-apps/redmine/ChangeLog
+++ b/www-apps/redmine/ChangeLog
@@ -1,6 +1,22 @@
# ChangeLog for www-apps/redmine
# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/ChangeLog,v 1.33 2013/01/07 13:39:26 matsuu Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/ChangeLog,v 1.34 2013/05/11 21:29:22 pva Exp $
+
+*redmine-2.2.4 (11 May 2013)
+*redmine-1.4.7 (11 May 2013)
+
+ 11 May 2013; Peter Volkov <pva@gentoo.org> -redmine-1.3.2.ebuild,
+ -redmine-1.3.3.ebuild, -redmine-1.4.1.ebuild, -redmine-1.4.3.ebuild,
+ -redmine-1.4.5.ebuild, +redmine-1.4.7.ebuild, -redmine-2.1.5.ebuild,
+ -redmine-2.2.0.ebuild, +redmine-2.2.4.ebuild, files/redmine-2.initd,
+ -files/redmine-rubytree-r8214.patch, metadata.xml:
+ Version bump (thank Coacher): fixes incorrect dependencies reported in bug
+ #451078, stop creating /var/run/redmine (create it in init script) #444936.
+ Drop ldap authentification in case ldap was disabled, bug #413779 wrt Chris
+ Murtagh and Diego Augusto Molina. Fixes trace in case openid is disabled.
+ Fixes multiple security vulnerabilities, #418925 thank Manuel Rüger for
+ report. Added fastercsv dependency reported in bug #453966. Drop old and
+ vulnerable versions.
*redmine-2.2.0 (07 Jan 2013)
*redmine-2.1.5 (07 Jan 2013)
diff --git a/www-apps/redmine/files/redmine-2.initd b/www-apps/redmine/files/redmine-2.initd
index e4aece87f935..1c73258ed3e6 100644
--- a/www-apps/redmine/files/redmine-2.initd
+++ b/www-apps/redmine/files/redmine-2.initd
@@ -1,7 +1,7 @@
#!/sbin/runscript
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/files/redmine-2.initd,v 1.1 2013/01/07 13:39:26 matsuu Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/files/redmine-2.initd,v 1.2 2013/05/11 21:29:22 pva Exp $
RAILS_ENV=${RAILS_ENV:-production}
REDMINE_DIR=${REDMINE_DIR:-/var/lib/redmine}
@@ -9,7 +9,7 @@ REDMINE_ADDRESS=${REDMINE_ADDRESS:-localhost}
REDMINE_PORT=${REDMINE_PORT:-3000}
REDMINE_USER=${REDMINE_USER:-redmine}
REDMINE_GROUP=${REDMINE_GROUP:-redmine}
-REDMINE_PIDFILE="${REDMINE_DIR}/tmp/pids/server.pid"
+REDMINE_PIDFILE="/var/run/redmine/server.pid"
depend() {
use apache2 git-daemon mysql net postgresql svnserve
@@ -23,6 +23,9 @@ start_pre() {
eerror
return 1
fi
+ if [ ! -d /var/run/redmine ]; then
+ checkpath -q -d -m 0755 -o redmine:redmine /var/run/redmine
+ fi
}
start() {
@@ -33,6 +36,7 @@ start() {
--exec /usr/bin/ruby "${REDMINE_DIR}"/script/rails server -- \
--daemon --environment=${RAILS_ENV} \
--binding=${REDMINE_ADDRESS} --port=${REDMINE_PORT} \
+ --pid /var/run/redmine/server.pid \
${REDMINE_OPTS}
eend $?
}
diff --git a/www-apps/redmine/files/redmine-rubytree-r8214.patch b/www-apps/redmine/files/redmine-rubytree-r8214.patch
deleted file mode 100644
index af325ec63390..000000000000
--- a/www-apps/redmine/files/redmine-rubytree-r8214.patch
+++ /dev/null
@@ -1,261 +0,0 @@
-Index: test/unit/lib/redmine/menu_manager/menu_item_test.rb
-===================================================================
---- test/unit/lib/redmine/menu_manager/menu_item_test.rb (リビジョン 8213)
-+++ test/unit/lib/redmine/menu_manager/menu_item_test.rb (リビジョン 8214)
-@@ -114,7 +114,7 @@
-
- def test_has_children
- parent_item = get_menu_item(:test_menu, :parent)
-- assert parent_item.hasChildren?
-+ assert parent_item.children.present?
- assert_equal 2, parent_item.children.size
- assert_equal get_menu_item(:test_menu, :child_menu), parent_item.children[0]
- assert_equal get_menu_item(:test_menu, :child2_menu), parent_item.children[1]
-Index: config/environment.rb
-===================================================================
---- config/environment.rb (リビジョン 8213)
-+++ config/environment.rb (リビジョン 8214)
-@@ -54,7 +54,6 @@
- # It will automatically turn deliveries on
- config.action_mailer.perform_deliveries = false
-
-- config.gem 'rubytree', :lib => 'tree'
- config.gem 'coderay', :version => '~>1.0.0'
-
- # Load any local configuration that is kept out of source control
-Index: lib/redmine/menu_manager.rb
-===================================================================
---- lib/redmine/menu_manager.rb (リビジョン 8213)
-+++ lib/redmine/menu_manager.rb (リビジョン 8214)
-@@ -15,93 +15,6 @@
- # along with this program; if not, write to the Free Software
- # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
-
--require 'tree' # gem install rubytree
--
--# Monkey patch the TreeNode to add on a few more methods :nodoc:
--module TreeNodePatch
-- def self.included(base)
-- base.class_eval do
-- attr_reader :last_items_count
--
-- alias :old_initilize :initialize
-- def initialize(name, content = nil)
-- old_initilize(name, content)
-- @childrenHash ||= {}
-- @last_items_count = 0
-- extend(InstanceMethods)
-- end
-- end
-- end
--
-- module InstanceMethods
-- # Adds the specified child node to the receiver node. The child node's
-- # parent is set to be the receiver. The child is added as the first child in
-- # the current list of children for the receiver node.
-- def prepend(child)
-- raise "Child already added" if @childrenHash.has_key?(child.name)
--
-- @childrenHash[child.name] = child
-- @children = [child] + @children
-- child.parent = self
-- return child
--
-- end
--
-- # Adds the specified child node to the receiver node. The child node's
-- # parent is set to be the receiver. The child is added at the position
-- # into the current list of children for the receiver node.
-- def add_at(child, position)
-- raise "Child already added" if @childrenHash.has_key?(child.name)
--
-- @childrenHash[child.name] = child
-- @children = @children.insert(position, child)
-- child.parent = self
-- return child
--
-- end
--
-- def add_last(child)
-- raise "Child already added" if @childrenHash.has_key?(child.name)
--
-- @childrenHash[child.name] = child
-- @children << child
-- @last_items_count += 1
-- child.parent = self
-- return child
--
-- end
--
-- # Adds the specified child node to the receiver node. The child node's
-- # parent is set to be the receiver. The child is added as the last child in
-- # the current list of children for the receiver node.
-- def add(child)
-- raise "Child already added" if @childrenHash.has_key?(child.name)
--
-- @childrenHash[child.name] = child
-- position = @children.size - @last_items_count
-- @children.insert(position, child)
-- child.parent = self
-- return child
--
-- end
--
-- # Wrapp remove! making sure to decrement the last_items counter if
-- # the removed child was a last item
-- def remove!(child)
-- @last_items_count -= +1 if child && child.last
-- super
-- end
--
--
-- # Will return the position (zero-based) of the current child in
-- # it's parent
-- def position
-- self.parent.children.index(self)
-- end
-- end
--end
--Tree::TreeNode.send(:include, TreeNodePatch)
--
- module Redmine
- module MenuManager
- class MenuError < StandardError #:nodoc:
-@@ -169,7 +82,7 @@
-
- def display_main_menu?(project)
- menu_name = project && !project.new_record? ? :project_menu : :application_menu
-- Redmine::MenuManager.items(menu_name).size > 1 # 1 element is the root
-+ Redmine::MenuManager.items(menu_name).children.present?
- end
-
- def render_menu(menu, project=nil)
-@@ -181,7 +94,7 @@
- end
-
- def render_menu_node(node, project=nil)
-- if node.hasChildren? || !node.child_menus.nil?
-+ if node.children.present? || !node.child_menus.nil?
- return render_menu_node_with_children(node, project)
- else
- caption, url, selected = extract_node_details(node, project)
-@@ -306,13 +219,13 @@
- end
-
- def items(menu_name)
-- @items[menu_name.to_sym] || Tree::TreeNode.new(:root, {})
-+ @items[menu_name.to_sym] || MenuNode.new(:root, {})
- end
- end
-
- class Mapper
- def initialize(menu, items)
-- items[menu] ||= Tree::TreeNode.new(:root, {})
-+ items[menu] ||= MenuNode.new(:root, {})
- @menu = menu
- @menu_items = items[menu]
- end
-@@ -398,7 +311,102 @@
- end
- end
-
-- class MenuItem < Tree::TreeNode
-+ class MenuNode
-+ include Enumerable
-+ attr_accessor :parent
-+ attr_reader :last_items_count, :name
-+
-+ def initialize(name, content = nil)
-+ @name = name
-+ @childrenHash ||= {}
-+ @children = []
-+ @last_items_count = 0
-+ end
-+
-+ def children
-+ if block_given?
-+ @children.each {|child| yield child}
-+ else
-+ @children
-+ end
-+ end
-+
-+ # Returns the number of descendants + 1
-+ def size
-+ @children.inject(1) {|sum, node| sum + node.size}
-+ end
-+
-+ def each &block
-+ yield self
-+ children { |child| child.each(&block) }
-+ end
-+
-+ # Adds a child at first position
-+ def prepend(child)
-+ raise "Child already added" if @childrenHash.has_key?(child.name)
-+
-+ @childrenHash[child.name] = child
-+ @children = [child] + @children
-+ child.parent = self
-+ return child
-+ end
-+
-+ # Adds a child at given position
-+ def add_at(child, position)
-+ raise "Child already added" if @childrenHash.has_key?(child.name)
-+
-+ @childrenHash[child.name] = child
-+ @children = @children.insert(position, child)
-+ child.parent = self
-+ return child
-+ end
-+
-+ # Adds a child as last child
-+ def add_last(child)
-+ raise "Child already added" if @childrenHash.has_key?(child.name)
-+
-+ @childrenHash[child.name] = child
-+ @children << child
-+ @last_items_count += 1
-+ child.parent = self
-+ return child
-+ end
-+
-+ # Adds a child
-+ def add(child)
-+ raise "Child already added" if @childrenHash.has_key?(child.name)
-+
-+ @childrenHash[child.name] = child
-+ position = @children.size - @last_items_count
-+ @children.insert(position, child)
-+ child.parent = self
-+ return child
-+ end
-+ alias :<< :add
-+
-+ # Removes a child
-+ def remove!(child)
-+ @childrenHash.delete(child.name)
-+ @children.delete(child)
-+ @last_items_count -= +1 if child && child.last
-+ child.parent = nil
-+ child
-+ end
-+
-+ # Returns the position for this node in it's parent
-+ def position
-+ self.parent.children.index(self)
-+ end
-+
-+ # Returns the root for this node
-+ def root
-+ root = self
-+ root = root.parent while root.parent
-+ root
-+ end
-+ end
-+
-+ class MenuItem < MenuNode
- include Redmine::I18n
- attr_reader :name, :url, :param, :condition, :parent, :child_menus, :last
-
diff --git a/www-apps/redmine/metadata.xml b/www-apps/redmine/metadata.xml
index 7dbf569a0d17..232c704c46d2 100644
--- a/www-apps/redmine/metadata.xml
+++ b/www-apps/redmine/metadata.xml
@@ -4,6 +4,10 @@
<maintainer>
<email>matsuu@gentoo.org</email>
</maintainer>
+<maintainer>
+<email>pva@gentoo.org</email>
+<name>Peter Volkov</name>
+</maintainer>
<longdescription lang="en">
</longdescription>
<use>
diff --git a/www-apps/redmine/redmine-1.3.2.ebuild b/www-apps/redmine/redmine-1.3.2.ebuild
deleted file mode 100644
index e0c2b70b4e22..000000000000
--- a/www-apps/redmine/redmine-1.3.2.ebuild
+++ /dev/null
@@ -1,180 +0,0 @@
-# Copyright 1999-2012 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/redmine-1.3.2.ebuild,v 1.2 2012/08/16 03:58:52 flameeyes Exp $
-
-EAPI="3"
-# ruby19: dev-ruby/rack has no ruby19
-# jruby: dev-ruby/rails has no jruby
-# rbx: dev-ruby/rails has no rbx
-#USE_RUBY="ruby18 ree18"
-USE_RUBY="ruby18"
-inherit eutils depend.apache ruby-ng
-
-DESCRIPTION="Redmine is a flexible project management web application written using Ruby on Rails framework"
-HOMEPAGE="http://www.redmine.org/"
-SRC_URI="mirror://rubyforge/${PN}/${P}.tar.gz"
-
-KEYWORDS="~amd64 ~x86"
-LICENSE="GPL-2"
-SLOT="0"
-#IUSE="bazaar cvs darcs fastcgi git imagemagick mercurial mysql openid passenger postgres sqlite3 subversion"
-IUSE="fastcgi imagemagick openid passenger"
-
-RDEPEND="$(ruby_implementation_depend ruby18 '>=' -1.8.6)[ssl]"
-
-ruby_add_rdepend "virtual/ruby-ssl
- virtual/rubygems
- >=dev-ruby/coderay-1
- >=dev-ruby/ruby-net-ldap-0.0.4
- ~dev-ruby/i18n-0.4.2
- >=dev-ruby/rack-1.1:0
- dev-ruby/rake
- >=dev-ruby/rails-2.3.14:2.3
- dev-ruby/activerecord:2.3
- fastcgi? ( dev-ruby/fcgi )
- imagemagick? ( dev-ruby/rmagick )
- openid? ( dev-ruby/ruby-openid )
- passenger? ( www-apache/passenger )"
-
-#RDEPEND="${RDEPEND}
-# bazaar ( dev-vcs/bazaar )
-# cvs? ( >=dev-vcs/cvs-1.12 )
-# darcs? ( dev-vcs/darcs )
-# git? ( dev-vcs/git )
-# mercurial? ( dev-vcs/mercurial )
-# subversion? ( >=dev-vcs/subversion-1.3 )"
-
-REDMINE_DIR="/var/lib/${PN}"
-
-pkg_setup() {
- enewgroup redmine
- # home directory is required for SCM.
- enewuser redmine -1 -1 "${REDMINE_DIR}" redmine
-}
-
-all_ruby_prepare() {
- rm -r log files/delete.me || die
- rm -r vendor/gems/coderay-1.0.0 || die
- rm -r vendor/plugins/ruby-net-ldap-0.0.4 || die
- rm -fr vendor/rails || die
-
- # bug #406605
- rm .gitignore .hgignore || die
-
- # bug #399503
- rm -r vendor/gems/rubytree-0.5.2 || die
- epatch "${FILESDIR}/${PN}-rubytree-r8214.patch"
-
- echo "CONFIG_PROTECT=\"${EPREFIX}${REDMINE_DIR}/config\"" > "${T}/50${PN}"
- echo "CONFIG_PROTECT_MASK=\"${EPREFIX}${REDMINE_DIR}/config/locales ${EPREFIX}${REDMINE_DIR}/config/settings.yml\"" >> "${T}/50${PN}"
- sed -i -e "/RAILS_GEM_VERSION/s/'.*'/'$(best_version dev-ruby/rails:2.3|cut -d- -f3)'/" config/environment.rb || die
-}
-
-all_ruby_install() {
- dodoc doc/{CHANGELOG,INSTALL,README_FOR_APP,RUNNING_TESTS,UPGRADING} || die
- rm -fr doc || die
- dodoc README.rdoc || die
- rm README.rdoc || die
-
- keepdir /var/log/${PN} || die
- dosym /var/log/${PN}/ "${REDMINE_DIR}/log" || die
-
- insinto "${REDMINE_DIR}"
- doins -r . || die
- keepdir "${REDMINE_DIR}/files" || die
- keepdir "${REDMINE_DIR}/public/plugin_assets" || die
-
- fowners -R redmine:redmine \
- "${REDMINE_DIR}/config" \
- "${REDMINE_DIR}/files" \
- "${REDMINE_DIR}/public/plugin_assets" \
- "${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
- # for SCM
- fowners redmine:redmine "${REDMINE_DIR}" || die
- # bug #406605
- fperms -R go-rwx \
- "${REDMINE_DIR}/config" \
- "${REDMINE_DIR}/files" \
- "${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
-
- if use passenger ; then
- has_apache
- insinto "${APACHE_VHOSTS_CONFDIR}"
- doins "${FILESDIR}/10_redmine_vhost.conf" || die
- else
- newconfd "${FILESDIR}/${PN}.confd" ${PN} || die
- newinitd "${FILESDIR}/${PN}.initd" ${PN} || die
- keepdir /var/run/${PN} || die
- fowners -R redmine:redmine /var/run/${PN} || die
- dosym /var/run/${PN}/ "${REDMINE_DIR}/tmp/pids" || die
- fi
- doenvd "${T}/50${PN}" || die
-}
-
-pkg_postinst() {
- einfo
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ] ; then
- elog "Execute the following command to upgrade environment:"
- elog
- elog "# emerge --config \"=${CATEGORY}/${PF}\""
- elog
- elog "For upgrade instructions take a look at:"
- elog "http://www.redmine.org/wiki/redmine/RedmineUpgrade"
- else
- elog "Execute the following command to initlize environment:"
- elog
- elog "# cd ${EPREFIX}${REDMINE_DIR}"
- elog "# cp config/database.yml.example config/database.yml"
- elog "# \${EDITOR} config/database.yml"
- elog "# emerge --config \"=${CATEGORY}/${PF}\""
- elog
- elog "Installation notes are at official site"
- elog "http://www.redmine.org/wiki/redmine/RedmineInstall"
- fi
- einfo
-}
-
-pkg_config() {
- if [ ! -e "${EPREFIX}${REDMINE_DIR}/config/database.yml" ] ; then
- eerror "Copy ${EPREFIX}${REDMINE_DIR}/config/database.yml.example to ${EPREFIX}${REDMINE_DIR}/config/database.yml and edit this file in order to configure your database settings for \"production\" environment."
- die
- fi
-
- local RAILS_ENV=${RAILS_ENV:-production}
- local RUBY=${RUBY:-ruby18}
-
- cd "${EPREFIX}${REDMINE_DIR}"
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ] ; then
- einfo
- einfo "Upgrade database."
- einfo
-
- einfo "Migrate database."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Upgrade the plugin migrations."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate:upgrade_plugin_migrations # || die
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate_plugins || die
- einfo "Clear the cache and the existing sessions."
- ${RUBY} -S rake tmp:cache:clear || die
- ${RUBY} -S rake tmp:sessions:clear || die
- else
- einfo
- einfo "Initialize database."
- einfo
-
- einfo "Generate a session store secret."
- ${RUBY} -S rake generate_session_store || die
- einfo "Create the database structure."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Insert default configuration data in database."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake redmine:load_default_data || die
- einfo
- einfo "If you use sqlite3. please do not forget to change the ownership of the sqlite files."
- einfo
- einfo "# cd \"${EPREFIX}${REDMINE_DIR}\""
- einfo "# chown redmine db/ db/*.sqlite3"
- einfo
- fi
-}
diff --git a/www-apps/redmine/redmine-1.3.3.ebuild b/www-apps/redmine/redmine-1.3.3.ebuild
deleted file mode 100644
index ce822c5c33d7..000000000000
--- a/www-apps/redmine/redmine-1.3.3.ebuild
+++ /dev/null
@@ -1,180 +0,0 @@
-# Copyright 1999-2012 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/redmine-1.3.3.ebuild,v 1.2 2012/08/16 03:58:52 flameeyes Exp $
-
-EAPI="3"
-# ruby19: dev-ruby/rack has no ruby19
-# jruby: dev-ruby/rails has no jruby
-# rbx: dev-ruby/rails has no rbx
-#USE_RUBY="ruby18 ree18"
-USE_RUBY="ruby18"
-inherit eutils depend.apache ruby-ng
-
-DESCRIPTION="Redmine is a flexible project management web application written using Ruby on Rails framework"
-HOMEPAGE="http://www.redmine.org/"
-SRC_URI="mirror://rubyforge/${PN}/${P}.tar.gz"
-
-KEYWORDS="~amd64 ~x86"
-LICENSE="GPL-2"
-SLOT="0"
-#IUSE="bazaar cvs darcs fastcgi git imagemagick mercurial mysql openid passenger postgres sqlite3 subversion"
-IUSE="fastcgi imagemagick openid passenger"
-
-RDEPEND="$(ruby_implementation_depend ruby18 '>=' -1.8.6)[ssl]"
-
-ruby_add_rdepend "virtual/ruby-ssl
- virtual/rubygems
- >=dev-ruby/coderay-1
- >=dev-ruby/ruby-net-ldap-0.0.4
- ~dev-ruby/i18n-0.4.2
- >=dev-ruby/rack-1.1:0
- dev-ruby/rake
- >=dev-ruby/rails-2.3.14:2.3
- dev-ruby/activerecord:2.3
- fastcgi? ( dev-ruby/fcgi )
- imagemagick? ( dev-ruby/rmagick )
- openid? ( dev-ruby/ruby-openid )
- passenger? ( www-apache/passenger )"
-
-#RDEPEND="${RDEPEND}
-# bazaar ( dev-vcs/bazaar )
-# cvs? ( >=dev-vcs/cvs-1.12 )
-# darcs? ( dev-vcs/darcs )
-# git? ( dev-vcs/git )
-# mercurial? ( dev-vcs/mercurial )
-# subversion? ( >=dev-vcs/subversion-1.3 )"
-
-REDMINE_DIR="/var/lib/${PN}"
-
-pkg_setup() {
- enewgroup redmine
- # home directory is required for SCM.
- enewuser redmine -1 -1 "${REDMINE_DIR}" redmine
-}
-
-all_ruby_prepare() {
- rm -r log files/delete.me || die
- rm -r vendor/gems/coderay-1.0.0 || die
- rm -r vendor/plugins/ruby-net-ldap-0.0.4 || die
- rm -fr vendor/rails || die
-
- # bug #406605
- rm .gitignore .hgignore || die
-
- # bug #399503
- rm -r vendor/gems/rubytree-0.5.2 || die
- epatch "${FILESDIR}/${PN}-rubytree-r8214.patch"
-
- echo "CONFIG_PROTECT=\"${EPREFIX}${REDMINE_DIR}/config\"" > "${T}/50${PN}"
- echo "CONFIG_PROTECT_MASK=\"${EPREFIX}${REDMINE_DIR}/config/locales ${EPREFIX}${REDMINE_DIR}/config/settings.yml\"" >> "${T}/50${PN}"
- sed -i -e "/RAILS_GEM_VERSION/s/'.*'/'$(best_version dev-ruby/rails:2.3|cut -d- -f3)'/" config/environment.rb || die
-}
-
-all_ruby_install() {
- dodoc doc/{CHANGELOG,INSTALL,README_FOR_APP,RUNNING_TESTS,UPGRADING} || die
- rm -fr doc || die
- dodoc README.rdoc || die
- rm README.rdoc || die
-
- keepdir /var/log/${PN} || die
- dosym /var/log/${PN}/ "${REDMINE_DIR}/log" || die
-
- insinto "${REDMINE_DIR}"
- doins -r . || die
- keepdir "${REDMINE_DIR}/files" || die
- keepdir "${REDMINE_DIR}/public/plugin_assets" || die
-
- fowners -R redmine:redmine \
- "${REDMINE_DIR}/config" \
- "${REDMINE_DIR}/files" \
- "${REDMINE_DIR}/public/plugin_assets" \
- "${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
- # for SCM
- fowners redmine:redmine "${REDMINE_DIR}" || die
- # bug #406605
- fperms -R go-rwx \
- "${REDMINE_DIR}/config" \
- "${REDMINE_DIR}/files" \
- "${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
-
- if use passenger ; then
- has_apache
- insinto "${APACHE_VHOSTS_CONFDIR}"
- doins "${FILESDIR}/10_redmine_vhost.conf" || die
- else
- newconfd "${FILESDIR}/${PN}.confd" ${PN} || die
- newinitd "${FILESDIR}/${PN}.initd" ${PN} || die
- keepdir /var/run/${PN} || die
- fowners -R redmine:redmine /var/run/${PN} || die
- dosym /var/run/${PN}/ "${REDMINE_DIR}/tmp/pids" || die
- fi
- doenvd "${T}/50${PN}" || die
-}
-
-pkg_postinst() {
- einfo
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ] ; then
- elog "Execute the following command to upgrade environment:"
- elog
- elog "# emerge --config \"=${CATEGORY}/${PF}\""
- elog
- elog "For upgrade instructions take a look at:"
- elog "http://www.redmine.org/wiki/redmine/RedmineUpgrade"
- else
- elog "Execute the following command to initlize environment:"
- elog
- elog "# cd ${EPREFIX}${REDMINE_DIR}"
- elog "# cp config/database.yml.example config/database.yml"
- elog "# \${EDITOR} config/database.yml"
- elog "# emerge --config \"=${CATEGORY}/${PF}\""
- elog
- elog "Installation notes are at official site"
- elog "http://www.redmine.org/wiki/redmine/RedmineInstall"
- fi
- einfo
-}
-
-pkg_config() {
- if [ ! -e "${EPREFIX}${REDMINE_DIR}/config/database.yml" ] ; then
- eerror "Copy ${EPREFIX}${REDMINE_DIR}/config/database.yml.example to ${EPREFIX}${REDMINE_DIR}/config/database.yml and edit this file in order to configure your database settings for \"production\" environment."
- die
- fi
-
- local RAILS_ENV=${RAILS_ENV:-production}
- local RUBY=${RUBY:-ruby18}
-
- cd "${EPREFIX}${REDMINE_DIR}"
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ] ; then
- einfo
- einfo "Upgrade database."
- einfo
-
- einfo "Migrate database."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Upgrade the plugin migrations."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate:upgrade_plugin_migrations # || die
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate_plugins || die
- einfo "Clear the cache and the existing sessions."
- ${RUBY} -S rake tmp:cache:clear || die
- ${RUBY} -S rake tmp:sessions:clear || die
- else
- einfo
- einfo "Initialize database."
- einfo
-
- einfo "Generate a session store secret."
- ${RUBY} -S rake generate_session_store || die
- einfo "Create the database structure."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Insert default configuration data in database."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake redmine:load_default_data || die
- einfo
- einfo "If you use sqlite3. please do not forget to change the ownership of the sqlite files."
- einfo
- einfo "# cd \"${EPREFIX}${REDMINE_DIR}\""
- einfo "# chown redmine db/ db/*.sqlite3"
- einfo
- fi
-}
diff --git a/www-apps/redmine/redmine-1.4.1.ebuild b/www-apps/redmine/redmine-1.4.1.ebuild
deleted file mode 100644
index d9bc9fcf6533..000000000000
--- a/www-apps/redmine/redmine-1.4.1.ebuild
+++ /dev/null
@@ -1,203 +0,0 @@
-# Copyright 1999-2012 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/redmine-1.4.1.ebuild,v 1.2 2012/08/16 03:58:52 flameeyes Exp $
-
-EAPI="3"
-# ruby19: dev-ruby/rack has no ruby19
-# jruby: dev-ruby/rails has no jruby
-# rbx: dev-ruby/rails has no rbx
-#USE_RUBY="ruby18 ree18"
-USE_RUBY="ruby18"
-inherit eutils depend.apache ruby-ng
-
-DESCRIPTION="Redmine is a flexible project management web application written using Ruby on Rails framework"
-HOMEPAGE="http://www.redmine.org/"
-SRC_URI="mirror://rubyforge/${PN}/${P}.tar.gz"
-
-KEYWORDS="~amd64 ~x86"
-LICENSE="GPL-2"
-SLOT="0"
-#IUSE="bazaar cvs darcs fastcgi git imagemagick mercurial mysql openid passenger postgres sqlite3 subversion"
-IUSE="fastcgi imagemagick ldap openid passenger"
-
-RDEPEND="$(ruby_implementation_depend ruby18 '>=' -1.8.6)[ssl]"
-
-ruby_add_rdepend "virtual/ruby-ssl
- virtual/rubygems
- >=dev-ruby/coderay-1.0.6
- dev-ruby/i18n:0.4
- >=dev-ruby/rack-1.1:0
- >=dev-ruby/tzinfo-0.3.31
- dev-ruby/rake
- >=dev-ruby/rails-2.3.14:2.3
- fastcgi? ( dev-ruby/fcgi )
- imagemagick? ( >=dev-ruby/rmagick-2 )
- ldap? ( >=dev-ruby/ruby-net-ldap-0.3.1 )
- openid? ( >=dev-ruby/ruby-openid-2.1.4 )
- passenger? ( www-apache/passenger )
- ruby_targets_ruby18? (
- >=dev-ruby/fastercsv-1.5
- )"
-# ruby_targets_ruby18? (
-# >=dev-ruby/fastercsv-1.5
-# postgres? ( >=dev-ruby/pg-0.11 )
-# sqlite3? ( dev-ruby/sqlite3 )
-# mysql? ( dev-ruby/mysql )
-# )
-# ruby_targets_ruby19? (
-# postgres? ( >=dev-ruby/pg-0.11 )
-# sqlite3? ( dev-ruby/sqlite3 )
-# mysql? ( dev-ruby/mysql2:0.2 )
-# )
-# ruby_targets_jruby? (
-# >=dev-ruby/fastercsv-1.5
-# mysql? ( dev-ruby/activerecord-jdbcmysql-adapter )
-# postgres? ( dev-ruby/activerecord-jdbcpostgresql-adapter )
-# sqlite3? ( dev-ruby/activerecord-jdbcsqlite3-adapter )
-# )
-
-#ruby_add_bdepend ">=dev-ruby/rdoc-2.4.2
-# test? (
-# >=dev-ruby/shoulda-2.10.3
-# >=dev-ruby/edavis10-object_daddy
-# >=dev-ruby/mocha
-# )"
-
-#RDEPEND="${RDEPEND}
-# bazaar ( dev-vcs/bazaar )
-# cvs? ( >=dev-vcs/cvs-1.12 )
-# darcs? ( dev-vcs/darcs )
-# git? ( dev-vcs/git )
-# mercurial? ( dev-vcs/mercurial )
-# subversion? ( >=dev-vcs/subversion-1.3 )"
-
-REDMINE_DIR="/var/lib/${PN}"
-
-pkg_setup() {
- enewgroup redmine
- # home directory is required for SCM.
- enewuser redmine -1 -1 "${REDMINE_DIR}" redmine
-}
-
-all_ruby_prepare() {
- rm -r log files/delete.me || die
-
- # bug #406605
- rm .gitignore .hgignore || die
-
- rm Gemfile config/preinitializer.rb || die
- epatch "${FILESDIR}/${P}-bundler.patch" || die
-
- echo "CONFIG_PROTECT=\"${EPREFIX}${REDMINE_DIR}/config\"" > "${T}/50${PN}"
- echo "CONFIG_PROTECT_MASK=\"${EPREFIX}${REDMINE_DIR}/config/locales ${EPREFIX}${REDMINE_DIR}/config/settings.yml\"" >> "${T}/50${PN}"
-}
-
-all_ruby_install() {
- dodoc doc/{CHANGELOG,INSTALL,README_FOR_APP,RUNNING_TESTS,UPGRADING} || die
- rm -fr doc || die
- dodoc README.rdoc || die
- rm README.rdoc || die
-
- keepdir /var/log/${PN} || die
- dosym /var/log/${PN}/ "${REDMINE_DIR}/log" || die
-
- insinto "${REDMINE_DIR}"
- doins -r . || die
- keepdir "${REDMINE_DIR}/files" || die
- keepdir "${REDMINE_DIR}/public/plugin_assets" || die
-
- fowners -R redmine:redmine \
- "${REDMINE_DIR}/config" \
- "${REDMINE_DIR}/files" \
- "${REDMINE_DIR}/public/plugin_assets" \
- "${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
- # for SCM
- fowners redmine:redmine "${REDMINE_DIR}" || die
- # bug #406605
- fperms -R go-rwx \
- "${REDMINE_DIR}/config" \
- "${REDMINE_DIR}/files" \
- "${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
-
- if use passenger ; then
- has_apache
- insinto "${APACHE_VHOSTS_CONFDIR}"
- doins "${FILESDIR}/10_redmine_vhost.conf" || die
- else
- newconfd "${FILESDIR}/${PN}.confd" ${PN} || die
- newinitd "${FILESDIR}/${PN}.initd" ${PN} || die
- keepdir /var/run/${PN} || die
- fowners -R redmine:redmine /var/run/${PN} || die
- dosym /var/run/${PN}/ "${REDMINE_DIR}/tmp/pids" || die
- fi
- doenvd "${T}/50${PN}" || die
-}
-
-pkg_postinst() {
- einfo
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ] ; then
- elog "Execute the following command to upgrade environment:"
- elog
- elog "# emerge --config \"=${CATEGORY}/${PF}\""
- elog
- elog "For upgrade instructions take a look at:"
- elog "http://www.redmine.org/wiki/redmine/RedmineUpgrade"
- else
- elog "Execute the following command to initlize environment:"
- elog
- elog "# cd ${EPREFIX}${REDMINE_DIR}"
- elog "# cp config/database.yml.example config/database.yml"
- elog "# \${EDITOR} config/database.yml"
- elog "# chown redmine:redmine config/database.yml"
- elog "# emerge --config \"=${CATEGORY}/${PF}\""
- elog
- elog "Installation notes are at official site"
- elog "http://www.redmine.org/wiki/redmine/RedmineInstall"
- fi
- einfo
-}
-
-pkg_config() {
- if [ ! -e "${EPREFIX}${REDMINE_DIR}/config/database.yml" ] ; then
- eerror "Copy ${EPREFIX}${REDMINE_DIR}/config/database.yml.example to ${EPREFIX}${REDMINE_DIR}/config/database.yml and edit this file in order to configure your database settings for \"production\" environment."
- die
- fi
-
- local RAILS_ENV=${RAILS_ENV:-production}
- local RUBY=${RUBY:-ruby18}
-
- cd "${EPREFIX}${REDMINE_DIR}"
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ] ; then
- einfo
- einfo "Upgrade database."
- einfo
-
- einfo "Migrate database."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Upgrade the plugin migrations."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate:upgrade_plugin_migrations # || die
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate_plugins || die
- einfo "Clear the cache and the existing sessions."
- ${RUBY} -S rake tmp:cache:clear || die
- ${RUBY} -S rake tmp:sessions:clear || die
- else
- einfo
- einfo "Initialize database."
- einfo
-
- einfo "Generate a session store secret."
- ${RUBY} -S rake generate_session_store || die
- einfo "Create the database structure."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Insert default configuration data in database."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake redmine:load_default_data || die
- einfo
- einfo "If you use sqlite3. please do not forget to change the ownership of the sqlite files."
- einfo
- einfo "# cd \"${EPREFIX}${REDMINE_DIR}\""
- einfo "# chown redmine:redmine db/ db/*.sqlite3"
- einfo
- fi
-}
diff --git a/www-apps/redmine/redmine-1.4.3.ebuild b/www-apps/redmine/redmine-1.4.3.ebuild
deleted file mode 100644
index 19ac2a8aa743..000000000000
--- a/www-apps/redmine/redmine-1.4.3.ebuild
+++ /dev/null
@@ -1,203 +0,0 @@
-# Copyright 1999-2012 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/redmine-1.4.3.ebuild,v 1.2 2012/08/16 03:58:52 flameeyes Exp $
-
-EAPI="3"
-# ruby19: dev-ruby/rack has no ruby19
-# jruby: dev-ruby/rails has no jruby
-# rbx: dev-ruby/rails has no rbx
-#USE_RUBY="ruby18 ree18"
-USE_RUBY="ruby18"
-inherit eutils depend.apache ruby-ng
-
-DESCRIPTION="Redmine is a flexible project management web application written using Ruby on Rails framework"
-HOMEPAGE="http://www.redmine.org/"
-SRC_URI="mirror://rubyforge/${PN}/${P}.tar.gz"
-
-KEYWORDS="~amd64 ~x86"
-LICENSE="GPL-2"
-SLOT="0"
-#IUSE="bazaar cvs darcs fastcgi git imagemagick mercurial mysql openid passenger postgres sqlite3 subversion"
-IUSE="fastcgi imagemagick ldap openid passenger"
-
-RDEPEND="$(ruby_implementation_depend ruby18 '>=' -1.8.6)[ssl]"
-
-ruby_add_rdepend "virtual/ruby-ssl
- virtual/rubygems
- >=dev-ruby/coderay-1.0.6
- dev-ruby/i18n:0.4
- >=dev-ruby/rack-1.1:0
- >=dev-ruby/tzinfo-0.3.31
- dev-ruby/rake
- >=dev-ruby/rails-2.3.14:2.3
- fastcgi? ( dev-ruby/fcgi )
- imagemagick? ( >=dev-ruby/rmagick-2 )
- ldap? ( >=dev-ruby/ruby-net-ldap-0.3.1 )
- openid? ( >=dev-ruby/ruby-openid-2.1.4 )
- passenger? ( www-apache/passenger )
- ruby_targets_ruby18? (
- >=dev-ruby/fastercsv-1.5
- )"
-# ruby_targets_ruby18? (
-# >=dev-ruby/fastercsv-1.5
-# postgres? ( >=dev-ruby/pg-0.11 )
-# sqlite3? ( dev-ruby/sqlite3 )
-# mysql? ( dev-ruby/mysql )
-# )
-# ruby_targets_ruby19? (
-# postgres? ( >=dev-ruby/pg-0.11 )
-# sqlite3? ( dev-ruby/sqlite3 )
-# mysql? ( dev-ruby/mysql2:0.2 )
-# )
-# ruby_targets_jruby? (
-# >=dev-ruby/fastercsv-1.5
-# mysql? ( dev-ruby/activerecord-jdbcmysql-adapter )
-# postgres? ( dev-ruby/activerecord-jdbcpostgresql-adapter )
-# sqlite3? ( dev-ruby/activerecord-jdbcsqlite3-adapter )
-# )
-
-#ruby_add_bdepend ">=dev-ruby/rdoc-2.4.2
-# test? (
-# >=dev-ruby/shoulda-2.10.3
-# >=dev-ruby/edavis10-object_daddy
-# >=dev-ruby/mocha
-# )"
-
-#RDEPEND="${RDEPEND}
-# bazaar ( dev-vcs/bazaar )
-# cvs? ( >=dev-vcs/cvs-1.12 )
-# darcs? ( dev-vcs/darcs )
-# git? ( dev-vcs/git )
-# mercurial? ( dev-vcs/mercurial )
-# subversion? ( >=dev-vcs/subversion-1.3 )"
-
-REDMINE_DIR="/var/lib/${PN}"
-
-pkg_setup() {
- enewgroup redmine
- # home directory is required for SCM.
- enewuser redmine -1 -1 "${REDMINE_DIR}" redmine
-}
-
-all_ruby_prepare() {
- rm -r log files/delete.me || die
-
- # bug #406605
- rm .gitignore .hgignore || die
-
- rm Gemfile config/preinitializer.rb || die
- epatch "${FILESDIR}/${PN}-1.4.1-bundler.patch" || die
-
- echo "CONFIG_PROTECT=\"${EPREFIX}${REDMINE_DIR}/config\"" > "${T}/50${PN}"
- echo "CONFIG_PROTECT_MASK=\"${EPREFIX}${REDMINE_DIR}/config/locales ${EPREFIX}${REDMINE_DIR}/config/settings.yml\"" >> "${T}/50${PN}"
-}
-
-all_ruby_install() {
- dodoc doc/{CHANGELOG,INSTALL,README_FOR_APP,RUNNING_TESTS,UPGRADING} || die
- rm -fr doc || die
- dodoc README.rdoc || die
- rm README.rdoc || die
-
- keepdir /var/log/${PN} || die
- dosym /var/log/${PN}/ "${REDMINE_DIR}/log" || die
-
- insinto "${REDMINE_DIR}"
- doins -r . || die
- keepdir "${REDMINE_DIR}/files" || die
- keepdir "${REDMINE_DIR}/public/plugin_assets" || die
-
- fowners -R redmine:redmine \
- "${REDMINE_DIR}/config" \
- "${REDMINE_DIR}/files" \
- "${REDMINE_DIR}/public/plugin_assets" \
- "${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
- # for SCM
- fowners redmine:redmine "${REDMINE_DIR}" || die
- # bug #406605
- fperms -R go-rwx \
- "${REDMINE_DIR}/config" \
- "${REDMINE_DIR}/files" \
- "${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
-
- if use passenger ; then
- has_apache
- insinto "${APACHE_VHOSTS_CONFDIR}"
- doins "${FILESDIR}/10_redmine_vhost.conf" || die
- else
- newconfd "${FILESDIR}/${PN}.confd" ${PN} || die
- newinitd "${FILESDIR}/${PN}.initd" ${PN} || die
- keepdir /var/run/${PN} || die
- fowners -R redmine:redmine /var/run/${PN} || die
- dosym /var/run/${PN}/ "${REDMINE_DIR}/tmp/pids" || die
- fi
- doenvd "${T}/50${PN}" || die
-}
-
-pkg_postinst() {
- einfo
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ] ; then
- elog "Execute the following command to upgrade environment:"
- elog
- elog "# emerge --config \"=${CATEGORY}/${PF}\""
- elog
- elog "For upgrade instructions take a look at:"
- elog "http://www.redmine.org/wiki/redmine/RedmineUpgrade"
- else
- elog "Execute the following command to initlize environment:"
- elog
- elog "# cd ${EPREFIX}${REDMINE_DIR}"
- elog "# cp config/database.yml.example config/database.yml"
- elog "# \${EDITOR} config/database.yml"
- elog "# chown redmine:redmine config/database.yml"
- elog "# emerge --config \"=${CATEGORY}/${PF}\""
- elog
- elog "Installation notes are at official site"
- elog "http://www.redmine.org/wiki/redmine/RedmineInstall"
- fi
- einfo
-}
-
-pkg_config() {
- if [ ! -e "${EPREFIX}${REDMINE_DIR}/config/database.yml" ] ; then
- eerror "Copy ${EPREFIX}${REDMINE_DIR}/config/database.yml.example to ${EPREFIX}${REDMINE_DIR}/config/database.yml and edit this file in order to configure your database settings for \"production\" environment."
- die
- fi
-
- local RAILS_ENV=${RAILS_ENV:-production}
- local RUBY=${RUBY:-ruby18}
-
- cd "${EPREFIX}${REDMINE_DIR}"
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ] ; then
- einfo
- einfo "Upgrade database."
- einfo
-
- einfo "Migrate database."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Upgrade the plugin migrations."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate:upgrade_plugin_migrations # || die
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate_plugins || die
- einfo "Clear the cache and the existing sessions."
- ${RUBY} -S rake tmp:cache:clear || die
- ${RUBY} -S rake tmp:sessions:clear || die
- else
- einfo
- einfo "Initialize database."
- einfo
-
- einfo "Generate a session store secret."
- ${RUBY} -S rake generate_session_store || die
- einfo "Create the database structure."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Insert default configuration data in database."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake redmine:load_default_data || die
- einfo
- einfo "If you use sqlite3. please do not forget to change the ownership of the sqlite files."
- einfo
- einfo "# cd \"${EPREFIX}${REDMINE_DIR}\""
- einfo "# chown redmine:redmine db/ db/*.sqlite3"
- einfo
- fi
-}
diff --git a/www-apps/redmine/redmine-1.4.5.ebuild b/www-apps/redmine/redmine-1.4.7.ebuild
index 5e888a133015..2995fcf50dd3 100644
--- a/www-apps/redmine/redmine-1.4.5.ebuild
+++ b/www-apps/redmine/redmine-1.4.7.ebuild
@@ -1,12 +1,10 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/redmine-1.4.5.ebuild,v 1.1 2013/01/07 13:39:26 matsuu Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/redmine-1.4.7.ebuild,v 1.1 2013/05/11 21:29:22 pva Exp $
-EAPI="3"
-# ruby19: dev-ruby/rack has no ruby19
-# jruby: dev-ruby/rails has no jruby
-# rbx: dev-ruby/rails has no rbx
-#USE_RUBY="ruby18 ree18"
+EAPI="4"
+# rails:2.3 isn't available for ruby19 on Gentoo
+#USE_RUBY="ruby18 ruby19"
USE_RUBY="ruby18"
inherit eutils depend.apache ruby-ng
@@ -17,23 +15,24 @@ SRC_URI="mirror://rubyforge/${PN}/${P}.tar.gz"
KEYWORDS="~amd64 ~x86"
LICENSE="GPL-2"
SLOT="0"
-#IUSE="bazaar cvs darcs fastcgi git imagemagick mercurial mysql openid passenger postgres sqlite3 subversion"
-IUSE="fastcgi imagemagick ldap openid passenger"
+# All db-related USEs are ineffective since we depend on rails
+# which depends on activerecord which depends on all ruby's db bindings
+#IUSE="ldap openid imagemagick postgres sqlite mysql fastcgi passenger"
+IUSE="ldap openid imagemagick fastcgi passenger"
-RDEPEND="$(ruby_implementation_depend ruby18 '>=' -1.8.6)[ssl]"
+#RDEPEND="$(ruby_implementation_depend jruby '>=' -1.6.7)[ssl]"
ruby_add_rdepend "virtual/ruby-ssl
virtual/rubygems
- >=dev-ruby/coderay-1.0.6
+ >=dev-ruby/rails-2.3.15:2.3
dev-ruby/i18n:0.4
- >=dev-ruby/rack-1.1:0
+ >=dev-ruby/coderay-1.0.6
>=dev-ruby/tzinfo-0.3.31
dev-ruby/rake
- >=dev-ruby/rails-2.3.14:2.3
- fastcgi? ( dev-ruby/fcgi )
- imagemagick? ( >=dev-ruby/rmagick-2 )
ldap? ( >=dev-ruby/ruby-net-ldap-0.3.1 )
openid? ( >=dev-ruby/ruby-openid-2.1.4 )
+ imagemagick? ( >=dev-ruby/rmagick-2 )
+ fastcgi? ( dev-ruby/fcgi )
passenger? ( www-apache/passenger )
ruby_targets_ruby18? (
>=dev-ruby/fastercsv-1.5
@@ -42,7 +41,7 @@ ruby_add_rdepend "virtual/ruby-ssl
# >=dev-ruby/fastercsv-1.5
# postgres? ( >=dev-ruby/pg-0.11 )
# sqlite3? ( dev-ruby/sqlite3 )
-# mysql? ( dev-ruby/mysql )
+# mysql? ( >=dev-ruby/mysql-ruby-2.8.1 )
# )
# ruby_targets_ruby19? (
# postgres? ( >=dev-ruby/pg-0.11 )
@@ -50,6 +49,7 @@ ruby_add_rdepend "virtual/ruby-ssl
# mysql? ( dev-ruby/mysql2:0.2 )
# )
# ruby_targets_jruby? (
+# dev-ruby/jruby-openssl
# >=dev-ruby/fastercsv-1.5
# mysql? ( dev-ruby/activerecord-jdbcmysql-adapter )
# postgres? ( dev-ruby/activerecord-jdbcpostgresql-adapter )
@@ -58,24 +58,23 @@ ruby_add_rdepend "virtual/ruby-ssl
#ruby_add_bdepend ">=dev-ruby/rdoc-2.4.2
# test? (
-# >=dev-ruby/shoulda-2.10.3
+# !ruby_targets_ruby19? (
+# >=dev-ruby/shoulda-2.11
+# )
+# ruby_targets_ruby19? (
+# dev-ruby/test-unit
+# )
+# ruby_targets_jruby? (
+# dev-ruby/test-unit
+# )
# >=dev-ruby/edavis10-object_daddy
-# >=dev-ruby/mocha-0.12.3
+# =dev-ruby/mocha-0.12*
# )"
-#RDEPEND="${RDEPEND}
-# bazaar ( dev-vcs/bazaar )
-# cvs? ( >=dev-vcs/cvs-1.12 )
-# darcs? ( dev-vcs/darcs )
-# git? ( dev-vcs/git )
-# mercurial? ( dev-vcs/mercurial )
-# subversion? ( >=dev-vcs/subversion-1.3 )"
-
REDMINE_DIR="/var/lib/${PN}"
pkg_setup() {
enewgroup redmine
- # home directory is required for SCM.
enewuser redmine -1 -1 "${REDMINE_DIR}" redmine
}
@@ -86,53 +85,51 @@ all_ruby_prepare() {
rm .gitignore .hgignore || die
rm Gemfile config/preinitializer.rb || die
- epatch "${FILESDIR}/${PN}-1.4.1-bundler.patch" || die
+ epatch "${FILESDIR}/${PN}-1.4.1-bundler.patch"
echo "CONFIG_PROTECT=\"${EPREFIX}${REDMINE_DIR}/config\"" > "${T}/50${PN}"
echo "CONFIG_PROTECT_MASK=\"${EPREFIX}${REDMINE_DIR}/config/locales ${EPREFIX}${REDMINE_DIR}/config/settings.yml\"" >> "${T}/50${PN}"
}
all_ruby_install() {
- dodoc doc/{CHANGELOG,INSTALL,README_FOR_APP,RUNNING_TESTS,UPGRADING} || die
+ dodoc doc/{CHANGELOG,INSTALL,README_FOR_APP,RUNNING_TESTS,UPGRADING}
rm -fr doc || die
- dodoc README.rdoc || die
+ dodoc README.rdoc
rm README.rdoc || die
- keepdir /var/log/${PN} || die
- dosym /var/log/${PN}/ "${REDMINE_DIR}/log" || die
+ keepdir /var/log/${PN}
+ dosym /var/log/${PN}/ "${REDMINE_DIR}/log"
insinto "${REDMINE_DIR}"
- doins -r . || die
- keepdir "${REDMINE_DIR}/files" || die
- keepdir "${REDMINE_DIR}/public/plugin_assets" || die
+ doins -r .
+ keepdir "${REDMINE_DIR}/files"
+ keepdir "${REDMINE_DIR}/public/plugin_assets"
fowners -R redmine:redmine \
"${REDMINE_DIR}/config" \
"${REDMINE_DIR}/files" \
"${REDMINE_DIR}/public/plugin_assets" \
"${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
- # for SCM
- fowners redmine:redmine "${REDMINE_DIR}" || die
- # bug #406605
+ /var/log/${PN}
+
+ fowners redmine:redmine "${REDMINE_DIR}"
+
+ # protect sensitive data, see bug #406605
fperms -R go-rwx \
"${REDMINE_DIR}/config" \
"${REDMINE_DIR}/files" \
"${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
+ /var/log/${PN}
if use passenger ; then
has_apache
insinto "${APACHE_VHOSTS_CONFDIR}"
- doins "${FILESDIR}/10_redmine_vhost.conf" || die
+ doins "${FILESDIR}/10_redmine_vhost.conf"
else
- newconfd "${FILESDIR}/${PN}.confd" ${PN} || die
- newinitd "${FILESDIR}/${PN}.initd" ${PN} || die
- keepdir /var/run/${PN} || die
- fowners -R redmine:redmine /var/run/${PN} || die
- dosym /var/run/${PN}/ "${REDMINE_DIR}/tmp/pids" || die
+ newconfd "${FILESDIR}/${PN}.confd" ${PN}
+ newinitd "${FILESDIR}/${PN}.initd" ${PN}
fi
- doenvd "${T}/50${PN}" || die
+ doenvd "${T}/50${PN}"
}
pkg_postinst() {
@@ -161,22 +158,23 @@ pkg_postinst() {
pkg_config() {
if [ ! -e "${EPREFIX}${REDMINE_DIR}/config/database.yml" ] ; then
- eerror "Copy ${EPREFIX}${REDMINE_DIR}/config/database.yml.example to ${EPREFIX}${REDMINE_DIR}/config/database.yml and edit this file in order to configure your database settings for \"production\" environment."
+ eerror "Copy ${EPREFIX}${REDMINE_DIR}/config/database.yml.example to ${EPREFIX}${REDMINE_DIR}/config/database.yml"
+ eerror "then edit this file in order to configure your database settings for \"production\" environment."
die
fi
local RAILS_ENV=${RAILS_ENV:-production}
local RUBY=${RUBY:-ruby18}
- cd "${EPREFIX}${REDMINE_DIR}"
+ cd "${EPREFIX}${REDMINE_DIR}" || die
if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ] ; then
einfo
- einfo "Upgrade database."
+ einfo "Upgrading database."
einfo
- einfo "Migrate database."
+ einfo "Migrating database."
RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Upgrade the plugin migrations."
+ einfo "Upgrading the plugin migrations."
RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate:upgrade_plugin_migrations # || die
RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate_plugins || die
einfo "Clear the cache and the existing sessions."
@@ -184,17 +182,17 @@ pkg_config() {
${RUBY} -S rake tmp:sessions:clear || die
else
einfo
- einfo "Initialize database."
+ einfo "Initializing database."
einfo
- einfo "Generate a session store secret."
+ einfo "Generating a session store secret."
${RUBY} -S rake generate_session_store || die
- einfo "Create the database structure."
+ einfo "Creating the database structure."
RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Insert default configuration data in database."
+ einfo "Populating database with default configuration dat."
RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake redmine:load_default_data || die
einfo
- einfo "If you use sqlite3. please do not forget to change the ownership of the sqlite files."
+ einfo "If you use sqlite3, please do not forget to change the ownership of the sqlite files."
einfo
einfo "# cd \"${EPREFIX}${REDMINE_DIR}\""
einfo "# chown redmine:redmine db/ db/*.sqlite3"
diff --git a/www-apps/redmine/redmine-2.1.5.ebuild b/www-apps/redmine/redmine-2.1.5.ebuild
deleted file mode 100644
index e883a8570e24..000000000000
--- a/www-apps/redmine/redmine-2.1.5.ebuild
+++ /dev/null
@@ -1,215 +0,0 @@
-# Copyright 1999-2013 Gentoo Foundation
-# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/redmine-2.1.5.ebuild,v 1.1 2013/01/07 13:39:26 matsuu Exp $
-
-EAPI="3"
-# ruby19: dev-ruby/rack has no ruby19
-# jruby: dev-ruby/rails has no jruby
-# rbx: dev-ruby/rails has no rbx
-#USE_RUBY="ruby18 ree18"
-USE_RUBY="ruby18 ruby19"
-inherit eutils depend.apache ruby-ng
-
-DESCRIPTION="Redmine is a flexible project management web application written using Ruby on Rails framework"
-HOMEPAGE="http://www.redmine.org/"
-SRC_URI="mirror://rubyforge/${PN}/${P}.tar.gz"
-
-KEYWORDS="~amd64 ~x86"
-LICENSE="GPL-2"
-SLOT="0"
-#IUSE="bazaar cvs darcs fastcgi git imagemagick mercurial mysql openid passenger postgres sqlite3 subversion"
-IUSE="fastcgi imagemagick ldap openid passenger"
-
-#RDEPEND="$(ruby_implementation_depend ruby18 '>=' -1.8.6)[ssl]"
-
-ruby_add_rdepend "virtual/ruby-ssl
- virtual/rubygems
- >=dev-ruby/coderay-1.0.6
- dev-ruby/i18n:0.6
- dev-ruby/rake
- ~dev-ruby/rails-3.2.8:3.2
- >=dev-ruby/jquery-rails-2.0.2
- dev-ruby/builder:3
- fastcgi? ( dev-ruby/fcgi )
- imagemagick? ( >=dev-ruby/rmagick-2 )
- ldap? ( >=dev-ruby/ruby-net-ldap-0.3.1 )
- openid? (
- >=dev-ruby/ruby-openid-2.1.4
- >=dev-ruby/rack-openid-0.2.1
- )
- passenger? ( www-apache/passenger )
- "
-# ruby_targets_ruby18? (
-# >=dev-ruby/fastercsv-1.5
-# postgres? ( >=dev-ruby/pg-0.11 )
-# sqlite3? ( dev-ruby/sqlite3 )
-# mysql? ( >=dev-ruby/mysql-ruby-2.8.1 )
-# )
-# ruby_targets_ruby19? (
-# postgres? ( >=dev-ruby/pg-0.11 )
-# sqlite3? ( dev-ruby/sqlite3 )
-# mysql? ( dev-ruby/mysql2:0.3 )
-# )
-# ruby_targets_jruby? (
-# dev-ruby/jruby-openssl
-# >=dev-ruby/fastercsv-1.5
-# mysql? ( dev-ruby/activerecord-jdbcmysql-adapter )
-# postgres? ( dev-ruby/activerecord-jdbcpostgresql-adapter )
-# sqlite3? ( dev-ruby/activerecord-jdbcsqlite3-adapter )
-# )
-
-#ruby_add_bdepend ">=dev-ruby/rdoc-2.4.2
-# yard
-# test? (
-# !ruby_targets_ruby19? (
-# >=dev-ruby/shoulda-2.11
-# )
-# ruby_targets_ruby19? (
-# dev-ruby/test-unit
-# )
-# >=dev-ruby/mocha-0.12.3
-# )"
-
-#RDEPEND="${RDEPEND}
-# bazaar ( dev-vcs/bazaar )
-# cvs? ( >=dev-vcs/cvs-1.12 )
-# darcs? ( dev-vcs/darcs )
-# git? ( dev-vcs/git )
-# mercurial? ( dev-vcs/mercurial )
-# subversion? ( >=dev-vcs/subversion-1.3 )"
-
-REDMINE_DIR="/var/lib/${PN}"
-
-pkg_setup() {
- enewgroup redmine
- # home directory is required for SCM.
- enewuser redmine -1 -1 "${REDMINE_DIR}" redmine
-}
-
-all_ruby_prepare() {
- rm -r log files/delete.me || die
-
- # bug #406605
- rm .gitignore .hgignore || die
-
- rm Gemfile config/preinitializer.rb || die
-
- echo "CONFIG_PROTECT=\"${EPREFIX}${REDMINE_DIR}/config\"" > "${T}/50${PN}"
- echo "CONFIG_PROTECT_MASK=\"${EPREFIX}${REDMINE_DIR}/config/locales ${EPREFIX}${REDMINE_DIR}/config/settings.yml\"" >> "${T}/50${PN}"
-}
-
-all_ruby_install() {
- dodoc doc/{CHANGELOG,INSTALL,README_FOR_APP,RUNNING_TESTS,UPGRADING} || die
- rm -fr doc || die
- dodoc README.rdoc || die
- rm README.rdoc || die
-
- keepdir /var/log/${PN} || die
- dosym /var/log/${PN}/ "${REDMINE_DIR}/log" || die
-
- insinto "${REDMINE_DIR}"
- doins -r . || die
- keepdir "${REDMINE_DIR}/files" || die
- keepdir "${REDMINE_DIR}/public/plugin_assets" || die
-
- fowners -R redmine:redmine \
- "${REDMINE_DIR}/config" \
- "${REDMINE_DIR}/files" \
- "${REDMINE_DIR}/public/plugin_assets" \
- "${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
- # for SCM
- fowners redmine:redmine "${REDMINE_DIR}" || die
- # bug #406605
- fperms -R go-rwx \
- "${REDMINE_DIR}/config" \
- "${REDMINE_DIR}/files" \
- "${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
-
- if use passenger ; then
- has_apache
- insinto "${APACHE_VHOSTS_CONFDIR}"
- doins "${FILESDIR}/10_redmine_vhost.conf" || die
- else
- newconfd "${FILESDIR}/${PN}.confd" ${PN} || die
- newinitd "${FILESDIR}/${PN}-2.initd" ${PN} || die
- keepdir /var/run/${PN} || die
- fowners -R redmine:redmine /var/run/${PN} || die
- dosym /var/run/${PN}/ "${REDMINE_DIR}/tmp/pids" || die
- fi
- doenvd "${T}/50${PN}" || die
-}
-
-pkg_postinst() {
- einfo
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" -o -e "${EPREFIX}${REDMINE_DIR}/config/initializers/secret_token.rb" ] ; then
- elog "Execute the following command to upgrade environment:"
- elog
- elog "# emerge --config \"=${CATEGORY}/${PF}\""
- elog
- elog "For upgrade instructions take a look at:"
- elog "http://www.redmine.org/wiki/redmine/RedmineUpgrade"
- else
- elog "Execute the following command to initlize environment:"
- elog
- elog "# cd ${EPREFIX}${REDMINE_DIR}"
- elog "# cp config/database.yml.example config/database.yml"
- elog "# \${EDITOR} config/database.yml"
- elog "# chown redmine:redmine config/database.yml"
- elog "# emerge --config \"=${CATEGORY}/${PF}\""
- elog
- elog "Installation notes are at official site"
- elog "http://www.redmine.org/wiki/redmine/RedmineInstall"
- fi
- einfo
-}
-
-pkg_config() {
- if [ ! -e "${EPREFIX}${REDMINE_DIR}/config/database.yml" ] ; then
- eerror "Copy ${EPREFIX}${REDMINE_DIR}/config/database.yml.example to ${EPREFIX}${REDMINE_DIR}/config/database.yml and edit this file in order to configure your database settings for \"production\" environment."
- die
- fi
-
- local RAILS_ENV=${RAILS_ENV:-production}
- local RUBY=${RUBY:-ruby18}
-
- cd "${EPREFIX}${REDMINE_DIR}"
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ] ; then
- einfo
- einfo "Generate secret token."
- einfo
- rm config/initializers/session_store.rb || die
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake generate_secret_token || die
- fi
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/secret_token.rb" ] ; then
- einfo
- einfo "Upgrade database."
- einfo
-
- einfo "Migrate database."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Upgrade the plugin migrations."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake redmine:plugins:migrate || die
- einfo "Clear the cache and the existing sessions."
- ${RUBY} -S rake tmp:cache:clear || die
- ${RUBY} -S rake tmp:sessions:clear || die
- else
- einfo
- einfo "Initialize database."
- einfo
-
- einfo "Generate a session store secret."
- ${RUBY} -S rake generate_secret_token || die
- einfo "Create the database structure."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Insert default configuration data in database."
- RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake redmine:load_default_data || die
- einfo
- einfo "If you use sqlite3. please do not forget to change the ownership of the sqlite files."
- einfo
- einfo "# cd \"${EPREFIX}${REDMINE_DIR}\""
- einfo "# chown redmine:redmine db/ db/*.sqlite3"
- einfo
- fi
-}
diff --git a/www-apps/redmine/redmine-2.2.0.ebuild b/www-apps/redmine/redmine-2.2.4.ebuild
index 7612b6e0cb4a..0be3f042fb00 100644
--- a/www-apps/redmine/redmine-2.2.0.ebuild
+++ b/www-apps/redmine/redmine-2.2.4.ebuild
@@ -1,12 +1,8 @@
# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/redmine-2.2.0.ebuild,v 1.1 2013/01/07 13:39:26 matsuu Exp $
+# $Header: /var/cvsroot/gentoo-x86/www-apps/redmine/redmine-2.2.4.ebuild,v 1.1 2013/05/11 21:29:22 pva Exp $
-EAPI="3"
-# ruby19: dev-ruby/rack has no ruby19
-# jruby: dev-ruby/rails has no jruby
-# rbx: dev-ruby/rails has no rbx
-#USE_RUBY="ruby18 ree18"
+EAPI="4"
USE_RUBY="ruby18 ruby19"
inherit eutils depend.apache ruby-ng
@@ -17,28 +13,33 @@ SRC_URI="mirror://rubyforge/${PN}/${P}.tar.gz"
KEYWORDS="~amd64 ~x86"
LICENSE="GPL-2"
SLOT="0"
-#IUSE="bazaar cvs darcs fastcgi git imagemagick mercurial mysql openid passenger postgres sqlite3 subversion"
-IUSE="fastcgi imagemagick ldap openid passenger"
+# All db-related USEs are ineffective since we depend on rails
+# which depends on activerecord which depends on all ruby's db bindings
+#IUSE="ldap openid imagemagick postgres sqlite mysql fastcgi passenger"
+IUSE="ldap openid imagemagick fastcgi passenger"
-#RDEPEND="$(ruby_implementation_depend ruby18 '>=' -1.8.6)[ssl]"
+#RDEPEND="$(ruby_implementation_depend jruby '>=' -1.6.7)[ssl]"
+RDEPEND="
+ ruby_targets_ruby18? (
+ >=dev-ruby/fastercsv-1.5[ruby_targets_ruby18]
+ )"
ruby_add_rdepend "virtual/ruby-ssl
virtual/rubygems
- >=dev-ruby/coderay-1.0.6
- dev-ruby/i18n:0.6
- dev-ruby/rake
- ~dev-ruby/rails-3.2.9:3.2
+ >=dev-ruby/rails-3.2.13:3.2
>=dev-ruby/jquery-rails-2.0.2
+ dev-ruby/i18n:0.6
+ >=dev-ruby/coderay-1.0.6
dev-ruby/builder:3
- fastcgi? ( dev-ruby/fcgi )
- imagemagick? ( >=dev-ruby/rmagick-2 )
+ dev-ruby/rake
ldap? ( >=dev-ruby/ruby-net-ldap-0.3.1 )
openid? (
>=dev-ruby/ruby-openid-2.1.4
>=dev-ruby/rack-openid-0.2.1
)
- passenger? ( www-apache/passenger )
- "
+ imagemagick? ( >=dev-ruby/rmagick-2 )
+ fastcgi? ( dev-ruby/fcgi )
+ passenger? ( www-apache/passenger )"
# ruby_targets_ruby18? (
# >=dev-ruby/fastercsv-1.5
# postgres? ( >=dev-ruby/pg-0.11 )
@@ -70,22 +71,13 @@ ruby_add_rdepend "virtual/ruby-ssl
# ruby_targets_jruby? (
# dev-ruby/test-unit
# )
-# >=dev-ruby/mocha-0.12.3
+# =dev-ruby/mocha-0.12*
# )"
-#RDEPEND="${RDEPEND}
-# bazaar ( dev-vcs/bazaar )
-# cvs? ( >=dev-vcs/cvs-1.12 )
-# darcs? ( dev-vcs/darcs )
-# git? ( dev-vcs/git )
-# mercurial? ( dev-vcs/mercurial )
-# subversion? ( >=dev-vcs/subversion-1.3 )"
-
REDMINE_DIR="/var/lib/${PN}"
pkg_setup() {
enewgroup redmine
- # home directory is required for SCM.
enewuser redmine -1 -1 "${REDMINE_DIR}" redmine
}
@@ -99,54 +91,57 @@ all_ruby_prepare() {
echo "CONFIG_PROTECT=\"${EPREFIX}${REDMINE_DIR}/config\"" > "${T}/50${PN}"
echo "CONFIG_PROTECT_MASK=\"${EPREFIX}${REDMINE_DIR}/config/locales ${EPREFIX}${REDMINE_DIR}/config/settings.yml\"" >> "${T}/50${PN}"
+
+ # remove openid module in case openid is disabled
+ use openid || rm -r lib/plugins/open_id_authentication || die
+ # remove ldap staff module to avoid #413779
+ use ldap || rm app/models/auth_source_ldap.rb || die
}
all_ruby_install() {
- dodoc doc/{CHANGELOG,INSTALL,README_FOR_APP,RUNNING_TESTS,UPGRADING} || die
+ dodoc doc/{CHANGELOG,INSTALL,README_FOR_APP,RUNNING_TESTS,UPGRADING}
rm -fr doc || die
- dodoc README.rdoc || die
+ dodoc README.rdoc
rm README.rdoc || die
- keepdir /var/log/${PN} || die
- dosym /var/log/${PN}/ "${REDMINE_DIR}/log" || die
+ keepdir /var/log/${PN}
+ dosym /var/log/${PN}/ "${REDMINE_DIR}/log"
insinto "${REDMINE_DIR}"
- doins -r . || die
- keepdir "${REDMINE_DIR}/files" || die
- keepdir "${REDMINE_DIR}/public/plugin_assets" || die
+ doins -r .
+ keepdir "${REDMINE_DIR}/files"
+ keepdir "${REDMINE_DIR}/public/plugin_assets"
fowners -R redmine:redmine \
"${REDMINE_DIR}/config" \
"${REDMINE_DIR}/files" \
"${REDMINE_DIR}/public/plugin_assets" \
"${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
- # for SCM
- fowners redmine:redmine "${REDMINE_DIR}" || die
- # bug #406605
+ /var/log/${PN}
+
+ fowners redmine:redmine "${REDMINE_DIR}"
+
+ # protect sensitive data, see bug #406605
fperms -R go-rwx \
"${REDMINE_DIR}/config" \
"${REDMINE_DIR}/files" \
"${REDMINE_DIR}/tmp" \
- /var/log/${PN} || die
+ /var/log/${PN}
- if use passenger ; then
+ if use passenger; then
has_apache
insinto "${APACHE_VHOSTS_CONFDIR}"
- doins "${FILESDIR}/10_redmine_vhost.conf" || die
+ doins "${FILESDIR}/10_redmine_vhost.conf"
else
- newconfd "${FILESDIR}/${PN}.confd" ${PN} || die
- newinitd "${FILESDIR}/${PN}-2.initd" ${PN} || die
- keepdir /var/run/${PN} || die
- fowners -R redmine:redmine /var/run/${PN} || die
- dosym /var/run/${PN}/ "${REDMINE_DIR}/tmp/pids" || die
+ newconfd "${FILESDIR}/${PN}.confd" ${PN}
+ newinitd "${FILESDIR}/${PN}-2.initd" ${PN}
fi
- doenvd "${T}/50${PN}" || die
+ doenvd "${T}/50${PN}"
}
pkg_postinst() {
einfo
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" -o -e "${EPREFIX}${REDMINE_DIR}/config/initializers/secret_token.rb" ] ; then
+ if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" -o -e "${EPREFIX}${REDMINE_DIR}/config/initializers/secret_token.rb" ]; then
elog "Execute the following command to upgrade environment:"
elog
elog "# emerge --config \"=${CATEGORY}/${PF}\""
@@ -169,47 +164,53 @@ pkg_postinst() {
}
pkg_config() {
- if [ ! -e "${EPREFIX}${REDMINE_DIR}/config/database.yml" ] ; then
- eerror "Copy ${EPREFIX}${REDMINE_DIR}/config/database.yml.example to ${EPREFIX}${REDMINE_DIR}/config/database.yml and edit this file in order to configure your database settings for \"production\" environment."
+ if [ ! -e "${EPREFIX}${REDMINE_DIR}/config/database.yml" ]; then
+ eerror "Copy ${EPREFIX}${REDMINE_DIR}/config/database.yml.example to ${EPREFIX}${REDMINE_DIR}/config/database.yml"
+ eerror "then edit this file in order to configure your database settings for \"production\" environment."
die
fi
local RAILS_ENV=${RAILS_ENV:-production}
- local RUBY=${RUBY:-ruby18}
+ if [ ! -L /usr/bin/ruby ]; then
+ eerror "/usr/bin/ruby is not a valid symlink to any ruby implementation."
+ eerror "Please update it via `eselect ruby`"
+ die
+ fi
+ local RUBY=${RUBY:-ruby}
- cd "${EPREFIX}${REDMINE_DIR}"
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ] ; then
+ cd "${EPREFIX}${REDMINE_DIR}" || die
+ if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/session_store.rb" ]; then
einfo
- einfo "Generate secret token."
+ einfo "Generating secret token."
einfo
rm config/initializers/session_store.rb || die
RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake generate_secret_token || die
fi
- if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/secret_token.rb" ] ; then
+ if [ -e "${EPREFIX}${REDMINE_DIR}/config/initializers/secret_token.rb" ]; then
einfo
- einfo "Upgrade database."
+ einfo "Upgrading database."
einfo
- einfo "Migrate database."
+ einfo "Migrating database."
RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Upgrade the plugin migrations."
+ einfo "Upgrading the plugin migrations."
RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake redmine:plugins:migrate || die
einfo "Clear the cache and the existing sessions."
${RUBY} -S rake tmp:cache:clear || die
${RUBY} -S rake tmp:sessions:clear || die
else
einfo
- einfo "Initialize database."
+ einfo "Initializing database."
einfo
- einfo "Generate a session store secret."
+ einfo "Generating a session store secret."
${RUBY} -S rake generate_secret_token || die
- einfo "Create the database structure."
+ einfo "Creating the database structure."
RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake db:migrate || die
- einfo "Insert default configuration data in database."
+ einfo "Populating database with default configuration dat."
RAILS_ENV="${RAILS_ENV}" ${RUBY} -S rake redmine:load_default_data || die
einfo
- einfo "If you use sqlite3. please do not forget to change the ownership of the sqlite files."
+ einfo "If you use sqlite3, please do not forget to change the ownership of the sqlite files."
einfo
einfo "# cd \"${EPREFIX}${REDMINE_DIR}\""
einfo "# chown redmine:redmine db/ db/*.sqlite3"