Skip to content

je-so/js-projekt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Title: Readme
  Content of Readme file of js-projekt.
  See <Make Command> and also <System Configuration>.

License:
  Licensed under GNU General Public License v2 (see LICENSE),
  or (at your option) any later version.

Author:
  (c) 2010-2014 Jörg Seebohn

Web location:
  Free software project hosted at github:  https://github.com/je-so/js-projekt

Download:
  The newest source code (Linux version) can be downloaded from: http://github.com/je-so/js-projekt/zipball/master


section: Description

about: Goal

  To develop a database server and also a transactional general purpose programming language.
  The goal is to remove the impedance mismatch between computer languages and database backends.
  Implementation language is C99 (switch to C11 will be made if gcc supports it).
  During the design phase the development is done only on Linux.
  Development system is Ubuntu 11.04 or later.

about: State

  The current development is the architecture and design phase.
  The structure of the base system must support many users so the concurrency problem
  has to be solved in one way or another. Some kind of transaction
  processing monitor which can handle things like client-server communication,
  transaction contexts and process management is needed.

about: Developed Ideas

Subproject TextDB:

  Reads text database in CSV format and patches query result into C-source code.
  Used to manage initialization lists and to configure unix signal handlers.
  See directory "C-kern/resource/config/" for textdb databases.

  Example:
  The following code shows how the init and free functions (which should be called once at the start of the process) are patched into code.
  The list of functions is stored in the text database file 'C-kern/resource/config/initprocess'.
  > // TEXTDB:SELECT(\n"   err = initonce_"module"("(if (parameter!="") "&pcontext->" else "")parameter") ;"\n"   if (err) goto ONABORT ;"\n"   ++ pcontext->initcount ;")FROM("C-kern/resource/config/initprocess")
  > ...
  > err = initonce_valuecache(&pcontext->valuecache) ;
  > if (err) goto ONABORT ;
  > ++ pcontext->initcount ;
  >
  > err = initonce_thread() ;
  > if (err) goto ONABORT ;
  > ++ pcontext->initcount ;
  > // TEXTDB:END

Subproject Genmake:

  Automate generation of makefiles. Genmake offers a simple project description and generates the
  corresponding makefile with all source code dependencies.

  Example:
  The following example shows the project description of the text resource compiler.
  > include        projekte/binary.gcc
  > Src            = C-kern/main/tools/resource_textcompiler.c
  > Src           += C-kern/tools/hash.c
  > Includes       = .
  > Defines        =

Subproject textres2compiler:

  Handle text resources for different languages.
  The textres2compiler generates a C header and source file from a text resource file, see "C-kern/resource/loerror2.text".
  The generated files can be used to produce text strings for any language described in the resource file.
  The kind of language must be decided at compile time - runtime switching is not supported at the moment.

  The second version of the resource compiler supports conditional text which can depend on the supplied parameters.

  Example:
  The following text resource has as single parameter the number of files and the returned text depends on it.
  >  FILES_DELETED(unsigned nr_of_deleted_files)
  >  en: "I have deleted " ((nr_of_deleted_files==0) "no" (nr_of_deleted_files==1) "one" else nr_of_deleted_files)
  >      ((nr_of_deleted_files==1) " file\n" else " files\n")


section: Build

about: Make Command

  Run 'make' at the top level directory.
  This should build all subprojects.

  The main makefile ('Makefile') calls for every subproject the corresponding
  makefile in 'projekte/makefiles/'.

  To run all unit tests execute bin/unittest (release version)
  or bin/unittest_Debug.

about: System Configuration

  To run the test program no special system configuration is required
  for most of the tests.

unittest_platform_sysuser:
  The authenfication service which is implemented with help of libpam
  uses the service name "passwd" and therefore the same configuration
  as the passwd system command. But to make the unittest work you
  should create a user "guest" with passowrd "GUEST" and either run
  the test as setuid root or as setuid guest to work.
  If you want to change the values edit C-kern/resource/config/modulevalues
  and change the values prefixed with module "sysuser_t".

