Changeset 796

Show
Ignore:
Timestamp:
09/03/07 15:45:11 (1 year ago)
Author:
Gregor
Message:

MERGE: trunk r795

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • branches/tango/docs/ChangeLog

    r694 r796  
    1 SVN from 0.68: 
    2     - Added --test option to test built libraries. 
     1SVN from 0.72: 
     2        - Rebuild: Merged DMD 2.003. 
     3        - Improved incremental build speed. 
     4        - Fixed excludes to work with a larger variety of paths (see ticket #126). 
     5        - Added a warning for targets containing no files. 
     6 
     70.72 from 0.71: 
     8        - More DMD fixes - now always compiles one file at a time. 
     9        - Fixed -version=OSXUniversalBinary (see ticket #121). 
     10 
     110.71 from 0.70: 
     12        - Much-improved README.software_engineers. 
     13        - Fixed 'set' and 'add' commands (see ticket #102). 
     14        - Added 'error' and 'warn' hook commands (see ticket #103). 
     15        - Added 'binstall' subcommand (see ticket #105). 
     16        - Added 'noinstall' setting (see ticket #106). 
     17        - `dsss install` now installs .di files in libraries (see ticket #92). 
     18        - Added 'installdir' hook command (see ticket #84). 
     19        - Rebuild: Should now handle non-DMD compilers derived from DMD more 
     20          easily (see ticket #115). 
     21        - Rebuild: Fixed configuration's "include" option (see ticket #116). 
     22        - Rebuild: Fixed a crash bug with the highly-uncommon pragmas 
     23          containing declarations (see ticket #117). 
     24        - Added --config file for testing alternative dsss.conf's (see ticket 
     25          #109). 
     26        - Added --debug option (see ticket #108). 
     27        - Added .dsssrc support (see ticket #120). 
     28 
     290.70 from 0.69: 
     30        - Rebuild: Merged DMD 1.020. 
     31        - Should now trim whitespace in "name" (and other) settings (see 
     32          ticket #93). 
     33        - Now uses 'svn export' instead of 'svn co' (see ticket #96). 
     34        - Will now always remove temporary directories, even if the build 
     35          failed (I decided this wasn't worth the difficulty it causes). 
     36 
     370.69 from 0.68: 
     38        - Added --test option to test built libraries. 
     39        - Rebuild: Fixed an intermittent segfault on Windows. 
     40        - Added --doc-binaries option to generate documentation for binary 
     41          builds. 
     42        - Fixed DSSS_Light build. 
    343 
    4440.68 from 0.67: 
  • branches/tango/docs/NEWS

    r694 r796  
     12007-08-25: DSSS and Rebuild 0.72 released. 
     2 
     32007-08-15: DSSS and Rebuild 0.71 released. 
     4 
     52007-08-07: DSSS and Rebuild 0.70 released. 
     6 
     72007-08-03: DSSS and Rebuild 0.69 released. 
     8 
    192007-07-22: DSSS and Rebuild 0.68 released. 
    210 
  • branches/tango/docs/README.overview

    r654 r796  
    1 The D Shared Software System 
    2 ---------------------------- 
     1=== The D Shared Software System === 
    32 
    43DSSS, the D Shared Software System, is a tool to ease the building, 
     
    65 
    76 
    8 Building 
    9 -------- 
     7== Building == 
    108 
    119There are plenty of tools for building D software. There's bud (previously 
     
    2725 
    2826 
    29 Installation 
    30 ------------ 
     27== Installation == 
    3128 
    3229As compared to building software, there are few tools capable of installing D 
     
    4138 
    4239 
    43 Configuration 
    44 ------------- 
     40== Configuration == 
    4541 
    4642DSSS' build configuration file (dsss.conf) allows full use of version 
     
    4945 
    5046 
    51 Acquisition 
    52 ----------- 
     47== Acquisition == 
    5348 
    5449In the spirit of Perl's CPAN or Ruby's Gems, DSSS has a central repository of 
     
    6762 
    6863 
    69 More Information 
    70 ---------------- 
     64== More Information == 
    7165 
    7266DSSS is available from http://www.dsource.org/projects/dsss . It is FOSS 
  • branches/tango/docs/README.software_engineers

    r654 r796  
    1 DSSS is a tool to: 
     1= DSSS Documentation for Software Engineers = 
     2 
     3DSSS, the D Shared Software System, is a tool to: 
    24 
    35* Build D software. 
     
    79  via the Internet. 
    810 
    9 To the average software engineer, the most important part is dsss.conf, the 
    10 file added to your source code to configure how DSSS will compile it. 
    11  
    12 dsss.conf is a plain-text file, with a similar syntax to Windows INI files. It 
    13 can have any number of sections, each of which is headed with a name in 
    14 brackets, like so: 
    15 [foo/bar.d] 
    16  
    17  
    18 Most sections are named by a source file or directory. In general, sections 
    19 named for source files will generate binaries, and sections named for 
    20 directories will generate libraries. However, you can manually specify a 
    21 binary, library or sourcelibrary (like a library, but not compiled until it's 
    22 used in a binary) with the type setting: 
    23 [wholedirbinary] 
    24 type=binary 
    25  
    26 [onefilelibrary.d] 
     11This document explains the use of DSSS by software engineers wishing to use 
     12DSSS as a project management solution. 
     13 
     14 
     15== OVERVIEW == 
     16 
     17Software utilizing DSSS is configured with a file named "dsss.conf". This file 
     18describes the components of the complete software package and how each component 
     19should be built. 
     20 
     21dsss.conf files are plain text files, in a format similar to Windows INI files. 
     22They are intentionally minimalistic, and require very little maintenance to keep 
     23working. 
     24 
     25Because dsss.conf files are minimalistic, most software packages can be 
     26configured for use by DSSS with very simple dsss.conf files. For example, most 
     27software packages containing one binary can have a dsss.conf file like the 
     28following: 
     29[example.d] 
     30target = example_binary 
     31 
     32This is all you need for a simple application. DSSS will parse your imports, so 
     33you only need to list the file with the entry function (main). In most cases, 
     34DSSS is very easy to use. Simple instructions on basic dsss.conf files is 
     35available at http://www.dsource.org/projects/dsss/wiki/DSSSByExample 
     36 
     37 
     38== THE BASICS == 
     39 
     40dsss.conf files are divided into a number of sections. Most sections describes a 
     41single binary or library to be built. 
     42 
     43A section is started with the file name of the source module or package in 
     44brackets. File names should always be specified with '/' for the path 
     45separator. '\' will work on Windows, but is not portable. '/' works on all 
     46platforms. 
     47 
     48In general, sections which are named for modules produce binaries, and sections 
     49which are named for packages produce libraries. Each section may have any 
     50number of settings, which customize how that section is built. 
     51 
     52When running `dsss build`, sections are built in the order that they appear in 
     53the dsss.conf file, with the exception that binaries are always built last. 
     54 
     55= SETTINGS = 
     56 
     57Settings are simple name-value pairs which customize the building of sections. 
     58The format is simple: 
     59<name>=<value> 
     60 
     61For example, 
     62target=example_binary 
     63 
     64It is also possible to add to a setting: 
     65<name>+=<value> 
     66 
     67e.g.: 
     68a=Hello 
     69a+=World 
     70 
     71The setting 'a' is now 'Hello World'. This is most useful with versioning, 
     72described later. 
     73 
     74Some settings do not require values. In this case, the setting name alone is 
     75sufficient, such as: 
     76shared 
     77 
     78Settings may include references to environment variables: 
     79a=$PREFIX 
     80 
     81DSSS provides several environment variables for this purpose: 
     82PREFIX: The prefix to which the software is being installed. 
     83BIN_PREFIX: The prefix for binaries. 
     84LIB_PREFIX: The prefix for libraries. 
     85INCLUDE_PREFIX: The base prefix for .di files. 
     86DOC_PREFIX: The prefix for documentation. 
     87ETC_PREFIX: The prefix for configuration files. 
     88EXE_EXT: The extension for executable files. Empty on POSIX, ".exe" on Windows. 
     89DSSS: The full path to the DSSS binary itself. 
     90DSSS_BUILD: The full path to the build tool being used by DSSS (usually 
     91            rebuild). 
     92 
     93= FLAGS = 
     94 
     95Any section may have a 'buildflags' setting, which specifies the flags to be 
     96used while building that section. For example, 
     97buildflags=-O 
     98 
     99Flags for use with release and debug builds (when using --debug) can be 
     100specified separately in 'releaseflags' and 'debugflags', respectively. 
     101'debugflags' defaults to '-debug -gc'. 
     102 
     103= SECTION TYPES = 
     104 
     105Although section types are usually determined automatically from the section 
     106name, they may also be overridden with the 'type' setting: 
     107[oneFileLib.d] 
    27108type=library 
    28109 
    29 [onefilesrclib.d] 
     110The valid values for 'type' (all described in later sections) are: 
     111binary 
     112library 
     113sourcelibrary 
     114special 
     115subdir 
     116 
     117= BINARIES = 
     118 
     119Sections which are named for D modules (.d files) produce executable binaries 
     120when built with DSSS. The target binary file name will be deduced from the name 
     121of the .d file, or can be set explicitly with a 'target' line, such as: 
     122[example.d] 
     123target=example_binary 
     124 
     125Windows users: Be careful not to set the target of a binary build to the name of 
     126a directory. This will work on Windows because it gains the .exe suffix, but 
     127will fail on other operating systems. 
     128 
     129= LIBRARIES = 
     130 
     131Sections which are named for D packages (directories) produce libraries when 
     132built with DSSS. The name of the library file is derived from the name of the 
     133package and the platform. There is no reason to remember this name, however, 
     134because DSSS will detect library dependencies and link them in automatically. 
     135This name can partially be overridden if desired, in the same way as binaries: 
     136[mydpackage] 
     137target=dlibrary 
     138 
     139However, the platform will always affect the output library name. On POSIX 
     140systems, the above library will be named libSdlibrary.a and libdlibrary.so. On 
     141Windows, the above library will be named Sdlibrary.lib. 
     142 
     143By default, all of the .d files within the directory and any subdirectory will 
     144be included in the library. Files may be excluded with the 'exclude' setting: 
     145[mydpackage] 
     146exclude=mydpackage/broken.d 
     147 
     148Entire directories may also be excluded: 
     149[mydpackage] 
     150exclude=mydpackage/brokenpackage 
     151 
     152The 'exclude' setting is useful in concert with versioning, described in a later 
     153section. 
     154 
     155When using GDC on POSIX, it is also possible to build shared libraries (.so 
     156files). To specify that a shared library should be built, set the 'shared' 
     157option in the library's section: 
     158[mydpackage] 
     159shared 
     160 
     161You can set the .so file's version extension (the 1.2.3 in .so.1.2.3) with the 
     162soversion setting: 
     163[mydpackage] 
     164shared 
     165soversion=3.2.1 
     166 
     167= SOURCE LIBRARIES = 
     168 
     169Source libraries are libraries which are not compiled until they are used in a 
     170binary. They are installed in their source form. Otherwise, they act identically 
     171to normal libraries. A source library may be specified by setting the 'type' 
     172setting to 'sourcelibrary': 
     173[mydpackage] 
    30174type=sourcelibrary 
    31175 
    32  
    33 In each section, there can be any number of settings. Each setting is a 
    34 keyword, possibly followed by = or += and a value. For example, the "target" 
    35 setting sets the name of the output binary or library in a given section: 
    36 [main.d] 
    37 target=dzip 
    38  
    39 (In general, the target setting will be automatically set to something 
    40 sensible) 
    41  
    42  
    43 Sections creating libraries from directories will normally include all the .d 
    44 files in that directory or any subdirectory of it. You may also specify 
    45 subdirectories explicitly in dsss.conf, which will cause some .d files to be 
    46 reassigned. For example, if you have these files: 
    47 dzip/algorithm.d, foo/compression/zip.d 
    48 and a section: 
    49 [dzip] 
    50 then the produced library will include algorithm.d and zip.d. 
    51 If you have two sections: 
    52 [dzip] 
    53 [dzip/compression] 
    54 then two libraries will be produced: The library from 'dzip' will contain 
    55 algorithm.d, and the library from [dzip/compression] will contain zip.d. 
    56  
    57  
    58 Furthermore, content in dsss.conf can be set up as version-specific, with a 
    59 version keyword similar to the version keyword in D. For example, to make sure 
    60 that a certain binary is only produced on Windows: 
     176= SPECIAL SECTIONS = 
     177 
     178It is also possible to create sections which are not associated with compiling 
     179a binary or library. These sections are given names starting with a '+', such 
     180as: 
     181[+generate] 
     182 
     183The utility of these sections will be seen below, in the section on hooks. 
     184 
     185 
     186== INSTALLATION == 
     187 
     188DSSS is capable of installing binaries and libraries to a predetermined 
     189directory, usually the prefix in which it is installed. When libraries are 
     190installed in this way, they will be usable by DSSS without being explicitly 
     191specified. 
     192 
     193If a section should be built but not installed, set the 'noinstall' setting: 
     194[test.d] 
     195noinstall 
     196 
     197 
     198== DEPENDENCIES == 
     199 
     200The primary reason that DSSS exists is to make handling dependencies easier. To 
     201this end, is is never necessary to explicitly specify a dependency upon a 
     202library which is itself set up to use DSSS. Because DSSS traces D imports and 
     203keeps an Internet-accessible repository of package information, installing the 
     204dependencies which are supported by DSSS is as easy as typing: 
     205$ dsss net deps 
     206 
     207However, dependencies on non-DSSS D libraries or C libraries can be more 
     208complicated. 
     209 
     210= INCLUDE PATHS = 
     211 
     212It is possible to specify include paths in the 'buildflags' settings. Import 
     213paths are specified with the -I flag: 
     214buildflags=-I../prerequisite/import 
     215 
     216= PREREQUISITE LIBRARIES = 
     217 
     218Library search paths are specified with the -S flag: 
     219buildflags=-S../prerequisite/lib 
     220 
     221Libraries can be explicitly linked in with the -ll flag. -ll works similarly to 
     222-l in most compilers. On POSIX and similar platforms, a flag such as 
     223-ll<library> 
     224will link in a library named 
     225lib<library>.a (or lib<library>.so) 
     226 
     227On Windows (except GDC), the same flag will link a library named 
     228<library>.lib 
     229 
     230Libraries linked in with the -ll flag are searched for in the search paths 
     231specified by the -S flag. 
     232 
     233The -ll flag is only useful for explicitly linking libraries into binaries. If 
     234the DSSS-implemented library depends on a non-DSSS library, the dependency must 
     235be specified in a .d file which is part of the DSSS-implemented library. This 
     236is done with the 'link' pragma, which must always be specified within 
     237version(build): 
     238version (build) { 
     239    pragma(link, "example"); 
     240
     241 
     242The above example will cause any binary linked against the DSSS-implemented 
     243library to link against the library named libexample.a (or example.lib on 
     244Windows). 
     245 
     246 
     247== HOOKS == 
     248 
     249DSSS can run arbitrary commands while building software. There are a number of 
     250points at which commands can be run: before and after building, before and after 
     251installing, and before and after cleaning up. These commands are added to 
     252'prebuild', 'postbuild', 'preinstall', 'postinstall', 'preclean' and 'postclean' 
     253lines, respectively. 
     254 
     255Hook commands can be anything which can be run on the shell of the host system, 
     256such as: 
     257prebuild = echo Hello 
     258 
     259Any number of hook commands may be strung together between semicolons: 
     260prebuild = echo Hello ; echo World 
     261 
     262And may span multiple lines by ending each line with a backslash: 
     263prebuild = echo \ 
     264    Hello ; \ 
     265    echo World 
     266 
     267 
     268 
     269There are also a number of special, builtin commands available. 
     270 
     271= warn and error = 
     272 
     273A warning or error condition can be specified by the hook commands 'warn' and 
     274'error'. 
     275 
     276An example of 'error': 
     277version (!Posix) { 
     278    prebuild=error Only POSIX is supported. 
     279
     280 
     281An example of 'warn': 
     282version (Posix) { 
     283    prebuild=warn POSIX support is untested. 
     284
     285 
     286When an error hook command is run, building of course halts. 
     287 
     288= install = 
     289 
     290The 'install' command installs a file to the specified directory. If the 
     291directory does not exist, it is created. For example: 
     292postinstall = install docs/README $DOC_PREFIX 
     293 
     294Files installed in this way are recorded, so that they may be uninstalled 
     295easily. 
     296 
     297= installdir = 
     298 
     299'installdir' is similar to 'install', with the exception that it can install 
     300entire directories (and all of their subdirectories). The /content/ of the 
     301first directory will be installed into the second directory. 
     302 
     303= cd = 
     304 
     305The 'cd' command changes the current directory. It works exactly as on POSIX 
     306and Windows shells: 
     307prebuild = cd c_source ; make 
     308 
     309It is unnecessary to return to the original directory after 'cd'ing. The 
     310directory will be restored after the hook commands have finished. 
     311 
     312= .d files = 
     313 
     314Any .d file may be used as a command. It will be compiled and run on-the-fly: 
     315prebuild = generateBindings.d 
     316 
     317= set = 
     318 
     319The 'set' command sets a dsss.conf file setting while DSSS is actually running. 
     320The parameters are: 
     321set <section>:<setting> <value> 
     322 
     323It is also possible to omit the section from the command to set in the current 
     324section: 
     325set <setting> <value> 
     326 
     327The special section '*' may be used to set a setting in all sections: 
     328set *:<setting> <value> 
     329 
     330For example, 
     331set example.d:postbuild echo Hello 
     332 
     333'set' is most useful in concert with the 'eval' command (described below), as 
     334it can then be used to set dsss.conf file settings programatically. It is 
     335also usable independently of 'eval', but is no better than merely specifying 
     336the setting. 
     337 
     338= add = 
     339 
     340The 'add' command is identical to the 'set' command, except that it appends to 
     341the current value instead of replacing it. 
     342 
     343For example, 
     344add example.d:postbuild World 
     345 
     346= eval = 
     347 
     348The 'eval' command runs a specified command, captures its output, and then runs 
     349its output as a command. This allows for very general processes to be 
     350encapsulated into binaries, rather than the dsss.conf file itself. 
     351 
     352For example, imagine the scenario that some system specifics need to be detected 
     353and utilized in the building of a section. There can be a program, analyze.d, 
     354which does the analysis and outputs commands such as 
     355add *:postbuild echo Hello 
     356 
     357This program could be run and used with the hook command: 
     358prebuild=eval analyze.d 
     359 
     360 
     361== VERSIONING == 
     362 
     363dsss.conf files support version statements with a similar syntax to D's own 
     364version statements: 
     365 
    61366version (Windows) { 
    62  [dzip/windows.d] 
    63  target=dzip_for_windows 
    64 
    65  
    66 The version keyword in dsss.conf also supports negation: 
     367    postbuild=setupWindows.d 
     368} else version (Posix) { 
     369    postbuild=setupPosix.d 
     370
     371 
     372Unlike D, dsss.conf files support negative versions: 
     373 
    67374version (!Windows) { 
    68  [dzip/nonwindows.d] 
    69  target=dzip_for_nonwindows 
    70 
    71  
    72 The version statement also supports an 'else' clause
     375    postbuild=giveUserCandy.d 
     376
     377 
     378dsss.conf's version statements can be used at any point in the dsss.conf file. 
     379They can even conditionally include different sections
    73380version (Windows) { 
    74  [foo/windows.d] 
    75  target=foo_for_windows 
    76 } else { 
    77  [foo/notwindows.d] 
    78  target=foo_for_notwindows 
    79 
    80  
    81 The version statement in dsss.conf has a fairly strict syntax: the { must be on 
    82 the same line as the statement, and the version being tested must be in 
    83 parenthesis. 
    84  
    85  
    86 There are quite a few other settings supported: 
    87  
    88 * exclude 
    89   * Exclude a list of .d files from being included in a library: 
    90     exclude=foo.d bar.d 
    91  
    92 * buildflags 
    93   * Flags that will be added to the command line for rebuild when building this 
    94     section. 
    95  
    96 * prebuild, preinstall, preclean, predigen, postbuild, postinstall, postclean, 
    97   postdigen 
    98   * Commands to be run before or after (pre or post) building (build), 
    99     installing (install), cleaning (clean) or generating .di files (digen) for 
    100     the current section. Can be any number of ;-separated commands, and 
    101     supports some special command types: 
    102     * .d files. If a .d file is specified as a command, it will be compiled and 
    103       run. 
    104       * Notably, D files can always use DSSS' headers. That is, the package 
    105         'sss'. 
    106  
    107     * install: DSSS has an internal 'install' command, which takes the 
    108       following syntax: 
    109       install <file> <target directory> 
    110  
    111     * eval: Run a command (.d file or otherwise), and execute its result 
    112       * For example, the command could print "install chosen/file/to/install 
    113         $INCLUDE_PREFIX" 
    114  
    115     * set: Set a setting in DSSS' environment. The syntax is as follows: 
    116       * set <section>.<setting> <value> 
    117       * You may use * to apply a setting to all sections, or simply exclude the 
    118         section (but still include the .) to set a global setting. 
    119       * This is most useful when used via eval, as in: 
    120         eval detectsettings.d 
    121  
    122     * add: Like set, but adds to a setting. 
    123  
    124   * In any command, you can use environment variables with a '$', such as 
    125     $PREFIX. The following environment variables are provided by DSSS: 
    126     * $DSSS : The dsss binary, if you need to call DSSS recursively. Better 
    127       than counting on it being on the PATH. 
    128  
    129     * $PREFIX : The prefix to which the software is being installed. 
    130  
    131     * $BIN_PREFIX : The prefix to which binaries are being installed. 
    132  
    133     * $LIB_PREFIX : The prefix to which libraries are being installed. 
    134  
    135     * $INCLUDE_PREFIX : The prefix to which generated .di interface files are 
    136       being installed. 
    137       * This is the /base/ prefix, so for example the module foo.bar will be 
    138         installed to $INCLUDE_PREFIX/foo/bar.di 
    139       * This directory can also be used for .d files. 
    140  
    141     * $DOC_PREFIX : The prefix to which documentation is installed. 
    142  
    143     * $ETC_PREFIX : The prefix to which configuration files are being 
    144       installed. 
    145  
    146  
    147 Furthermore, there is a global section for settings which are not specific to 
    148 any binary or library. You can add settings to this section simply by adding 
    149 them before any section declarations, or by making an empty section declaration 
    150 like so: 
     381    [winlib] 
     382} else version (Posix) { 
     383    [posixlib] 
     384
     385type = library 
     386 
     387 
     388== GLOBAL SETTINGS == 
     389 
     390There are several settings that DSSS supports which are global. That is, they 
     391are specified for the software package as a whole, rather than any section. 
     392These are included at the top of the dsss.conf file. Common settings are 'name' 
     393(the name of the software package) and 'version'. 
     394 
     395There is also a global setting available to specify which sections should be 
     396built normally, 'defaulttargets'. Without it, all sections will be built by 
     397default. The section list is simply separated by spaces: 
     398defaulttargets=xlib xbin 
     399 
     400It is also possible to specify global settings later in the dsss.conf file by 
     401adding an empty section header: 
    151402[] 
    152 global_setting=0 
    153  
    154 The important global settings are 'name' (which will otherwise be gleaned from 
    155 the directory name) and 'version' (which will otherwise be set to 'latest'). 
    156 With these settings, a dsss.conf file would conventionally look something like 
    157 this: 
    158 name = dzip 
    159 version = 1.0 
    160 [dzip.d] 
    161 target = dzip 
    162  
    163  
    164 There is also a global setting, "requires", which may be used to explicitly 
    165 list dependencies: 
    166 requires = bintod 
    167 In general, it is NOT necessary to use this setting, as DSSS will detect 
    168 dependencies based on what is imported from the D source. 
    169  
    170  
    171 It is possible to add a setting to all sections with the special [*] section: 
    172 name = dzip 
    173 version = 1.0 
     403name=exampleSoft 
     404 
     405 
     406== DEFAULT SETTINGS == 
     407 
     408It is possible to create default settings with a special "*" section. This is 
     409most useful for settings such as 'buildflags': 
     410 
    174411[*] 
    175 buildflags=-g 
    176 [main.d] 
    177 target = dzipper 
    178 [dzip] 
    179  
    180  
    181 You can make 'special' build steps, which do not correspond to D source files 
    182 and so do not call the build tool, by naming them prefixed with a +. For 
    183 example: 
    184 [+genSource] 
    185 prebuild = gensource.d 
    186  
    187  
    188 It is possible to have source files spread out through several directories, and 
    189 to support this in dsss.conf there is the special type "subdir": 
    190 [subtool] 
    191 type = subdir 
    192  
    193 Each subdirectory must have its own dsss.conf . Note that setting type=subdir 
    194 will cause DSSS to recurse into that directory, but will not cause that 
    195 directory to be visible at compile time. If you want that feature, you will 
    196 need to add -I flags to buildflags: 
    197 name = dzip 
    198 version = 1.0 
     412buildflags=-O 
     413 
     414Note that any settings in a named section will override those in "*" sections. 
     415For example, in this situation: 
     416 
    199417[*] 
    200 buildflags=-g -Isubtool 
    201 [subtool] 
    202 type = subdir 
    203 [main.d] 
    204 target = dzipper 
    205 [dzip] 
    206  
    207  
    208 At build time, sections will be handled in the order that they appear in the 
    209 dsss.conf file, with the exception that binaries are always built last. By 
    210 default, every section will be built. This can be overridden with the global 
    211 option 'defaulttargets', which allows you to specify a list of targets to build 
    212 by default. All targets will be built if 'all' is explicitly specified on the 
    213 command line. 
     418buildflags=-O 
     419 
     420[mydlib] 
     421buildflags+=-release 
     422 
     423mydlib's buildflags are only "-release". 
     424 
     425 
     426== ADVANCED FEATURES == 
     427 
     428There are several advanced features of DSSS which do not need any modification 
     429to the dsss.conf file to use. 
     430 
     431The flag '--test', when passed to `dsss build`: 
     432$ dsss build --test 
     433will cause all of the unit tests to be run. 
     434 
     435The flag '--doc', when passed to `dsss build`: 
     436$ dsss build --doc 
     437will cause API documentation for every library to be generated with CandyDoc, 
     438which beautifies and organizes the documentation. 
     439 
     440 
     441To-be-written: 
     442== SUBDIRECTORIES == 
     443== NET INSTALLATION == 
  • branches/tango/docs/README.use

    r654 r796  
    22 
    33 
    4 Building Software with DSSS 
    5 --------------------------- 
     4== Building Software with DSSS == 
    65 
    76Most D software can be built with DSSS, but if it hasn't been set up for DSSS 
     
    3433$ dsss distclean 
    3534 
     35If you'd like certain flags to be included whenever you call DSSS, you can add 
     36them to your DSSS RC file: ~/.dsssrc on POSIX, dsss.rc next to dsss.exe on 
     37Windows. 
    3638 
    37 Installing Software with DSSS 
    38 ----------------------------- 
     39 
     40== Installing Software with DSSS == 
    3941 
    4042Some software can be used directly after building, but most software, libraries 
     
    5860 
    5961 
    60 Acquiring Software with DSSS 
    61 ---------------------------- 
     62== Acquiring Software with DSSS == 
    6263 
    6364A very convenient feature of DSSS is its ability to install software from the 
  • branches/tango/dsss.conf

    r694 r796  
    33[*] 
    44buildflags = -g 
     5 
    56version (OSXUniversalBinary) { 
    6     buildflags += -arch ppc -arch i386 
     7    [+OSXUniversalBinary] 
     8    prebuild += add *:buildflags -arch ppc -arch i386 
    79} 
    810 
     
    5254# Also install prerequisite binaries on Windows 
    5355version (Windows) { 
     56version (!DSSS_Light) { 
    5457    postinstall += ; \ 
    5558        getwinbins.d ; \ 
     
    7780        install winbins/zlib1.dll $BIN_PREFIX 
    7881} 
     82} 
    7983 
    8084target=dsss 
  • branches/tango/hcf/path.d

    r795 r796  
    190190        } 
    191191    } 
     192 
     193    // get rid of any introductory ./'s 
     194    while (ret.length > 2 && ret[0..2] == "." ~ FileConst.PathSeparatorChar) { 
     195        ret = ret[2..$]; 
     196    } 
    192197     
    193198    // finally, get rid of any trailing separators 
  • branches/tango/rebuild/Makefile

    r654 r796  
    22CXX=$(CROSS)g++ 
    33NATIVECXX=g++ 
    4 CXXFLAGS=-O2 -
     4CXXFLAGS=-
    55 
    66EXEEXT= 
     
    6666  struct.o \ 
    6767  template.o \ 
     68  traits.o \ 
    6869  unialpha.o \ 
    6970  utf.o \ 
  • branches/tango/rebuild/attrib.c

    r694 r796  
    258258    } 
    259259    else 
    260     buf->writeByte(':'); 
     260    buf->writeByte(';'); 
    261261    buf->writenl(); 
    262262} 
     
    880880    } 
    881881 
    882     if (decl) 
    883     { 
    884     for (unsigned i = 0; i < decl->dim; i++) 
    885     { 
    886         Dsymbol *s = (Dsymbol *)decl->data[i]; 
    887  
    888         s->semantic(sc); 
    889     } 
    890     } 
    891882    return; 
    892883 
     
    12011192    exp = exp->optimize(WANTvalue | WANTinterpret); 
    12021193    if (exp->op != TOKstring) 
    1203     {   error("argument to mixin must be a string, not (%s)", exp->toChars()); 
     1194    {   //error("argument to mixin must be a string, not (%s)", exp->toChars()); 
    12041195    return; 
    12051196    } 
     
    12121203    if (p.token.value != TOKeof) 
    12131204    { 
    1214     error("incomplete mixin declaration (%s)", se->toChars()); 
     1205    //error("incomplete mixin declaration (%s)", se->toChars()); 
    12151206    } 
    12161207 
  • branches/tango/rebuild/cast.c

    r694 r796  
    11 
    2 // Copyright (c) 1999-2006 by Digital Mars 
     2// Copyright (c) 1999-2007 by Digital Mars 
    33// All Rights Reserved 
    44// written by Walter Bright 
     
    3232Expression *Expression::implicitCastTo(Scope *sc, Type *t) 
    3333{ 
    34     //printf("implicitCastTo(%s) => %s\n", type->toChars(), t->toChars()); 
     34    //printf("Expression::implicitCastTo(%s) => %s\n", type->toChars(), t->toChars()); 
     35    //printf("%s\n", toChars()); 
     36 
    3537    if (implicitConvTo(t)) 
    3638    { 
     
    6163t->print(); 
    6264printf("%p %p type: %s to: %s\n", type->deco, t->deco, type->deco, t->deco); 
    63 //printf("%p %p %p\n", type->next->arrayOf(), type, t); 
     65//printf("%p %p %p\n", type->nextOf()->arrayOf(), type, t); 
    6466fflush(stdout); 
    6567#endif 
     
    7880    error("forward reference to type %s", t->reliesOnTident()->toChars()); */ 
    7981 
    80     error("cannot implicitly convert expression (%s) of type %s to %s", 
    81     toChars(), type->toChars(), t->toChars()); 
     82    /* error("cannot implicitly convert expression (%s) of type %s to %s", 
     83    toChars(), type->toChars(), t->toChars()); */ 
    8284    return castTo(sc, t); 
    8385} 
     
    8890 */ 
    8991 
    90 int Expression::implicitConvTo(Type *t) 
     92MATCH Expression::implicitConvTo(Type *t) 
    9193{ 
    9294#if 0 
     
    98100    type = Type::terror; 
    99101    } 
    100     if (t->ty == Tbit && isBit()) 
    101     return MATCHconvert; 
    102102    Expression *e = optimize(WANTvalue | WANTflags); 
    103103    if (e != this) 
     
    105105    return e->implicitConvTo(t); 
    106106    } 
    107     int match = type->implicitConvTo(t); 
    108     if (match
     107    MATCH match = type->implicitConvTo(t); 
     108    if (match != MATCHnomatch
    109109    return match; 
    110110#if 0 
     
    112112    if (tb->ty == Tdelegate) 
    113113    {   TypeDelegate *td = (TypeDelegate *)tb; 
    114     TypeFunction *tf = (TypeFunction *)td->next
     114    TypeFunction *tf = (TypeFunction *)td->nextOf()
    115115 
    116116    if (!tf->varargs && 
     
    118118       ) 
    119119    { 
    120         match = type->implicitConvTo(tf->next); 
     120        match = type->implicitConvTo(tf->nextOf()); 
    121121        if (match) 
    122122        return match; 
    123         if (tf->next->toBasetype()->ty == Tvoid) 
     123        if (tf->nextOf()->toBasetype()->ty == Tvoid) 
    124124        return MATCHconvert; 
    125125    } 
     
    130130 
    131131 
    132 int IntegerExp::implicitConvTo(Type *t) 
     132MATCH IntegerExp::implicitConvTo(Type *t) 
    133133{ 
    134134#if 0 
     
    139139    return MATCHexact; 
    140140 
    141     enum TY ty = type->toBasetype()->ty; 
    142     enum TY toty = t->toBasetype()->ty; 
     141    TY ty = type->toBasetype()->ty; 
     142    TY toty = t->toBasetype()->ty; 
    143143 
    144144    if (type->implicitConvTo(t) == MATCHnomatch && t->ty == Tenum) 
    145     return MATCHnomatch
     145    goto Lno
    146146 
    147147    switch (ty) 
     
    299299        goto Lyes; 
    300300    } 
     301 
     302    case Tpointer: 
     303//printf("type = %s\n", type->toBasetype()->toChars()); 
     304//printf("t = %s\n", t->toBasetype()->toChars()); 
     305        if (ty == Tpointer && 
     306            type->toBasetype()->nextOf()->ty == t->toBasetype()->nextOf()->ty) 
     307        {   /* Allow things like: 
     308         *  const char* P = cast(char *)3; 
     309         *  char* q = P; 
     310         */ 
     311        goto Lyes; 
     312        } 
     313        break; 
    301314    } 
    302315    return Expression::implicitConvTo(t); 
     
    309322} 
    310323 
    311 int NullExp::implicitConvTo(Type *t) 
     324MATCH NullExp::implicitConvTo(Type *t) 
    312325{ 
    313326#if 0 
     
    318331    return MATCHexact; 
    319332    // NULL implicitly converts to any pointer type or dynamic array 
    320     if (type->ty == Tpointer && type->next->ty == Tvoid) 
     333    if (type->ty == Tpointer && type->nextOf()->ty == Tvoid) 
    321334    { 
    322335    if (t->ty == Ttypedef) 
     
    330343}