Go Back   Cockos Incorporated Forums > REAPER Forums > REAPER Compatibility

Reply
 
Thread Tools Display Modes
Old 01-05-2021, 06:07 AM   #1
whtht
Human being with feelings
 
Join Date: Jan 2021
Posts: 5
Default [c++, g++, dylib] MacOS c++ plugin not loading on startup

Hello, I have developed a REAPER plugin with C++. DLL output works great on windows. But when I convert the plug-in to dylib format for macOS, the REAPER application in macOS does not initially install this plugin.

Plugin folders:
Windows: %APPDATA%\REAPER\UserPlugins
MacOS: ~/Library/Application Support/REAPER/UserPlugins

I've added the Windows and MacOS versions of the plugin below.
Generally, the plugin should type "Works" on the console.

Does anyone have any ideas?

Note: I am using g++ CLI to create dylib.
g++ Command: g++ -dynamiclib -o "Build\reaper_VadiSoundLibrary.dylib" "main.cpp"
Attached Files
File Type: zip reaper_VadiSoundLibrary.zip (50.3 KB, 65 views)

Last edited by whtht; 01-05-2021 at 06:10 AM. Reason: Wrong word usage.
whtht is offline   Reply With Quote
Old 01-05-2021, 02:39 PM   #2
cfillion
Human being with feelings
 
cfillion's Avatar
 
Join Date: May 2015
Location: Québec, Canada
Posts: 4,937
Default

That .dylib in the archive you've attached is a 32-bit Windows executable. You need to build it on macOS to get a macOS binary.

Code:
Downloads/reaper_VadiSoundLibrary$ file reaper_VadiSoundLibrary.dylib
PE32 executable (console) Intel 80386, for MS Windows

Downloads/reaper_VadiSoundLibrary$ file reaper_VadiSoundLibrary.dll
PE32+ executable (DLL) (GUI) x86-64, for MS Windows
The correct output for a 64-bit macOS shared library would be:

Code:
Mach-O 64-bit x86_64 dynamically linked shared library, flags:<NOUNDEFS|DYLDLINK|TWOLEVEL|WEAK_DEFINES|BINDS_TO_WEAK|NO_REEXPORTED_DYLIBS|HAS_TLV_DESCRIPTORS>

Last edited by cfillion; 01-05-2021 at 02:54 PM.
cfillion is offline   Reply With Quote
Old 01-05-2021, 04:10 PM   #3
whtht
Human being with feelings
 
Join Date: Jan 2021
Posts: 5
Default

Quote:
Originally Posted by cfillion View Post
That .dylib in the archive you've attached is a 32-bit Windows executable. You need to build it on macOS to get a macOS binary.

Code:
Downloads/reaper_VadiSoundLibrary$ file reaper_VadiSoundLibrary.dylib
PE32 executable (console) Intel 80386, for MS Windows

Downloads/reaper_VadiSoundLibrary$ file reaper_VadiSoundLibrary.dll
PE32+ executable (DLL) (GUI) x86-64, for MS Windows
The correct output for a 64-bit macOS shared library would be:

Code:
Mach-O 64-bit x86_64 dynamically linked shared library, flags:<NOUNDEFS|DYLDLINK|TWOLEVEL|WEAK_DEFINES|BINDS_TO_WEAK|NO_REEXPORTED_DYLIBS|HAS_TLV_DESCRIPTORS>
Thank you for reply.
whtht is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 03:08 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.