Building a Win32 DLL from a Linux Library Source

I am trying to create a Win32 DLL from the Linux library associated with the audio DSP ( http://breakfastquay.com/rubberband/ ). For Linux, there are make files and config scripts, but for Windows there is no help. The author provides the Win32 binary code for the sample application using the library, and I see that several "#ifdef MSVC" and "#ifdef WIN32" are scattered around me, so I don’t think that I start completely from scratch, Nevertheless.

Since my programming knowledge on any platform is quite limited, I will be grateful for any help.

First of all, what is the right way to start here? Visual studio Cygwin? Initially, I started creating a Win32 DLL project in Visual Studio, adding the source files, thinking about adding a .def file, etc., but at some point I felt that it was no good.

Regarding Cygwin, this was the first time I used it, and I don’t even know if this is suitable for Cygwin. It?

At Cygwin, I ran. / configure and stuck in something like this:

"check for SRC ... configure: error: package requirements (fetching) failed: packet" samplerate "not found"

After looking at the log, it turns out that pkg-config is looking for samplerate.pc. How to process packages on Windows? libsamplerate is just an open source library, and for that I have a source and a DLL. But I'm not sure how to use them to satisfy the dependency requirements for librubberband (what I'm trying to create)

At that moment, I was completely lost, and if someone can give me a push in the right direction ... and is there an easier way to do this?

Thank you very much in advance.

+3
source share
2 answers

If you're still stuck on this, I can light up a bit.

, ( , ). Cygwin, MinGW MSYS , .

, Cygwin, , ​​ . , .

libsndfile. Cygwin bash . :

./configure
make
make install prefix=/cygdrive/c/cygwin

, , Cygwin ( MinGW MSYS, MinGW). , usr , .

FFTW, libsamplerate rubberband. , libsndfile: , , . FFTW ( , /cygdrive/c/cygwin/include) include usr ( /cygdrive/c/cygwin/usr/include).

SRC (libsamplerate), .

Vamp plugin SDK. , src\vamp-hostsdk\PluginLoader.cpp, RTLD_LOCAL dlopen() ( , ).

, ( ). PKG_CONFIG_PATH, pkgconfig, :

set PKG_CONFIG_PATH=/cygdrive/c/cygwin/lib/pkgconfig:/usr/local/lib/pkgconfig

ladspa.h include LADSPA

, , , .

MSYS MinGW , . Visual Studio - , (, libsndfile), Linux Windows ( ) VS.

, ; , , .

+1

Linux w32 - , , .
:

./configure
make
sudo make install

, MinGW + msys CygWin ( , ). , VS - 't .

+1

Source: https://habr.com/ru/post/1717547/


All Articles