Hi,
As i'm working on portgen(1) and remembered Pamela's manpage diff, i've
found out that sqlports-compact is mentioned, and its presence still
checked. I'm proposing to remove those bits.
It has been successfully tried in a chroot without sqlports installed,
and the runtime is as expected on installed.
Comments/feedback are welcome,
Charlène.
Index: Utils.pm
===================================================================
RCS file: /cvs/ports/infrastructure/lib/OpenBSD/PortGen/Utils.pm,v
retrieving revision 1.3
diff -u -p -r1.3 Utils.pm
--- Utils.pm 11 May 2019 15:09:06 -0000 1.3
+++ Utils.pm 18 Nov 2019 12:15:45 -0000
@@ -58,22 +58,16 @@ sub module_in_ports
my $dbpath = '/usr/local/share';
my $dbfile;
- if ( -e "$dbpath/sqlports-compact" ) {
- $dbfile = 'sqlports-compact';
- } elsif ( -e "$dbpath/sqlports" ) {
+ if ( -e "$dbpath/sqlports" ) {
$dbfile = 'sqlports';
} else {
- die "install databases/sqlports-compact or databases/sqlports";
+ die "install databases/sqlports";
}
my $dbh = DBI->connect( "dbi:SQLite:dbname=$dbpath/$dbfile", "", "" )
or die "failed to connect to database: $DBI::errstr";
- my $stmt;
- $stmt =
- $dbfile =~ /compact/
- ? "SELECT FULLPKGPATH FROM Paths WHERE ID IN ( SELECT FULLPKGPATH
FROM Ports WHERE DISTNAME LIKE '$module%' )"
- : "SELECT FULLPKGPATH FROM Ports WHERE DISTNAME LIKE '$module%'";
+ my $stmt = "SELECT FULLPKGPATH FROM Ports WHERE DISTNAME LIKE
'$module%'";
my $pr = $dbh->prepare($stmt);
$pr->execute();