| 1 | ## no critic qw(ProhibitUselessNoCritic PodSpelling ProhibitExcessMainComplexity) # DEVELOPER DEFAULT 1a: allow unreachable & POD-commented code, must be on line 1; SYSTEM SPECIAL 4: allow complex code outside subroutines, must be on line 1 | ||
| 2 | |||
| 3 | package MLPerl::Config; | ||
| 4 | use strict; | ||
| 5 | use warnings; | ||
| 6 | our $VERSION = 0.002_000; | ||
| 7 | our $IS_RPERL_CONFIG = 1; # DEV NOTE, CORRELATION #rp027: RPerl::Config, MLPerl::Config, PhysicsPerl::Config, etc | ||
| 8 | |||
| 9 | ## no critic qw(ProhibitUselessNoCritic ProhibitMagicNumbers RequireCheckedSyscalls) # USER DEFAULT 1: allow numeric values & print operator | ||
| 10 | ## no critic qw(RequireInterpolationOfMetachars) # USER DEFAULT 2: allow single-quoted control characters & sigils | ||
| 11 | ## no critic qw(Capitalization ProhibitMultiplePackages ProhibitReusedNames) # SYSTEM DEFAULT 3: allow multiple & lower case package names | ||
| 12 | |||
| 13 | # DEV NOTE: this package exists to serve as the header file for MLPerl.pm itself | ||
| 14 | |||
| 15 | package MLPerl; | ||
| 16 | |||
| 17 | # [[[ INCLUDES ]]] | ||
| 18 | use RPerl::Config; | ||
| 19 | |||
| 20 | # [[[ OO CLASS PROPERTIES SPECIAL ]]] | ||
| 21 | our $BASE_PATH = undef; # all target software lives below here | ||
| 22 | our $INCLUDE_PATH = undef; # all target system modules live here | ||
| 23 | our $SCRIPT_PATH = undef; # interpreted target system programs live here | ||
| 24 | |||
| 25 | # [[[ OPERATIONS SPECIAL ]]] | ||
| 26 | |||
| 27 | # set system paths | ||
| 28 | my $file_name_config = 'MLPerl/Config.pm'; # this file name | ||
| 29 | my $package_name_config = 'MLPerl::Config'; # this file's primary package name | ||
| 30 | my $file_name_pm = 'MLPerl.pm'; | ||
| 31 | my $file_name_script = 'mlperl'; | ||
| 32 | ( $BASE_PATH, $INCLUDE_PATH, $SCRIPT_PATH ) = @{ RPerl::set_system_paths( $file_name_config, $package_name_config, $file_name_pm, $file_name_script ) }; | ||
| 33 | |||
| 34 | 1; # end of package | ||
| 35 | |||
| 36 | |||
| 37 | # export system paths to main:: namespace for use by PMC files | ||
| 38 | package main; | ||
| 39 | |||
| 40 | # [[[ OO CLASS PROPERTIES SPECIAL ]]] | ||
| 41 | # DEV NOTE: duplicate lines to avoid 'used only once' warnings | ||
| 42 | our $BASE_PATH = $MLPerl::BASE_PATH; | ||
| 43 | $BASE_PATH = $MLPerl::BASE_PATH; | ||
| 44 | our $INCLUDE_PATH = $MLPerl::INCLUDE_PATH; | ||
| 45 | $INCLUDE_PATH = $MLPerl::INCLUDE_PATH; | ||
| 46 | our $SCRIPT_PATH = $MLPerl::SCRIPT_PATH; | ||
| 47 | $SCRIPT_PATH = $MLPerl::SCRIPT_PATH; | ||
| 48 | |||
| 49 | 1; # end of package |