Use mingw in XP to compile rtmpdump to generate librtmp. dll

Source: Internet
Author: User
Tags install perl

Reference: http://blog.csdn.net/gavinr/article/details/7238453

1. The systems and resources I use
System: XP
Resources: mingw, Perl, msys, OpenSSL, zlib, rtmpdump
Download link mingw: http://download.csdn.net/detail/lightboat09/4485956

Download link Perl + msys + OpenSSL + zlib + rtmpdump

Rtmpdump: http://rtmpdump.mplayerhq.hu/

OpenSSL: http://www.openssl.org/

Zlib: http://zlib.net/

Perl: http://www.filecluster.com/downloads/ActivePerl.html

Msys: http://www.mingw.org/wiki/msys/

Ii. Install the compiling environment
1. Install Perl, run the ActivePerl-5.14.2.1402-MSWin32-x86-295342.msi, always press Enter!
2. Install mingw, run mingw-5.1.6.exe, select current and full for installation, and add the mingw installation path (C:/mingw/bin) to the system environment after installation.
3. Install msys, run msys-1.0.10.exe, and select the path C:/mysy! The default value is C:/mysy/1.0 (this can also be used ),
In the command box that appears, select the mingw installation path. Follow the instructions in English and enter C:/mingw,
If your mingw installation path is C:/mingw

3. Compile source code
Copy the source code of OpenSSL, zlib, and rtmpdump to C :/.
Run msys,
Cd c:
Go to disk C directory
1. OpenSSL
A. modify some symbolic connections in Linux.

CD Test
Rm-F md2test. c
Ln-s dummytest. c md2test. c
Rm-F rc5test. c
Ln-s dummytest. c rc5test. c
Rm-F jpaketest. c
Ln-s dummytest. c jpaketest. c

B. Compile
./Configure mingw -- prefix = 'pwd'/win32libs-dl_endian-dopenssl_no_hw
Make
Make install

2. zlib
 
CP Win32/makefile. GCC makefile. GCC
Make-F makefile. GCC

3. rtmpdump
A. Copy the dependent library and header file
Copy the OpenSSL folder under OpenSSL/include to the C:/mingw/include directory.
Copy zconf. h and zlib. h under zlib to the C:/mingw/include directory.
Copy libcrypto. A and libssl. A to the C:/mingw/lib directory under OpenSSL
Copy zlib. A under zlib to the C:/mingw/lib directory.

B. Compile
CD rtmpdump
Make sys = mingw
Make sys = mingw install

If everything goes well, you can see the generated librtmp. dll in the rtmpdump/librtmp directory.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.