Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-18 Thread Michał Górny
On Mon, 18 Oct 2010 14:06:26 -0400 Mike Frysinger wrote: > On Monday, October 18, 2010 03:08:15 Michał Górny wrote: > > On Wed, 13 Oct 2010 17:46:43 -0400 Mike Frysinger wrote: > > > On Wednesday, October 13, 2010 15:57:17 Amadeusz Żołnowski wrote: > > > > And why putting different tasks into one

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-18 Thread Mike Frysinger
On Monday, October 18, 2010 14:06:26 Mike Frysinger wrote: > On Monday, October 18, 2010 03:08:15 Michał Górny wrote: > > On Wed, 13 Oct 2010 17:46:43 -0400 Mike Frysinger wrote: > > > On Wednesday, October 13, 2010 15:57:17 Amadeusz Żołnowski wrote: > > > > And why putting different tasks into one

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-18 Thread Mike Frysinger
On Monday, October 18, 2010 03:08:15 Michał Górny wrote: > On Wed, 13 Oct 2010 17:46:43 -0400 Mike Frysinger wrote: > > On Wednesday, October 13, 2010 15:57:17 Amadeusz Żołnowski wrote: > > > And why putting different tasks into one function? > > > > for the same reason we dont have separate test

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-18 Thread Michał Górny
On Wed, 13 Oct 2010 17:46:43 -0400 Mike Frysinger wrote: > On Wednesday, October 13, 2010 15:57:17 Amadeusz Żołnowski wrote: > > And why putting different tasks into one function? > > for the same reason we dont have separate test binaries: test_exist, > test_file, test_dir, etc... > > it make

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-17 Thread Amadeusz Żołnowski
Excerpts from Mike Frysinger's message of Sun Oct 17 23:33:57 +0200 2010: > On Wednesday, October 13, 2010 19:08:55 Amadeusz Żołnowski wrote: > > Excerpts from Mike Frysinger's message of Thu Oct 14 00:32:40 +0200 2010: > > > On Wednesday, October 13, 2010 18:13:18 Amadeusz Żołnowski wrote: > > > >

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-17 Thread Mike Frysinger
On Tuesday, October 12, 2010 16:09:06 Dirkjan Ochtman wrote: > On Fri, Oct 1, 2010 at 15:07, Peter Volkov wrote: > >> if [[ -n $(ls /etc/openvpn/*/local.conf 2>/dev/null) ]] ; then > > > > I'd suggested [ -e /etc/openvpn/*/local.conf ] here, but probably there > > are better alternatives. A

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-17 Thread Mike Frysinger
On Wednesday, October 13, 2010 19:08:55 Amadeusz Żołnowski wrote: > Excerpts from Mike Frysinger's message of Thu Oct 14 00:32:40 +0200 2010: > > On Wednesday, October 13, 2010 18:13:18 Amadeusz Żołnowski wrote: > > > Mike Frysinger's message of Wed Oct 13 23:46:43 +0200 2010: > > > > On Wednesday,

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Amadeusz Żołnowski
Excerpts from Mike Frysinger's message of Thu Oct 14 00:32:40 +0200 2010: > On Wednesday, October 13, 2010 18:13:18 Amadeusz Żołnowski wrote: > > Excerpts from Mike Frysinger's message of Wed Oct 13 23:46:43 +0200 2010: > > > On Wednesday, October 13, 2010 15:57:17 Amadeusz Żołnowski wrote: > > > >

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Mike Frysinger
On Wednesday, October 13, 2010 18:13:18 Amadeusz Żołnowski wrote: > Excerpts from Mike Frysinger's message of Wed Oct 13 23:46:43 +0200 2010: > > On Wednesday, October 13, 2010 15:57:17 Amadeusz Żołnowski wrote: > > > And why putting different tasks into one function? > > > > for the same reason w

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Amadeusz Żołnowski
Excerpts from Mike Frysinger's message of Wed Oct 13 23:46:43 +0200 2010: > On Wednesday, October 13, 2010 15:57:17 Amadeusz Żołnowski wrote: > > And why putting different tasks into one function? > > for the same reason we dont have separate test binaries: test_exist, > test_file, test_dir, etc.

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Mike Frysinger
On Wednesday, October 13, 2010 15:57:17 Amadeusz Żołnowski wrote: > And why putting different tasks into one function? for the same reason we dont have separate test binaries: test_exist, test_file, test_dir, etc... it makes more sense in my mind to combine the functionality. -mike signature.a

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Mike Frysinger
On Wednesday, October 13, 2010 15:37:02 Ulrich Mueller wrote: > > On Wed, 13 Oct 2010, Mike Frysinger wrote: > > # If no paths are specified, then the return value is "false". > > For the "or" case that's fine. But for the "and" case, I would expect > that the function returns true if called w

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Amadeusz Żołnowski
Excerpts from Amadeusz Żołnowski's message of Wed Oct 13 21:20:01 +0200 2010: > Excerpts from Mike Frysinger's message of Wed Oct 13 20:51:35 +0200 2010: > > path_exists() { > > local opt=$1 > > [[ ${opt} == -[ao] ]] && shift || opt="-a" > > > > # no paths -> return false > > # sam

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Ulrich Mueller
> On Wed, 13 Oct 2010, Mike Frysinger wrote: > # If no paths are specified, then the return value is "false". For the "or" case that's fine. But for the "and" case, I would expect that the function returns true if called with no arguments. Ulrich

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Amadeusz Żołnowski
Excerpts from Mike Frysinger's message of Wed Oct 13 20:51:35 +0200 2010: > path_exists() { > local opt=$1 > [[ ${opt} == -[ao] ]] && shift || opt="-a" > > # no paths -> return false > # same behavior as: [[ -e "" ]] > [[ $# -eq 0 ]] && return 1 > > local p r=0 > for p

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Mike Frysinger
here's what i'll commit to eutils.eclass: # @FUNCTION: path_exists # @USAGE: [-a|-o] # @DESCRIPTION: # Check if the specified paths exist. Works for all types of paths # (files/dirs/etc...). The -a and -o flags control the requirements # of the paths. They correspond to "and" and "or" logic.

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Mike Frysinger
On Wednesday, October 13, 2010 12:35:20 Vaeth wrote: > Mike Frysinger wrote: > > relying on an external program > > The point is that external programs can have all sorts of undesired > side effects. For instance, if an directory is not readable (or > readable but not executable or is on $FILESYST

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Mike Frysinger
On Wednesday, October 13, 2010 13:26:24 Michał Górny wrote: > On Wed, 13 Oct 2010 18:51:31 +0200 Amadeusz Żołnowski wrote: > > > has_file()? > > > > What it would mean? „Has”? > > It's reference to has() function specified by PMS. 'The file system has > a file named one-of $...@}' :P. the has fu

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Michał Górny
On Wed, 13 Oct 2010 18:51:31 +0200 Amadeusz Żołnowski wrote: > > has_file()? > > What it would mean? „Has”? It's reference to has() function specified by PMS. 'The file system has a file named one-of $...@}' :P. -- Best regards, Michał Górny signature.asc Description: PGP signature

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Amadeusz Żołnowski
Excerpts from Michał Górny's message of Wed Oct 13 18:41:54 +0200 2010: > On Wed, 13 Oct 2010 10:13:58 -0400 > Mike Frysinger wrote: > > > > any_exists() { > > > local f > > > > > > for f; do > > > [[ -e $f ]] && return 0 > > > done > > > > > > return 1 > > > } > > > >

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Michał Górny
On Wed, 13 Oct 2010 10:13:58 -0400 Mike Frysinger wrote: > > any_exists() { > > local f > > > > for f; do > > [[ -e $f ]] && return 0 > > done > > > > return 1 > > } > > perhaps if it had a better name and were in a common location (eclass) has_file()? -- Best regard

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Amadeusz Żołnowski
Excerpts from Mike Frysinger's message of Wed Oct 13 16:13:58 +0200 2010: > On Wednesday, October 13, 2010 04:23:16 Amadeusz Żołnowski wrote: > > Excerpts from Mike Frysinger's message of Tue Oct 12 22:57:11 +0200 2010: > > > On Tuesday, October 12, 2010 16:26:31 Jeroen Roovers wrote: > > > > On Tu

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Vaeth
Mike Frysinger wrote: > relying on an external program The point is that external programs can have all sorts of undesired side effects. For instance, if an directory is not readable (or readable but not executable or is on $FILESYSTEM with who-knows-what permissions or accessability problems) it

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Mike Frysinger
On Wednesday, October 13, 2010 03:08:24 Vaeth wrote: > Mike Frysinger wrote: > > > for foo in ${ROOT}/etc/openvpn/*/local.conf; do > > > > > > [ -e ${foo} ] && bar ${foo} > > > > > > done > > > > i'd say doing a loop is worse than a `ls` hack. > > Why do you think so? No external program on w

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Mike Frysinger
On Wednesday, October 13, 2010 04:23:16 Amadeusz Żołnowski wrote: > Excerpts from Mike Frysinger's message of Tue Oct 12 22:57:11 +0200 2010: > > On Tuesday, October 12, 2010 16:26:31 Jeroen Roovers wrote: > > > On Tue, 12 Oct 2010 22:09:06 +0200 Dirkjan Ochtman wrote: > > > > On Fri, Oct 1, 2010 a

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Amadeusz Żołnowski
Excerpts from Mike Frysinger's message of Tue Oct 12 22:57:11 +0200 2010: > On Tuesday, October 12, 2010 16:26:31 Jeroen Roovers wrote: > > On Tue, 12 Oct 2010 22:09:06 +0200 Dirkjan Ochtman wrote: > > > On Fri, Oct 1, 2010 at 15:07, Peter Volkov wrote: > > > > [a very thorough review of the openvp

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-13 Thread Vaeth
Mike Frysinger wrote: > > for foo in ${ROOT}/etc/openvpn/*/local.conf; do > > [ -e ${foo} ] && bar ${foo} > > done > > i'd say doing a loop is worse than a `ls` hack. Why do you think so? No external program on which you must rely, and if you put a "break" in there, the loop is just syntacti

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-12 Thread Mike Frysinger
On Tuesday, October 12, 2010 16:26:31 Jeroen Roovers wrote: > On Tue, 12 Oct 2010 22:09:06 +0200 Dirkjan Ochtman wrote: > > On Fri, Oct 1, 2010 at 15:07, Peter Volkov wrote: > > > [a very thorough review of the openvpn ebuild] > > > > Thanks for reviewing, I've fixed most of the issues. > > > > >

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-12 Thread Jeroen Roovers
On Tue, 12 Oct 2010 22:09:06 +0200 Dirkjan Ochtman wrote: > On Fri, Oct 1, 2010 at 15:07, Peter Volkov wrote: > > [a very thorough review of the openvpn ebuild] > > Thanks for reviewing, I've fixed most of the issues. > > >> if [[ -n $(ls /etc/openvpn/*/local.conf 2>/dev/null) ]] ; > >>

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-12 Thread Mike Frysinger
On Tuesday, October 12, 2010 16:09:06 Dirkjan Ochtman wrote: > On Fri, Oct 1, 2010 at 15:07, Peter Volkov wrote: > >> if [[ -n $(ls /etc/openvpn/*/local.conf 2>/dev/null) ]] ; then > > > > I'd suggested [ -e /etc/openvpn/*/local.conf ] here, but probably there > > are better alternatives. Al

[gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-12 Thread Dirkjan Ochtman
On Fri, Oct 1, 2010 at 15:07, Peter Volkov wrote: > [a very thorough review of the openvpn ebuild] Thanks for reviewing, I've fixed most of the issues. >> if [[ -n $(ls /etc/openvpn/*/local.conf 2>/dev/null) ]] ; then > > I'd suggested [ -e /etc/openvpn/*/local.conf ] here, but probably th

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-04 Thread Jeroen Roovers
On Fri, 1 Oct 2010 20:47:38 +0530 Nirbheek Chauhan wrote: > >>               for i in $( ls 2>/dev/null ); do [...] > A nice way around this is to do the following: > > ls -1 | while read i; do What pva carelessly omitted to point out was that using ls(1) is incredibly bad bash programmin

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-02 Thread Nirbheek Chauhan
On Sat, Oct 2, 2010 at 9:08 AM, Ryan Hill wrote: > On Fri, 1 Oct 2010 20:47:38 +0530 > Nirbheek Chauhan wrote: >> >> A nice way around this is to do the following: >> >>     ls -1 | while read i; do >> >> `read` delimits on newline, so you're safe. > > This strips leading and trailing whitespace.

[gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-01 Thread Ryan Hill
On Fri, 1 Oct 2010 20:47:38 +0530 Nirbheek Chauhan wrote: > On Fri, Oct 1, 2010 at 6:37 PM, Peter Volkov wrote: > > В Пнд, 27/09/2010 в 11:37 +, Dirkjan Ochtman (djc) пишет: > >> src_compile() { > >>       use static && sed -i -e '/^LIBS/s/LIBS = /LIBS = -static /' Makefile > >> > >>       e

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-01 Thread Nirbheek Chauhan
On Fri, Oct 1, 2010 at 6:37 PM, Peter Volkov wrote: > В Пнд, 27/09/2010 в 11:37 +, Dirkjan Ochtman (djc) пишет: >> src_compile() { >>       use static && sed -i -e '/^LIBS/s/LIBS = /LIBS = -static /' Makefile >> >>       emake || die "make failed" >> >>       if ! use minimal ; then >>        

Re: [gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-01 Thread Thomas Sachau
Am 01.10.2010 15:07, schrieb Peter Volkov: > В Пнд, 27/09/2010 в 11:37 +, Dirkjan Ochtman (djc) пишет: > >> [[ ${i} == "README" || ${i} == "examples" || ${i} == >> "defer" ]] && continue >> [[ ${i} == "auth-pam" ]] && ! use pam && continue >>

[gentoo-dev] Re: [gentoo-commits] gentoo-x86 commit in net-misc/openvpn: ChangeLog openvpn-2.1.3.ebuild

2010-10-01 Thread Peter Volkov
В Пнд, 27/09/2010 в 11:37 +, Dirkjan Ochtman (djc) пишет: > src_prepare() { > epatch "${FILESDIR}/${PN}-2.1_rc13-peercred.patch" > epatch "${FILESDIR}/${PN}-2.1_rc20-pkcs11.patch" > use ipv6 && epatch "${WORKDIR}/${PN}-2.1.1-ipv6-${IPV6_VERSION}.patch" > use eurephia &&