diff options
author | mbligh <mbligh@592f7852-d20e-0410-864c-8624ca9c26a4> | 2008-02-20 16:09:08 +0000 |
---|---|---|
committer | mbligh <mbligh@592f7852-d20e-0410-864c-8624ca9c26a4> | 2008-02-20 16:09:08 +0000 |
commit | eacc6d3b8699d0fd0cb68269bedbd846cd9e34a4 (patch) | |
tree | dd5a433d8df82e1c688a26f5af802756d01bfa79 /conmux | |
parent | 4adaec7440e3707b336e1989e92d95dfda88946f (diff) |
Remove hard coded path of /usr/local/conmux and replace it with FindBin module
Clean up old commented out code that was trying to do this before
Signed-off-by: Scott Zawalski <scottz@google.com>
git-svn-id: svn://test.kernel.org/autotest/trunk@1253 592f7852-d20e-0410-864c-8624ca9c26a4
Diffstat (limited to 'conmux')
-rwxr-xr-x | conmux/conmux | 9 | ||||
-rwxr-xr-x | conmux/conmux-attach | 8 | ||||
-rwxr-xr-x | conmux/conmux-registry | 8 | ||||
-rwxr-xr-x | conmux/console | 10 |
4 files changed, 9 insertions, 26 deletions
diff --git a/conmux/conmux b/conmux/conmux index 14f763ec..63534b03 100755 --- a/conmux/conmux +++ b/conmux/conmux @@ -13,8 +13,8 @@ # use strict; +use FindBin; use Symbol qw(gensym); - use IO::Socket; use IO::Multiplex; use IPC::Open3; @@ -22,12 +22,7 @@ use URI::Escape; use Net::Domain; # Find our internal libraries. -###my $lib = $0; $lib =~ s@/[^/]+$@@; -###push(@INC, $lib); -###require Conmux; -##use lib "."; -##use Conmux; -use lib "/usr/local/conmux/lib"; +use lib $FindBin::Bin; use Conmux; our $P = 'conmux'; diff --git a/conmux/conmux-attach b/conmux/conmux-attach index 84cf2290..695d9ff8 100755 --- a/conmux/conmux-attach +++ b/conmux/conmux-attach @@ -12,16 +12,12 @@ # # The Console Multiplexor is released under the GNU Public License V2 # +use FindBin; use IO::Socket; use Getopt::Long qw(:config no_auto_abbrev); # Find our internal libraries. -###my $lib = $0; $lib =~ s@/[^/]+$@@; -###push(@INC, $lib); -###require Conmux; -##use lib "."; -##use Conmux; -use lib "/usr/local/conmux/lib"; +use lib $FindBin::Bin; use Conmux; my $P = 'conmux-attach'; diff --git a/conmux/conmux-registry b/conmux/conmux-registry index 7a4e0bfc..1f7a4171 100755 --- a/conmux/conmux-registry +++ b/conmux/conmux-registry @@ -13,6 +13,7 @@ # use strict; +use FindBin; use Symbol qw(gensym); use IO::Socket; @@ -20,12 +21,7 @@ use IO::Multiplex; use URI::Escape; # Find our internal libraries. -###my $lib = $0; $lib =~ s@/[^/]+$@@; -###push(@INC, $lib); -###require Conmux; -##use lib "."; -##use Conmux; -use lib "/usr/local/conmux/lib"; +use lib $FindBin::Bin; use Conmux; our $P = 'conmux-registry'; diff --git a/conmux/console b/conmux/console index 95539484..0ab1ad7f 100755 --- a/conmux/console +++ b/conmux/console @@ -16,20 +16,16 @@ $| = 1; our $P = 'console'; +use FindBin; use POSIX qw(errno_h BUFSIZ); use IO::Socket; use Getopt::Long qw(:config no_auto_abbrev); -my $CONMUX = '/usr/local/conmux'; +my $CONMUX = $FindBin::Bin; my $CONMUX = $ENV{'CONMUX_ROOT'} if ($ENV{'CONMUX_ROOT'}); # Find our internal libraries. -###my $lib = $0; $lib =~ s@/[^/]+$@@; -###push(@INC, $lib); -###require Conmux; -##use lib "."; -##use Conmux; -use lib "/usr/local/conmux/lib"; +use lib $FindBin::Bin; use Conmux; # Basic terminal handling. |