Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Ubuntu libdispatch what to include

I am trying to port a GCD (Grand Central Dispatch) application to Ubuntu and I found the libdispatch ubuntu package with

    apt-get install libdispatch0

and it appeared to install correctly (running the command dlocate libdispatch0 indicates it exists). The c header file that I use has

    #include <dispatch/dispatch.h>

but when I try to compile using clang it says that dispatch/dispatch.h not found. I've been looking for what include to use for a while now. Using dlocate, I found a dispatch.hpp file, but

    #include <dispatch/dispatch.hpp> 

didn't work either. Doing a dlocate for gcd found a gcd.h, but

   *include <gcd.h> 

didn't work either.

Anybody work with gcd on ubuntu?

like image 221
syzygy Avatar asked Aug 12 '26 19:08

syzygy


1 Answers

The solution was to run

    apt-get install libdispatch-dev 

instead of libdispatch0, which does not include header files, man pages and basically anything you would want if you want to make programs that use GCD. Apparently libdispatch0 is for people who want Ubuntu to use GCD internally.

like image 72
syzygy Avatar answered Aug 15 '26 09:08

syzygy