73632

Using libraries compiled for Windows on Linux

Question:

I'm curious. I have a library (static and dynamic version) compiled with visual studio for Windows 64bit which I want to use on Linux. This is a commercial library and to get the same library compiled for Linux will take many days of emailing and reminding and so on and so on.

Can I use one of these two library variants (and these are not .net, but native libraries) to link to them on Linux machine?

Answer1:

Theoretically, you should be able to do so.

It would be an awful lot of work, but this is for instance how windows audio/video codecs are loaded by MPlayer.

You would have to write from scratch the interface wrapper, load the dll, and fix up the calling conventions.

It is a lot of work, however, that makes most sense if the library is self-contained, interfaces are scarce and well understood, and the other option would take too much time.

(essentially, if you understand what goes into writing a linker for both linux and windows) :)

Please let me know if you need any help with that.

Answer2:

No, you cannot do that, I'm afraid

Answer3:

No you can't do that. You can either try to get the linux version, or build your program on windows and run it on linux with emulator, for example wine.

Recommend

  • What is the benefit of update instead of doing delete and then Insert in the same table
  • Core data structure use multiple entities or not?
  • Google Datastore - Not Seeing 1 Write per Second per Entity Group Limitation
  • Chart js - Draw center of each bubbles of a bubble chart
  • Product and product template in Odoo 10
  • getUserMedia results in TrackStartError in Chrome
  • 302 Redirect from http to https in Android using Dropbox short Hyperlinks
  • Finding number of samples in a .wav header
  • How to crop a mp3 in ASP.NET + C#?
  • Add a div to replace Video after Video Plays Through
  • Are there any supported high bit-depth video or image formats in DirectShow
  • Converting raw frames into webm live stream
  • Shopify API CARTS - Changing line_item line_price for price Override
  • UML diagram generator in Visual Studio 2010
  • include dlls in visual studio c++ 2008
  • How to assert that an input element is empty in Ruby on Rails tests
  • react split panel resize
  • SIP API media codecs
  • Embedded Glassfish JPA Datasource connection fail
  • Can you pass an array from javascript to asp.net mvc controller action without using a form?
  • Graphics.CopyFromScreen [Web application] + The handle is invalid
  • ADO and msqli connections very slow
  • Webgrid not refreshing after delete MVC
  • java inputstream
  • Custom Tabgroup Appcelerator
  • Jquery UI tool tip close icon
  • why do I get the error when installing the gem 'pg'? [duplicate]
  • javaw.exe and eclipse startup problems
  • Get object from AWS S3 as a stream
  • Sony Xperia Z Tablet not found by adb
  • Cross-Platform Protobuf Serialization
  • Validaiting emails with Net.Mail MailAddress
  • Javascript convert timezone issue
  • Why is the timeout on a windows udp receive socket always 500ms longer than set by SO_RCVTIMEO?
  • Timeout for blocking function call, i.e., how to stop waiting for user input after X seconds?
  • Do I've to free mysql result after storing it?
  • Function pointer “assignment from incompatible pointer type” only when using vararg ellipsis
  • Traverse Array and Display in markup
  • How do you join a server to an Active Directory (domain)?
  • Qt: Run a script BEFORE make