OSEC

Neohapsis is currently accepting applications for employment. For more information, please visit our website www.neohapsis.com or email hr@neohapsis.com
Should PORTSDIR_PATH be overridden during creation of sqlports

From: Mikolaj Kucharski (mikolajkucharski.name)
Date: Mon May 06 2013 - 09:54:56 CDT


Hi,

I have custom PORTSDIR_PATH in /etc/mk.conf and that makes sqlports fail
doring build when it tries to visit non existing directories under
mystuff, which do exist under $PORTSDIR.

# grep -e ^PORTSDIR_PATH /etc/mk.conf
PORTSDIR_PATH = ${PORTSDIR}/mystuff:/home/users/build/mystuff:${PORTSDIR}

Do you think something like below could be applied to mksqlitedb and
probably to pkg_mklocatedb as well?

Comments?

Index: files/mksqlitedb
===================================================================
RCS file: /cvs/ports/databases/sqlports/files/mksqlitedb,v
retrieving revision 1.41
diff -u -p -u -r1.41 mksqlitedb
--- files/mksqlitedb 6 Jan 2013 21:20:58 -0000 1.41
+++ files/mksqlitedb 6 May 2013 14:42:54 -0000
-149,9 +149,10 sub dump_dirs
                         $ENV{'REPORT_PROBLEM_LOGFILE'}= $opt_p;
                 }
                 $ENV{'NO_IGNORE'} = 'Yes';
+ $ENV{'PORTSDIR'} = '/usr/ports' unless $ENV{'PORTSDIR'};
                 delete $ENV{'SUBPACKAGE'};
                 delete $ENV{'FLAVOR'};
- exec {'make'} ("make", "dump-vars");
+ exec {'make'} ("make", "PORTSDIR_PATH=$ENV{'PORTSDIR'}", "dump-vars");
                 die $!;
         }
 }

--
best regards
q#