vs2008 编译 live555

 

1.官网说明

How to configure and build the code on Windows

  1. Unpack and extract the '.tar.gz' file (using an application such as "WinZip").
  2. If the 'tools' directory on your Windows machine is something other than "c:\Program Files\DevStudio\Vc", change the "TOOLS32 =" line in the file "win32config".
  3. In a command shell, 'cd' to the "live" directory, and run
        genWindowsMakefiles
    

This will generate - in each subdirectory - a "*.mak" makefile suitable for use by (e.g.) Microsoft Visual Studio.

  • Alternatively, if you're starting from a Unix machine, you can generate the Windows Makefiles by running
        ./genWindowsMakefiles
    
    (after - if necessary - changing the "TOOLS32 =" line in the file "win32config", as noted above). Then, copy the "live" directories and its subdirectories (in ASCII mode) to a Windows machine.
  • To use these Makefiles from within Visual Studio, use the "Open Workspace" menu command, then (in the file selection dialog) for "Files of type", choose "Makefiles (.mak)". Visual Studio should then prompt you, asking if you want to use this  Makefile to set up a new project. Say "OK".
  • Note that you will need to build each of the "UsageEnvironment", "groupsock", "liveMedia", and "BasicUsageEnvironment" projects first, before building "testProgs".
  • If you wish, you can build the "WindowsAudioInputDevice" project also.
  • Doug Kosovic notes: Visual C++ 2003 no longer comes with the old I/O Streams headers iostreams.h et al, or the corresponding library msvcirt.lib. So anybody trying to build the LIVE555 code with VC++ 2003 might find the following useful: A non-sourcecode modification workaround for VC++ 2003 is to copy the missing headers and msvcirt.lib from VC++ 2002. In file 'win32config' add an extra -I switch to COMPILE_OPTS to find the old headers and a -LIBPATH: switch to LINK_OPTS_0 to find msvcirt.lib.


2.修改win32config文件

TOOLS32 = D:\Program Files\Microsoft Visual Studio 9.0\VC

LINK_OPTS_0 = $(linkdebug) msvcirt.lib 中的msvcirt.lib修改为msvcrt.lib

修改groupsock/makefile.head替换"INCLUDES = -Iinclude -I../UsageEnvironment/include" 为"INCLUDES = -Iinclude -I../UsageEnvironment/include -DNO_STRSTREAM,其实就是定义了宏"NO_STRSTREAM"

3.运行genWindowsMakefiles.cmd 在各个了目录下会生成VS能够编译的*.mak文件

4.新建批处理文件compile.bat,内容如下:
call "D:\Program Files\Microsoft Visual Studio 9.0\VC\vcvarsall.bat"
cd liveMedia
nmake /B -f liveMedia.mak
cd ../groupsock
nmake /B -f groupsock.mak
cd ../UsageEnvironment
nmake /B -f UsageEnvironment.mak
cd ../BasicUsageEnvironment
nmake /B -f BasicUsageEnvironment.mak
cd ../testProgs
nmake /B -f testProgs.mak
cd ../mediaServer
nmake /B -f mediaServer.mak
pause

5. 若要调试应先在win32config加入一行"NODEBUG=1" (或定义宏"DEBUG")。


 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值