HowTo.txt 4.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. HowTo.txt - Copyright 2008 Symbian Software Ltd.
  2. This document describes how to use this test suite for stress-testing Linux-emulation type systems on Windows.
  3. Structure of tests
  4. ==================
  5. The Linux emulation layer tests are structured as follows:
  6. LinuxEmulationLayerStressTests\HowTo.txt (this file)
  7. LinuxEmulationLayerStressTests\makemakefile.py (described below)
  8. LinuxEmulationLayerStressTests\mingw.tar.bz2
  9. LinuxEmulationLayerStressTests\msys.tar.bz2
  10. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun01\makefiles_testrun01.zip
  11. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun01\testrig01.bat
  12. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun02\makefiles_testrun02.zip
  13. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun02\testrig02.bat
  14. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun03\makefiles_testrun03.zip
  15. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun03\testrig03.bat
  16. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun04\makefiles_testrun04.zip
  17. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun04\testrig04.bat
  18. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun05\makefiles_testrun05.zip
  19. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun05\testrig05.bat
  20. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun06\makefiles_testrun06.zip
  21. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun06\testrig06.bat
  22. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun07\makefiles_testrun07.zip
  23. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun07\testrig07.bat
  24. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun08\makefiles_testrun08.zip
  25. LinuxEmulationLayerStressTests\GeneratedMakefiles\TestRun08\testrig08.bat
  26. LinuxEmulationLayerStressTests\src\msys-sed-4.1.5-src.tar.gz
  27. Each test run has its makefiles preserved in the corresponding zip file (e.g. makefiles_testrun01.zip).
  28. The testrigNN.bat are very basic batch scripts that do not take any parameters. They are simply there as a
  29. bootstrap to
  30. 1) Set the PATH to contain either MSYS's or Cygwin's bin folder (but not both!)
  31. 2) Set the PATH to contain MinGW's bin folder (for MinGW's make)
  32. 3) Generate the makefiles in a number of for-loops (optional)
  33. 4) Run the make over the makefiles in a number of for-loops
  34. In future, if any of these batch files are re-used, it will be necessary to adjust them so that
  35. they set the PATH environment variable correctly to contain the place where MSYS or Cygwin
  36. was unzipped. Then decide if you wish to generate further makefiles using the Python script,
  37. or if it's just enough to run the existing makefiles.
  38. For convenience, both MSYS and Cygwin are provided in the files
  39. LinuxEmulationLayerStressTests\mingw.tar.bz2
  40. LinuxEmulationLayerStressTests\msys.tar.bz2
  41. These are the versions that were tested and were shipped with SBSv2. Simply untar to a convenient
  42. location and update the batch files bootstraps to add these to your PATH.
  43. makemakefile.py
  44. ===============
  45. This script, as its name suggests, makes a range of makefiles. Use the command
  46. python makemakefile.py -h
  47. to see a list of available options. At time of writing, the usage help is as follows:
  48. Usage: makemakefile.py [options]
  49. Options:
  50. -h, --help show this help message and exit
  51. -t TARGETS, --targets=TARGETS
  52. Number of main (or "level1") targets to generate -
  53. these are the targets that actually perform some
  54. simulated actions.
  55. -d DIVISIONS, --divisions=DIVISIONS
  56. The number of "level2" targets. Each level2 target
  57. will depend on t/d level1 targets. This makes makefile
  58. generation more logical.
  59. -m MAKEFILE, --makefile=MAKEFILE
  60. Name of makefile to generate. If blank, makefile is
  61. printed to STDOUT.
  62. -c CASE, --case=CASE Type of commands to use in each rule. Default is
  63. "all"; other options are "env", "echo", "cp" and "sed"
  64. The -t option specifies total the number of makefile targets. This should be a positive integer.
  65. The -d option specifies total the number of subdivisions of the makefile targets into level1/level2 targets.
  66. This should be a positive integer.
  67. The makefiles are structured in such as way, so that the dependency tree has three levels. The aim is to
  68. introduce some complexity into the makefile's dependency tree rather than just having a "flat" dependency tree.
  69. The top level in the dependency tree contains only one target called "main"; below this are the level2 targets
  70. which are all prerequisites of main; lastly are the level1 targets which split into groups and each group is
  71. the set of prerequisites for a level2 target.
  72. The size of these groups of level1 targets is <= DIVISIONS depending if DIVISIONS divides into TARGETS exactly or not.