Project homepage Mailing List  API Docs  Github Mirror 
{"schema":"libjg2-1", "vpath":"/git/", "avatar":"/git/avatar/", "alang":"en-US,en;q\u003d0.5", "gen_ut":1635258562, "reponame":"libwebsockets", "desc":"libwebsockets lightweight C networking library", "owner": { "name": "Andy Green", "email": "", "md5": "c50933ca2aa61e0fe2c43d46bb6b59cb" },"url":"", "f":3, "items": [ { "schema":"libjg2-1", "oid":{ "oid": "b5aad92ff0cc58dd1e0abb8ed7a08399b8f47e4b", "alias": [ "refs/heads/main"]},"tree": [ { "name": "CMakeLists.txt","mode": "33188", "size":2267}, { "name": "","mode": "33188", "size":2830}, { "name": "dbus.c","mode": "33188", "size":15281}, { "name": "private-lib-roles-dbus.h","mode": "33188", "size":1671}],"s":{"c":1635258562,"u": 645}} ,{"schema":"libjg2-1", "cid":"ffbeeb5bfe0c8b40ba9f829c4966a3d7", "oid":{ "oid": "b5aad92ff0cc58dd1e0abb8ed7a08399b8f47e4b", "alias": [ "refs/heads/main"]},"blobname": "lib/roles/dbus/", "blob": "# DBUS Role Support\n\n## DBUS-related distro packages\n\nFedora: dbus-devel\nDebian / Ubuntu: libdbus-1-dev\n\n## Enabling for build at cmake\n\nFedora example:\n```\n$ cmake .. -DLWS_ROLE_DBUS\u003d1 -DLWS_DBUS_INCLUDE2\u003d\u0022/usr/lib64/dbus-1.0/include\u0022\n```\n\nUbuntu example:\n```\n$ cmake .. -DLWS_ROLE_DBUS\u003d1 -DLWS_DBUS_INCLUDE2\u003d\u0022/usr/lib/x86_64-linux-gnu/dbus-1.0/include\u0022\n```\n\nDbus requires two include paths, which you can force by setting `LWS_DBUS_INCLUDE1`\nand `LWS_DBUS_INCLUDE2`. Although INCLUDE1 is usually guessable, both can be\nforced to allow cross-build.\n\nIf these are not forced, then lws cmake will try to check some popular places,\nfor `LWS_DBUS_INCLUDE1`, on both Fedora and Debian / Ubuntu, this is\n`/usr/include/dbus-1.0`... if the directory exists, it is used.\n\nFor `LWS_DBUS_INCLUDE2`, it is the arch-specific dbus header which may be\npackaged separately than the main dbus headers. On Fedora, this is in\n`/usr/lib[64]/dbus-1.0/include`... if not given externally, lws cmake will\ntry `/usr/lib64/dbus-1.0/include`. On Debian / Ubuntu, the package installs\nit in an arch-specific dir like `/usr/lib/x86_64-linux-gnu/dbus-1.0/include`,\nyou should force the path.\n\nThe library path is usually \u005c[lib\u005c] \u0022dbus-1\u0022, but this can also be forced if\nyou want to build cross or use a special build, via `LWS_DBUS_LIB`.\n\n## Building against local dbus build\n\nIf you built your own local dbus and installed it in /usr/local, then\nthis is the incantation to direct lws to use the local version of dbus:\n\n```\ncmake .. -DLWS_ROLE_DBUS\u003d1 -DLWS_DBUS_INCLUDE1\u003d\u0022/usr/local/include/dbus-1.0\u0022 -DLWS_DBUS_INCLUDE2\u003d\u0022/usr/local/lib/dbus-1.0/include\u0022 -DLWS_DBUS_LIB\u003d\u0022/usr/local/lib/\u0022\n```\n\nYou'll also need to give the loader a helping hand to do what you want if\nthere's a perfectly good dbus lib already in `/usr/lib[64]` using `LD_PRELOAD`\nlike this\n\n```\nLD_PRELOAD\u003d/usr/local/lib/ myapp\n```\n\n## Lws dbus api exports\n\nBecause of the irregular situation with libdbus includes, if lws exports the\ndbus helpers, which use dbus types, as usual from `#include \u003clibwebsockets.h\u003e`\nthen if lws was compiled with dbus role support it forces all users to take\ncare about the dbus include path mess whether they use dbus themselves or not.\n\nFor that reason, if you need access to the lws dbus apis, you must explicitly\ninclude them by\n\n```\n#include \u003clibwebsockets/lws-dbus.h\u003e\n```\n\nThis includes `\u003cdbus/dbus.h\u003e` and so requires the include paths set up. But\notherwise non-dbus users that don't include `libwebsockets/lws-dbus.h` don't\nhave to care about it.\n\n## DBUS and valgrind\n\n\n\n1) One-time 6KiB \u0022Still reachable\u0022 caused by abstract unix domain socket + libc\n`getgrouplist()` via nss... bug since 2004(!)\n\n\u003d273051\n\n\n\n","s":{"c":1635258562,"u": 213}} ],"g": 2459,"chitpc": 0,"ehitpc": 0,"indexed":0 , "ab": 1, "si": 0, "db":0, "di":1, "sat":0, "lfc": "0000"}