Contenues dans
Trouver plus de documentation
Ressources d'assistance comprises
| Télécharger cet ouvrage au format PDF
Dynamically Loadable Extensions
D
- X extensions must meet the following criteria to be dynamically loadable by the server:
-
- The extension must be decoupled from the DIX and DDX layers of the server. This means that the extension must not require any server code changes to the DIX or DDX code. Implement all extensions with X11R6 wrappers around DDX vectors.
- The extension must not depend on any resource devPrivates. An exception is the Screen devPrivates, which can be dynamically reallocated, unlike other resource devPrivates (such as Window and GC) that can only be allocated before any resources are instantiated.
- Follow these steps to make an X extension meet these criteria:
-
-
Compile and link the extension as a shared object.
-
example% cc -K PIC -DSUNSOFT_BUYBACK -DSUNSOFT ... *.c
example% ld -G -z text *.o ... -o ACMExtn.so.1
|
-
Note - If you are upgrading from an earlier release, it is a good idea to compile with the SUNSOFT and SUNSOFT_BUYBACK flags turned on as in the example above.
-
For x86 systems - On some SunPro development system releases, -z text flags errors against non-relocatable sections in instances where no problems exist. In general, you can build the shared object without the -z text flag.
-
-
Create an entry for the extension in the OWconfig file. See Appendix A, "The OWconfig File" and Appendix B, "Packaging and Installation Hints" for information on adding this entry.
-
Install the shared object into the modules directory.
The server searches the following path for extension modules listed in the OWconfig file: /etc/openwin/server/modules:/usr/openwin/server/modules. See Appendix B, "Packaging and Installation Hints" for more information.
-
Start the server and verify if the extension is listed with xdpyinfo. XListExtensions lists the extension as available if an entry in the OWconfig file exists, without actually forcing the extension to be loaded.
-
Invoke XQueryExtension or make an extension request to verify that the extension actually gets dynamically loaded.
|
|