I'm working on a change set to install headers on *nix when make install is run, but I need some clarification and direction.
First is the question of where to install them. The root is easy to determine, it should always be ${CMAKE_INSTALL_PREFIX}/include, but the subdirectory and file names I'm uncertain of.
Should they be allowed to co-exist with the non-embedded C and C++ libraries? My instincts say "yes".
If the community agrees with the above, then should they go in the mqtt/embed subdirectory perhaps? (e.g., /usr/include/mqtt/embed)
Finally, how many header files do we reasonably need? Can we consolidate them into a single packet.h header or do we need multiple headers?
Even if we want multiple headers, each should be structured to be able to be included alone such that types it uses are included. Probably the easiest way to do this would be to separate out MQTTString into its own header and tease apart the other inter-header dependencies.
I think the headers should be allowed to co-exist with the mainline Paho C/C++ libraries. If both are installed by accident, then unexpected and confusing errors could occur.
I think that the directory name ought to include the 'paho' name. Other MQTT implementations are available :-)
I intended that there would be at least 3 different packages each of which can be used independently:
MQTTPacket - most lightweight, least helpful
MQTTClient - C++ synchronous
MQTTAsync - C++ asynchronous
Now there is a C version of MQTTClient as well which adds to the options. I think we need separate headers for each. And a programming manual or similar doc, which I guess I should write :-)
I'm working on a change set to install headers on *nix when
make install
is run, but I need some clarification and direction.First is the question of where to install them. The root is easy to determine, it should always be
${CMAKE_INSTALL_PREFIX}/include
, but the subdirectory and file names I'm uncertain of.mqtt/embed
subdirectory perhaps? (e.g.,/usr/include/mqtt/embed
)packet.h
header or do we need multiple headers?Even if we want multiple headers, each should be structured to be able to be included alone such that types it uses are included. Probably the easiest way to do this would be to separate out MQTTString into its own header and tease apart the other inter-header dependencies.