[4/5] docs: Explain how to regenerate import libraries with MSVC tools

Message ID 1310113274-11262-4-git-send-email-martin@martin.st
State Committed
Headers show

Commit Message

Martin Storsjö July 8, 2011, 8:21 a.m.
---
 doc/general.texi |   28 ++++++++++++++++++++++++++++
 1 files changed, 28 insertions(+), 0 deletions(-)

Comments

Diego Biurrun July 8, 2011, 10:13 a.m. | #1
On Fri, Jul 08, 2011 at 11:21:13AM +0300, Martin Storsjö wrote:
> ---
>  doc/general.texi |   28 ++++++++++++++++++++++++++++
>  1 files changed, 28 insertions(+), 0 deletions(-)
> 
> diff --git a/doc/general.texi b/doc/general.texi
> index 81fa014..41ab778 100644
> --- a/doc/general.texi
> +++ b/doc/general.texi
> @@ -970,6 +970,34 @@ required when using import libraries generated by lib.exe.
>  This issue is reported upstream at
>  @url{http://sourceware.org/bugzilla/show_bug.cgi?id=12633}.
>  
> +To create import libraries that work with the /OPT:REF option

@code{/OPT:REF}

Push with that changed.

Diego

Patch

diff --git a/doc/general.texi b/doc/general.texi
index 81fa014..41ab778 100644
--- a/doc/general.texi
+++ b/doc/general.texi
@@ -970,6 +970,34 @@  required when using import libraries generated by lib.exe.
 This issue is reported upstream at
 @url{http://sourceware.org/bugzilla/show_bug.cgi?id=12633}.
 
+To create import libraries that work with the /OPT:REF option
+(which is enabled by default in Release mode), follow these steps:
+
+@enumerate
+
+@item Open @file{Visual Studio 2005 Command Prompt}.
+
+Alternatively, in a normal command line prompt, call @file{vcvars32.bat}
+which sets up the environment variables for the Visual C++ tools
+(the standard location for this file is
+@file{C:\Program Files\Microsoft Visual Studio 8\VC\bin\vcvars32.bat}).
+
+@item Enter the @file{bin} directory where the created LIB and DLL files
+are stored.
+
+@item Generate new import libraries with @file{lib.exe}:
+
+@example
+lib /machine:i386 /def:..\lib\avcodec-53.def  /out:avcodec.lib
+lib /machine:i386 /def:..\lib\avdevice-53.def /out:avdevice.lib
+lib /machine:i386 /def:..\lib\avfilter-2.def  /out:avfilter.lib
+lib /machine:i386 /def:..\lib\avformat-53.def /out:avformat.lib
+lib /machine:i386 /def:..\lib\avutil-51.def   /out:avutil.lib
+lib /machine:i386 /def:..\lib\swscale-2.def   /out:swscale.lib
+@end example
+
+@end enumerate
+
 @subsection Cross compilation for Windows with Linux
 
 You must use the MinGW cross compilation tools available at