Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #310. Add '-f' to 'rm' command in uninstall hooks to avoid error messages if files do not exist. #311

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion addshare/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ install-exec-hook: uninstall-hook
$(LN_S) $(libexecdir)/ksmbd.tools ksmbd.addshare )

uninstall-hook:
-rm $(DESTDIR)$(sbindir)/ksmbd.addshare
-rm -f "$(DESTDIR)$(sbindir)/ksmbd.addshare"
2 changes: 1 addition & 1 deletion adduser/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ install-exec-hook: uninstall-hook
$(LN_S) $(libexecdir)/ksmbd.tools ksmbd.adduser )

uninstall-hook:
-rm $(DESTDIR)$(sbindir)/ksmbd.adduser
-rm -f "$(DESTDIR)$(sbindir)/ksmbd.adduser"
15 changes: 15 additions & 0 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,21 @@ AC_PROG_SED
AC_PROG_MKDIR_P
AC_PROG_LN_S

# Check if PKG_CHECK_VAR exists for compatibility with older (pre-version 0.28) pkg-config
m4_ifndef([PKG_CHECK_VAR], [
# PKG_CHECK_VAR(VARIABLE, MODULE, CONFIG-VARIABLE,
# [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND])
# -------------------------------------------
# Retrieves the value of the pkg-config variable for the given module.
AC_DEFUN([PKG_CHECK_VAR],
[AC_REQUIRE([PKG_PROG_PKG_CONFIG])dnl
AC_ARG_VAR([$1], [value of $3 for $2, overriding pkg-config])dnl
_PKG_CONFIG([$1], [variable="][$3]["], [$2])
AS_VAR_COPY([$1], [pkg_cv_][$1])
AS_VAR_IF([$1], [""], [$5], [$4])dnl
])# PKG_CHECK_VAR
])

AC_SUBST([in_script], [[\
'$(SED) -e "s,[@]sbindir[@],$(sbindir),g" \
-e "s,[@]sysconfdir[@],$(sysconfdir),g" \
Expand Down
2 changes: 1 addition & 1 deletion control/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ install-exec-hook: uninstall-hook
$(LN_S) $(libexecdir)/ksmbd.tools ksmbd.control )

uninstall-hook:
-rm $(DESTDIR)$(sbindir)/ksmbd.control
-rm -f "$(DESTDIR)$(sbindir)/ksmbd.control"
2 changes: 1 addition & 1 deletion mountd/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ install-exec-hook: uninstall-hook
$(LN_S) $(libexecdir)/ksmbd.tools ksmbd.mountd )

uninstall-hook:
-rm $(DESTDIR)$(sbindir)/ksmbd.mountd
-rm -f "$(DESTDIR)$(sbindir)/ksmbd.mountd"