Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

Building on OSX

2014-07-22
2014-10-03
  • Chris de Rock
    Chris de Rock
    2014-07-22

    i got several errors on OSX:

    1. Platform
      OSX 10.9.4; QT 4.8.6

    2. Build Errors

    3. qlclogdestination.cpp:36 - Symbol ola::StringTrim not found
    4. hidjsdevice.h:113
      is: void outputDMX(const QByteArray &data) { Q_UNUSED(data);};
      must be: void outputDMX(const QByteArray &data, bool forceWrite =
      false) { Q_UNUSED(data); Q_UNUSED(forceWrite)};
    5. hidfx5device.cpp:187
      the fragment '(char)0x0' is not accepted by the compiler. when changed
      to '0' everything works

    6. Install Errors
      on make install, the qt frameworks are not copied, so the
      instal_name_tool reports the error.

    any ideas?

    regards
    -Chris

     
  • Hello to you.

    1) Qt 4.8.6 on OSX is buggy. There's an article about it in the QLC+ website homepage.
    After my bug report https://bugreports.qt-project.org/browse/QTBUG-38636 they have released a new package but I haven't tested it. Just use version 4.8.5.
    3) did you install OLA ?

     
    Last edit: Massimo Callegari 2014-07-22
  • Chris de Rock
    Chris de Rock
    2014-07-22

    in the "OSX Build HOWTO" you write qt 4.8.x so i took the latest version. and yes, ola is installed (0.9.0). its the single symbol that cannot resolved.

     
  • Chris de Rock
    Chris de Rock
    2014-07-22

    ok, trying with qt 4.8.5 and started with a fresh git clone. the first thing i got was "this version of mac os x is not supportet" ;) so i edited qglobal.h to enable the support...

    the build errors are the same as described but the install seems to work.

     
  • Chris de Rock
    Chris de Rock
    2014-07-22

    ok.. my intention was to build qlc with support for ftd2xx. the build is now complete and will be tested later this evening. for the people who wants to try the same here are some extensions to the nametool-process to include the libftd2xx.1.2.2.dylib into the app-bundle

     
  • Chris de Rock
    Chris de Rock
    2014-07-23

    some ideas for the ftd2xx support...

    in plugins/dmxusb/src/src.pro you write that the interface is propertiary. thats right. but why you link against this interface? you can go an other way:

    the constructor of QLCFTDI is empty atm. here you can try to load the interface using dlopen(3) on linux and osx. after that dlerror(3) will give you a response or NULL if the lib is not found. if the lib is loaded, just use dlsym to load the functions you need direct from the lib.

    if you go this way you can just compile the app and it contains no tainted code. if a user wants to use the ftd2xx, he can just install the propertiary interface and it will work.

     
  • Chris de Rock
    Chris de Rock
    2014-07-23

    here the refactored file. it is modified to load the library at runtime. but i'm a *nix developer so the m$ part is up to you. it compiles and qlc+ starts without problems but here i have no ftdi device for testing. (but i think, it should work)

     
    Attachments
  • What can I say ? Wow...this is a super solo of yourself.
    But I'm missing the point.

    Can you please explain to everyone the meaning of this change ? Why you did it, the pros and the cons. Are you having any benefit in using D2xx instead of FTDI ? If so, can you describe what they are ?

    By the way libFTDI doesn't taint the code as it is open source and freely distributed with macports. Same on Linux.

    In general, patches should be shared as .patch files or on GitHub. In this way you force me to manually compare your changes with the upstream sources

     
  • Chris de Rock
    Chris de Rock
    2014-07-23

    this driver works with my cheap usb2dmx device and i missed them in all versions above 4.6.1.

    the pros are very simple. you can just distribute the usbdmx plugin with this code without direct linking (and packaging) the propertiary interface. if the use installs the driver, it will work out of the box. at the moment the only con is see is that you have to do the work to support m$ as well.

    patches? mhh... one thing is that i see no hint about patches on your site (and never worked with git ;). the other thing is as i described, the code is not fully tested.

     
  • Well I guess the answer to the issues you found is in your last post. It seems QLC+ version 4.6.1 worked fine on some cheap USB devices, while latest builds don't. Can you confirm this ?

    I would prefer to concentrate on the cause of this instead of adding complexity to the build system and force average users to dedicate effort (they usually don't have) on a FTDI driver.

    QLC+ has to work out of the box, so for OSX users, a bundle must contain all the necessary software to accomplish the goal.

     
  • Chris de Rock
    Chris de Rock
    2014-07-23

    Yes. My device based on the FT232RL works fine with QLC+ 4.6.1 but is not supported in later versions. After building QLC+ with ftd2xx it works and makes me happy ;)

     
  • Interesting indeed.
    Do you actually know what is the difference between libftdi and libd2xx ?

    By "not supported" do you mean that the device is detected but it doesn't output anything ?

    I'm wondering if it could be safe to bundle by default D2xx in the OSX version...

     
  • Chris de Rock
    Chris de Rock
    2014-07-23

    With "not supported" i mean the device is not recognized by QLC+ > 4.6.1

     
  • Chris de Rock
    Chris de Rock
    2014-07-23

    i know this page, but only in the office i run 10.9. my private macs run with 10.6 and 10.7 so this is not the problem. and as i say. 4.6.1 works, later versions on the same machine dont work.

    at the moment i take a look at the software from chromateq. these contains the libftd2xx so it may be possible to bundle the lib.

     
  • Eddy
    Eddy
    2014-07-27

    Hi Christian

    If you will I can test it. I have a MacBook Pro with Max OS x 10.7.5 and an Enttec Open DMX USB. This is not working with the latests versions of QLC+. The last weeks I'm searching and trying to work this out but so far I didn't find a solution. If you send me the bundle I can try it out.

    Kind regards

    Eddy

     
    Last edit: Eddy 2014-07-27
  • Chris de Rock
    Chris de Rock
    2014-07-28

    You can try this build: http://chris.derock.de/qlc/ it has bundled the libftd2xx and works for me

     
  • Chris de Rock
    Chris de Rock
    2014-07-29

    i have now added a version that loads libftd2xx at runtime. available on http://chris.derock.de/qlc

     
  • Eddy
    Eddy
    2014-07-30

    I've tested QLC+ bundled with libftd2xx on my MacBook Pro with Max OS x 10.7.5 and an Enttec Open DMX USB. When you use the FTDI driver control from Entecc and disable the serial FTDI driver everything works fine. Thanks for the solution Christian.

    I also tested the version that loads libftd2xx at runtime. But that didn't work. What's the difference between this build: http://chris.derock.de/qlc/ it has bundled the libftd2xx and the version that loads libftd2xx at runtime?

     
  • Chris de Rock
    Chris de Rock
    2014-07-30

    The difference between these versions is that the bundled version is direct linked to libftd2xx (so the app 'knows' where to find the lib).

    the other version look at runtime for the library (first in the library cache, then at /usr/lib, then at /usr/local/lib). it looks for libftd2xx.dylib which should be a symlink to the real lib (as described in the installation manual for libftd2xx)

    after loading the lib, it loads all nedded functions from the lib into dummy-variables and uses these variables instead of the real function calls (look above for the file qlcftdi-ftd2xx.cpp)

    this prevents the app from containing propertiary code.

     
  • Eddy
    Eddy
    2014-10-03

    Hi Christian

    Comes there a 4.8.0 version of QLC+ bundled with the libftd2xx? I try the 4.8.0 version on my MacBook Pro with Max OS x 10.7.5 and an Enttec Open DMX USB, but it doesn't recognize the Enttec Open DMX USB.