Home Developper corner Other languages Availables libraries

Programming advices

The LDG principles come from many constations:

When you'll write a LDG-library, keep in mind theses motivations !

Rules to create a LDG-library

There are severals rules to respect :

About memory allocation

A typically example of a LDG library distribution

If you create and diffuse a LDG-library, the archive file should have the following structure :

  MYLDGLIB.LZH :

    \gemsys\ldg\myldglib.ldg  ; The LDG library
    \include\ldg\myldglib.h   ; The C header containing the prototype
                              ; of the functions of MYLDGLIB.LDG
    \lib\myldglib.c           ; Binding of the functions in portable C
                              ; You can provide compiled library too.
    \man\man3l\myldglib.3l    ; manuel page nroff format
    \hyp\myldglib.hyp         ; hypertext documentation of the library
    \readme                   ; details for installation
    \install                  ; if possible a script or an installer program

By convention, the C-header file containing the definition of the function of a LDG-library should be placed in a subdirectory of your include folder. These file are included by client using these libraries. The C-library (here MYLDGLIB.LIB or LYLDGLIB.O) contains the binding of the functions. It is usally a function (eg init_myldglib()) initializing the LDG functions using the function ldg_find(). This file should be linked with the client.

If you create and diffuse a LDG-library, please contact us and we will create a link from our LDG internet site.

Have fun !


Copyright © (c) 1997 - 2004 all right reserved.
Last updated on April 25, 2005

Home Developper corner Other languages Availables libraries