From 8bde269194876a25d0433283f3cc871bdbab5835 Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Mon, 9 Dec 2013 11:54:18 +0900 Subject: [PATCH] don't error out if /usr/share/pixmaps doesn't exist folder is missing on freebsd --- Makefile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 011f95be1..ecc2910bc 100644 --- a/Makefile +++ b/Makefile @@ -11,7 +11,8 @@ install: cp -av * ${DESTDIR}${PREFIX}/share/anki/ cd ${DESTDIR}${PREFIX}/share/anki && (\ mv runanki ${DESTDIR}${PREFIX}/local/bin/anki;\ - mv anki.xpm anki.png ${DESTDIR}${PREFIX}/share/pixmaps/;\ + test -d ${DESTDIR}${PREFIX}/share/pixmaps &&\ + mv anki.xpm anki.png ${DESTDIR}${PREFIX}/share/pixmaps/;\ mv anki.desktop ${DESTDIR}${PREFIX}/share/applications;\ mv anki.1 ${DESTDIR}${PREFIX}/share/man/man1/) xdg-mime install anki.xml --novendor @@ -23,7 +24,8 @@ install: uninstall: rm -rf ${DESTDIR}${PREFIX}/share/anki rm -rf ${DESTDIR}${PREFIX}/local/bin/anki - rm -rf ${DESTDIR}${PREFIX}/share/pixmaps/anki.{xpm,png} + rm -rf ${DESTDIR}${PREFIX}/share/pixmaps/anki.xpm + rm -rf ${DESTDIR}${PREFIX}/share/pixmaps/anki.png rm -rf ${DESTDIR}${PREFIX}/share/applications/anki.desktop rm -rf ${DESTDIR}${PREFIX}/share/man/man1/anki.1 -xdg-mime uninstall ${DESTDIR}${PREFIX}/share/mime/packages/anki.xml