tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

postinstall check fontconfig

Hi List

For quite some time now, postinstall keeps on failing fontconfig check because I don't have X11 installed on this headless box. This patch now passes populate_dir if the target directory does not exist which solves me problem. I don't know if what the intent of the function is if the directory does not exist or not, hence me asking the peanut gallery here.


Index: postinstall
RCS file: /cvsroot/src/usr.sbin/postinstall/postinstall,v
retrieving revision 1.164
diff -u -p -r1.164 postinstall
--- postinstall 15 Feb 2014 01:54:17 -0000      1.164
+++ postinstall 21 Feb 2014 10:09:36 -0000
@@ -248,6 +248,10 @@ populate_dir()
        shift 5
+       if [ ! -e "${_src}" ]; then
+               msg "${_src} does not exist; skipping check"
+               return 0
+       fi
        if [ ! -d "${_src}" ]; then
                msg "${_src} is not a directory; skipping check"
                return 1

Home | Main Index | Thread Index | Old Index