User Tools

Site Tools


doc:lua_make

This is an old revision of the document!


The LUA Make Environment

FIXME This page describes a build environment which is not released to the public yet. Although it is in daily use in a OEM already, we need to make it first more more generic for common use before releasing it. So this is more an internal paper yet.

How is the Make Environment set up?

The environment was designed to suit the following requirements:

  • Handle multiple car lines, each with dozens of module specs and scripts
  • batch translation of XML module specs, handwritten scripts and other templates in just one step
  • automatic encryption of the generated files, if wanted

To support this, the same kind of environment is used as what is widely known in software devopment: a command line based interface, where are the different tasks are started and controlled by makefiles, scripts and embedded other tools.

That means all step are started by typing the appropriate command and its parameter into a command line.

Setup the Cygwin Runtime Environment

To use the much more powerful unix environment instead of just a stupid DOS command interface, you need to install at first a CygWin Runtime Environment. To do so, please follow the CygWin Installation instructions

Basics about the Cygwin Environment

After installing and starting Cygwin, you'll be presented to a DOS like command line, but with some differences:

  • Unix takes care about uppercase and lowercase writing, so everything needs to be correctly written
  • the basic commands are different to DOS/Windows. A good introduction can be found here
  • Unix does not have backslashes \ in paths, it uses a normal slash / instead
  • Unix does not know drive letters like C:\. Instead each drive and directory is a subfolder under the global root directory /cygdrive. So drive C:\ becomes /cygdrive/c/, your Desktop folder would be /cygrive/c/Users/yourusername/Desktop (take care of upper/lower letters!)
  • with the cursor keys you can move back in the command history. Very helpful to not typing in the same commands all the time
  • with the TAB key you can auto-complete commands and file names.

Connect yourself to the central Script Repository

As soon as several scripts need to be maintained or more as one person is working on the scripts, it's highly recommended to use a central script repository, as we do here in our example with a central Subversion Server. The usage of subversion as such is out of the scope of this document, but you'll find tons of documentation in the Internet. Please read at last some base tutorials to get a basic understanding about subversion works.

To become connected to the so called repository, please get in contact with your repository admin. From him you'll get the so called repository-URL, your username and your password.

As next generate an empty directory, wherever you want to store all the script data, e.g. on your desktop

cd /cygrive/c/Users/yourusername/Desktop
mkdir OOBD-Script-Repository
cd OOBD-Script-Repository

as next create the so called “local working copy” of the repository with the command

svn checkout repository-URL

You'll be asked for username and password, and then svn (which is the short form for subversion) will transfer the whole content of the central repository into your working directory.

You might notice later that a lot of .svn directories have been created. In there subversion stores the metadata for the maintenance. Do not delete or even edit these directories!

The Directory Tree

after finishing the initial checkout, you'll find a directory and file structure like this:

.
├── docs
├── lua
├── mdx_pool
├── oobd_groups.pub
├── oobd_groups.pub.sig
└── tools
.
├── car1_my99_r
│   ├── car1_my99_carcheck.carcheck
│   ├── car1_my99_sw_versions.lua
│   ├── lua_reference
│   ├── files.inc
│   ├── makefile
│   ├── presets.rtd
│   ├── mdx_pool_reference
│   ├── ABC.seccode
├── car1_my99_s
│   └── ...
├── car1_my99_t
│   └── ...
├── car1_my99_w
│   └── ...
├── carcheck.footer
├── carcheck.header
├── carcheck.xslt
├── db
│   ├── oem.oodb
│   └── VehInfo_Stylesheet.xsl
├── generic.make
├── Healthfiles
│   └── OOBD-xmlfile.xml
├── lib_lua
│   └── ...
├── lib_protocol
│   └── ...
├── local.make
├── local_template.make
└── makefile

To use the available build tools for OOBD, it is essential that you keep the file structure as shown, as the tool settings rely on that.

Local Settings

This website uses cookies. By using the website, you agree with storing cookies on your computer. Also you acknowledge that you have read and understand our Privacy Policy. If you do not agree leave the website.More information about cookies
doc/lua_make.1393143938.txt.gz · Last modified: 2014/02/23 09:25 by admin