[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Handle -o w/ and w/o $EXEEXT during manifest embedding
From: |
Peter Rosin |
Subject: |
Handle -o w/ and w/o $EXEEXT during manifest embedding |
Date: |
Sat, 30 Aug 2008 22:26:45 +0200 |
User-agent: |
Thunderbird 2.0.0.16 (Windows/20080708) |
Hi!
During my exercise with libsndfile I found a problem with
the manifest embedding code. $output may or may not contain
the trailing $EXEEXT, so the code in $postlink_cmds has
to handle both cases (or some c14n has to be added to ltmain).
So, here is a patch to address that. Ok to push to the
pr-msvc-support branch?
Cheers,
Peter
2008-08-30 Peter Rosin <address@hidden>
* libltdl/m4/libtool.m4 (_LT_LINKER_SHLIBS)
[ cygwin, mingw, cegcc ] <cl*>: @OUTPUT@ may or may not
include a trailing $EXEEXT. If mt fails, make sure libtool
exits with an error.
(_LT_LANG_CXX_CONFIG): Likewise.
diff --git a/libltdl/m4/libtool.m4 b/libltdl/m4/libtool.m4
index a8f20f0..3e667b2 100644
--- a/libltdl/m4/libtool.m4
+++ b/libltdl/m4/libtool.m4
@@ -4824,9 +4824,14 @@ _LT_EOF
_LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
_LT_TAGVAR(compile_tag, $1)=-TC
_LT_TAGVAR(dashl_xform, $1)='s/\(.*\)/\1.lib/'
- _LT_TAGVAR(postlink_cmds, $1)='if test -e "@address@hidden"; then
- mt -manifest "@address@hidden" -outputresource:"@address@hidden";
- $RM "@address@hidden";
+ _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
+ case "$lt_outputfile" in
+ *.[eE][xX][eE]) ;;
+ *) lt_outputfile="$lt_outputfile.exe" ;;
+ esac~
+ if test -e "$lt_outputfile.manifest"; then
+ mt -manifest "$lt_outputfile.manifest"
-outputresource:"$lt_outputfile" || exit 1;
+ $RM "$lt_outputfile.manifest";
fi'
;;
*)
@@ -5821,9 +5826,14 @@ if test "$_lt_caught_CXX_error" != yes; then
_LT_TAGVAR(old_postinstall_cmds, $1)='chmod 644 $oldlib'
_LT_TAGVAR(compile_tag, $1)=-TP
_LT_TAGVAR(dashl_xform, $1)='s/\(.*\)/\1.lib/'
- _LT_TAGVAR(postlink_cmds, $1)='if test -e "@address@hidden"; then
- mt -manifest "@address@hidden" -outputresource:"@address@hidden";
- $RM "@address@hidden";
+ _LT_TAGVAR(postlink_cmds, $1)='lt_outputfile="@OUTPUT@"~
+ case "$lt_outputfile" in
+ *.[eE][xX][eE]) ;;
+ *) lt_outputfile="$lt_outputfile.exe" ;;
+ esac~
+ if test -e "$lt_outputfile.manifest"; then
+ mt -manifest "$lt_outputfile.manifest"
-outputresource:"$lt_outputfile" || exit 1;
+ $RM "$lt_outputfile.manifest";
fi'
;;
*)
- Handle -o w/ and w/o $EXEEXT during manifest embedding,
Peter Rosin <=