#!/bin/sh
sqlite3 "$REPOCOP_TEST_TMPDIR/tmp.db" <<EOSQL
attach database '$REPOCOP_TEST_DBDIR/rpm.db' as rpm;
.mode tabs
.output $REPOCOP_TEST_TMPDIR/msg
-- filemode & 64 = 0 -- executable
select distinct pkgid from rpm_files where filemode & 7 =0 and filemode & 64 = 0 and substr(filename,1,11)='/usr/share/';
EOSQL
for i in `cat $REPOCOP_TEST_TMPDIR/msg`; do repocop-test-info -k $i "Files below <tt>/usr/share</tt> not readable by others look like configuration files. They should be labelled as %config and placed in /etc because
 <tt>/usr/</tt> might be mounted read-only and thus, the local system
 administrator would not have a chance to modify this file.
"; done
rm $REPOCOP_TEST_TMPDIR/*
