2 # Copyright (c) 2007-2012 Zmanda, Inc. All Rights Reserved.
4 # This program is free software; you can redistribute it and/or
5 # modify it under the terms of the GNU General Public License
6 # as published by the Free Software Foundation; either version 2
7 # of the License, or (at your option) any later version.
9 # This program is distributed in the hope that it will be useful, but
10 # WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
11 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 # You should have received a copy of the GNU General Public License along
15 # with this program; if not, write to the Free Software Foundation, Inc.,
16 # 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18 # Contact information: Zmanda Inc, 465 S. Mathilda Ave., Suite 300
19 # Sunnyvale, CA 94086, USA, or: http://www.zmanda.com
21 package Amanda::Paths;
25 Amanda::Paths - perl access to build-time configuration paths
31 my $filename = "$amlibexecdir/foo/bar";
33 This package is a means of getting all of the necessary variables provided
34 by configure into Perl scripts, without a bunch of boilerplate, and without
35 requiring config.status substitution for every .pm file.
37 All of the variables in @EXPORT will be automatically imported into
38 your module's namespace. See the source, rather than the perldoc,
39 to find out what variables are available.
44 @ISA = qw( Exporter );
63 $GNUTAR_LISTED_INCREMENTAL_DIR
66 # the 'warnings' pragma doesn't recognized exported variables as "used", and generates warnings
67 # for variables only used once. We turn it off for this module.
70 ## basic filesystem layout
72 # these need to go in order, due to the way autoconf sets these dirs up
74 $exec_prefix = "@exec_prefix@";
76 $sbindir = "@sbindir@";
77 $libexecdir = "@libexecdir@";
78 $amlibexecdir = "@amlibexecdir@";
80 # (config.status worries if it doesn't see this:)
81 $datarootdir = "@datarootdir@";
82 $sysconfdir = "@sysconfdir@";
83 $amdatadir = "@amdatadir@";
84 $localstatedir = "@localstatedir@";
86 ## amanda configuration directories
88 $AMANDA_TMPDIR = "@AMANDA_TMPDIR@";
89 $CONFIG_DIR = "@CONFIG_DIR@";
90 $AMANDA_DBGDIR = "@AMANDA_DBGDIR@";
91 $APPLICATION_DIR = "@APPLICATION_DIR@";
92 $GNUTAR_LISTED_INCREMENTAL_DIR = "@GNUTAR_LISTED_INCREMENTAL_DIR@";