Alan W. Irwin wrote: > > I suggest you simplify the above logic by separating the driver namespace > from the core library one just as we currently do for the csa and nn > libraries. What I had in mind was using MAKINGDRDLL, USINGDRDLL, > DRDLLEXPORT, DRDLLIMPORT, and DRDLLIMPEXP for the driver-related symbols > with MAKINGPLDLL, USINGPLDLL, PLDLLEXPORT, PLDLLIMPORT, and PLDLLIMPEXP > strictly reserved for the core library symbols. If you follow my > suggestion, I don't think you will have to change the order of > #includes or > change from USING to MAKING in mid-stream like you suggest above. > > Instead, for the dynamic device case (ENABLE_DYNDRIVERS=ON) build > libplplotd > with -DMAKINGPLDLL -DUSINGCSADLL -DUSINGNNDLL -DUSINGDRDLL, and build the > dynamic devices with -DMAKINGDRDLL -DUSINGPLDLL. This way of doing > things > is only a small conceptual departure from what we do now (USING and > MAKING > controlled by CMake, xxxDLLIMPEXP used in the headers and defined as > import > or export depending on whether USING or MAKING). The only real > difference > from what we have now in my proposal is the driver/library namespace > separation issues are dealt with properly. > > I should also mention that separating the driver namespace from the core > library one is also important for the (usual Windows) case where dynamic > loading of drivers is disabled (ENABLE_DYNDRIVERS=OFF). In this case, > the > device driver code is put into libplplotd so import/export of library and > driver code with each other is no longer relevant. Instead, we want to > hide all driver symbols from the external world in this case. That is > easily arranged by setting DRDLLIMPEXP to nothing while setting > PLDLLIMPEXP > to the appropriate value.
Ah, indeed! That is the way forward. That makes it much easier, at the mere expense of an extra header file and a few macros. Regards, Arjen ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Plplot-devel mailing list Plplot-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/plplot-devel