about: Project Configuration

  Run ./configure which reads the system configuration of freetype2
  and writes it to projekte/external-lib/freetype2.

  Graphic Subsystem:
  To enable the graphic subsystem for the unit tests
  uncomment the settings at bottom of file projekte/unittest.prj.

  Include path for X11, EGL and OpenGL (ES) are hard coded
  in include files C-kern/api/platform/Linux/graphic/sys*.h.
  This enables for every platform different includes.
  But in general the include files are expected be located
  under the default /usr/include/{GL,EGL,GLES2,freetype2}.

about: Make Targets

  all      - Builds »Debug« and »Release« version of every subproject except »html«.
  Debug    - Builds debug binaries of every subproject. The generated binaries are stored under directory 'bin/'.
             A binary is named after its corresponding project name plus an additional '_Debug' suffix.
  Release  - Builds release binaries of every subproject. The generated binaries are stored under directory 'bin/'.
             A binary is named after its corresponding project name without any additional suffix or prefix.
  html     - Generate documentation from source code with naturaldoc.
             You can view it by opening html/index.html in a browser.
  genmake  - Build genmake binaries: »bin/genmake« and »bin/genmake_Debug«.
  unittest - Build test binaries »bin/unittest« and »bin/unittest_Debug« which run all unit tests of all
             devloped modules.
  textdb   - Build text database tool binaries: »bin/textdb[_Debug]«
  textrescompiler  - Build resource compiler binaries: »bin/textrescompiler[_Debug]«
  testchildprocess - Build test process »bin/testchildprocess[_Debug]« used in "unittest_platform_process".
  pp-textdb  - Runs the textdb tool to preprocess all C source files to patch the m with the content of
               the textdb database files.
  pp-textres - Runs the textrescompiler tool to preprocess all text resourc files and to generate
               the corresponding C header files.

about: Documentation
  The documentation is extracted from the source files by naturaldoc.
  Type 'make html' to run it. Make sure you have installed v1.5 on your system.
  Type 'firetestchildprocessfox html/index.html' to view it (replace firefox with your favourite browser).

about: Dependencies
  To build the whole project or any subproject the following dependencies should be considered.

  Libraries:
     - libpthread for threading support (installed on Linux by default)
     - librt for realtime signal support (installed on Linux by default)
     - libpam (Pluggable Authentication Modules) for authentication
       of user names and password secrets (installed on Linux by default)
       But you need to install libpam0g-dev (other distros than Ubuntu have other names) which contains all the C header development files for libpam.

  Libraries for graphic subsystem:
     - libfreetype: FreeType 2 font engine development files to support text in combination with OpenGL or OpenGL ES
     - libgl: OpenGL API development files to support OpenGL
     - libegl: OpenGL EGL API development files to support binding of OpenGL ES
     - libgles2: OpenGL GL ES 2 API development files to support OpenGL ES 2

You do not need OpenGL and OpenGL ES support both at the same time. Choose one.
But EGL (OpenGL binding to native window system) supports both (version >= 1.4)
with eglBindAPI.

about: Development Environment:
     * Git      (http://git-scm.com).
     * Codelite (http://codelite.org).
     * Natural Docs v1.5 (http://www.naturaldocs.org).

about: Project-structure
  Explanation of directory structure.

  LICENSE     - GPL v2 license
  Makefile    - Top level makefile which calls project makefiles
  README      - This readme file
  C-kern/     - Contains all C source code and other resources, e.g. localized text
  C-kern/api  - Contains all C header files (interfaces) of the implementation modules
  C-kern/konfig.h     - Global configuration file (must be included by every source module)
  coding-conventions/ - A textual description of the made design decisions
  projekte/           - Contains project descriptions suitable for Genmake
  projekte/makefiles/ - Contains generated makefiles
  projekte/codelite/  - Contains workspace & projects for the CodeLite IDE.

About

Database server in C99 (in design stage)

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages