mirror of
https://git.tukaani.org/xz.git
synced 2024-04-04 12:36:23 +02:00
Use $(LN_EXEEXT) in symlinks to executables.
This fixes "make install" on operating systems using a suffix for executables. Cygwin is treated specially. The symlink names won't have .exe suffix even though the executables themselves have. Thanks to Charles Wilson.
This commit is contained in:
parent
18a4233a53
commit
221be761f4
2 changed files with 11 additions and 2 deletions
|
@ -44,6 +44,15 @@ case $host_os in
|
||||||
esac
|
esac
|
||||||
AM_CONDITIONAL([COND_W32], [test "$is_w32" = yes])
|
AM_CONDITIONAL([COND_W32], [test "$is_w32" = yes])
|
||||||
|
|
||||||
|
# We need to use $EXEEXT with $(LN_S) when creating symlinks to
|
||||||
|
# executables. Cygwin is an exception to this, since it is recommended
|
||||||
|
# that symlinks don't have the .exe suffix. To make this work, we
|
||||||
|
# define LN_EXEEXT.
|
||||||
|
case $host_os in
|
||||||
|
cygwin) LN_EXEEXT= ;;
|
||||||
|
*) LN_EXEEXT='$(EXEEXT)' ;;
|
||||||
|
esac
|
||||||
|
AC_SUBST([LN_EXEEXT])
|
||||||
|
|
||||||
echo
|
echo
|
||||||
echo "Configure options:"
|
echo "Configure options:"
|
||||||
|
|
|
@ -69,7 +69,7 @@ install-exec-hook:
|
||||||
cd $(DESTDIR)$(bindir) && \
|
cd $(DESTDIR)$(bindir) && \
|
||||||
target=`echo xz | sed '$(transform)'`$(EXEEXT) && \
|
target=`echo xz | sed '$(transform)'`$(EXEEXT) && \
|
||||||
for name in $(xzlinks); do \
|
for name in $(xzlinks); do \
|
||||||
link=`echo $$name | sed '$(transform)'` && \
|
link=`echo $$name | sed '$(transform)'`$(LN_EXEEXT) && \
|
||||||
rm -f $$link && \
|
rm -f $$link && \
|
||||||
$(LN_S) $$target $$link; \
|
$(LN_S) $$target $$link; \
|
||||||
done
|
done
|
||||||
|
@ -86,7 +86,7 @@ install-data-hook:
|
||||||
uninstall-hook:
|
uninstall-hook:
|
||||||
cd $(DESTDIR)$(bindir) && \
|
cd $(DESTDIR)$(bindir) && \
|
||||||
for name in $(xzlinks); do \
|
for name in $(xzlinks); do \
|
||||||
link=`echo $$name | sed '$(transform)'` && \
|
link=`echo $$name | sed '$(transform)'`$(LN_EXEEXT) && \
|
||||||
rm -f $$link; \
|
rm -f $$link; \
|
||||||
done
|
done
|
||||||
cd $(DESTDIR)$(mandir)/man1 && \
|
cd $(DESTDIR)$(mandir)/man1 && \
|
||||||
|
|
Loading…
Reference in a new issue