diff --git a/Makefile.am b/Makefile.am index 73e8116..67ef283 100644 --- a/Makefile.am +++ b/Makefile.am @@ -71,7 +71,7 @@ install-data-hook: if test -d "$(DESTDIR)@includedir@/json" ; then \ (cd "$(DESTDIR)@includedir@/json" && \ rm -f $(libjson_cinclude_HEADERS)) ; \ - rmdir "$(DESTDIR)@includedir@/json" ; \ + test -L "$(DESTDIR)@includedir@/json" || rmdir "$(DESTDIR)@includedir@/json" ; \ fi test \! -e "$(DESTDIR)@includedir@/json" || rm "$(DESTDIR)@includedir@/json" $(LN_S) json-c "$(DESTDIR)@includedir@/json"