2
0
mirror of https://github.com/boostorg/build.git synced 2026-02-14 12:42:11 +00:00
Commit Graph

571 Commits

Author SHA1 Message Date
Vladimir Prus
37c940b22a Add MD5 builtin
[SVN r54306]
2009-06-24 15:29:35 +00:00
Vladimir Prus
db326b704e Catch more macros.
Patch from John W. Bito


[SVN r53383]
2009-05-29 08:47:03 +00:00
Vladimir Prus
ca203a0784 Allow Boost.Build to override the value of -j.
[SVN r52171]
2009-04-04 18:55:37 +00:00
Vladimir Prus
e0c99b52e3 Include unistd.h
Fixes #2596.


[SVN r51896]
2009-03-21 23:12:15 +00:00
Rene Rivera
0e05fe1efb Bump to bjam 3.1.18.
[SVN r50014]
2008-11-29 14:53:55 +00:00
Rene Rivera
e5c8a80156 Update copyright dates.
[SVN r49991]
2008-11-28 16:45:19 +00:00
Rene Rivera
eaf63139cf Fix compiling with vacpp on non-AIX systems. (fixes #2546)
[SVN r49990]
2008-11-28 16:25:56 +00:00
Rene Rivera
98420f64fd Reflect the results of calling bjam from Python. (fixes #2112)
[SVN r49907]
2008-11-24 03:14:55 +00:00
Rene Rivera
a73c47e478 Oops, fix one thing, break another... Fix the final arg parsing for passing extra option args to the bjam build.
[SVN r49906]
2008-11-24 03:00:45 +00:00
Rene Rivera
007b6c34c0 Rework how arguments are parsed and tested to fix handling of quoted arguments, options arguments, and arguments with "=". (fixes #2113)
[SVN r49905]
2008-11-24 02:03:53 +00:00
Rene Rivera
9d5792c977 Try to work around at least one compiler bug with GCC and variable aliasing that causes crashes with hashing file cache entries.
[SVN r49890]
2008-11-23 05:33:26 +00:00
Rene Rivera
7da8330926 Add -Wc,-fno-strict-aliasing for QCC/QNX to avoid the same aliasing crashes as in the general GCC 4.x series (thanks to Niklas Angare for the fix). (fixes #2459)
[SVN r49889]
2008-11-23 05:15:51 +00:00
Rene Rivera
d9f5f12dee Oops, put quotes around one-too-many args.
[SVN r49888]
2008-11-23 05:00:56 +00:00
Rene Rivera
77eabb3506 Add quotes for most arguments when building bjam. This solves the problem of externally specified values, like the Python path, from breaking when they have spaces.
[SVN r49887]
2008-11-23 04:51:24 +00:00
Rene Rivera
72f8d348b1 Adjust error un/setting for compatibility with more Windows CMD versions. (fixes #1663)
[SVN r49884]
2008-11-23 03:27:54 +00:00
Rene Rivera
c26a94ffd8 Let the child bjam commands inherit stdin, as some commands assume it's available. (fixes #1577)
[SVN r49883]
2008-11-23 02:37:44 +00:00
Rene Rivera
c06917cd60 On Windows don't limit bjam output to ASCII as some tools output characters in extended character sets. (fixes #1576)
[SVN r49882]
2008-11-23 02:10:52 +00:00
Rene Rivera
1fc9bb7a64 Fix some possible overrun issues revealed by Fortify build. Thanks to Steven Robbins for pointing out the issues. (fixes #2527)
[SVN r49877]
2008-11-23 00:21:21 +00:00
Vladimir Prus
c549e85b34 Handle \n and \r escape sequences
[SVN r49775]
2008-11-15 22:02:35 +00:00
Rene Rivera
f2d1d169b8 Minor edits to remove -Wall warnings. (fixes 2207)
[SVN r48994]
2008-09-29 00:05:22 +00:00
Rene Rivera
3c8c7b6f30 Dynamically adjust pwd buffer query size to allow for when PATH_MAX is default defined instead of being provided by the system C library. (fixes #2206)
[SVN r48993]
2008-09-28 23:10:51 +00:00
Rene Rivera
110d5aca60 Minor perf improvement for bjam by replacing hash function with faster version. Only 1% diff for Boost tree.
[SVN r48617]
2008-09-05 16:26:45 +00:00
Jurko Gospodnetić
775ce8a7a9 Updated Boost Jam's error location reporting when parsing Jamfiles. Now it reports the correct error location information when encountering an unexpected EOF. It now also reports where an invalid lexical token being read started instead of finished which makes it much easier to find errors like unclosed quotes (") or curly braces ({).
[SVN r48534]
2008-09-02 11:06:24 +00:00
Jurko Gospodnetić
a3e53d37aa Refactored Boost Jam's internal yyline() Jamfile parsing function a bit so it no longer uses one unneeded goto that was making the code much harder to read.
[SVN r48533]
2008-09-02 10:58:03 +00:00
Jurko Gospodnetić
5de4d38337 Stylistic changes throughout the Boost Jam source base done while researching the Boost Jam internals. No implementation changes.
[SVN r48532]
2008-09-02 10:54:08 +00:00
Jurko Gospodnetić
b14209b789 Major stylistic changes throughout the Boost Jam source base. No implementation changes.
Cleanup done while researching the Boost Jam internals. Added better implementation description comments at many places. Cleaned up the 'dependant' and 'dependency' terminology that got mixed up in several places. Renamed several functions to use underscores as word separators.

[SVN r48480]
2008-08-30 23:56:49 +00:00
K. Noel Belcourt
d8a723ee41 Forgot to remove -xarch=generic from both sun
and sunpro toolsets.



[SVN r48465]
2008-08-29 20:51:13 +00:00
K. Noel Belcourt
3cd298ec00 Removed the -xarch=generic architecture from build.jam
as this option is unknown so the Sun compilers on Linux.
As -xarch=generic is the default on the Sun, there should
be no impact to the Sun platform.



[SVN r48464]
2008-08-29 20:44:31 +00:00
Jurko Gospodnetić
84c8a57403 Minor stylistic changes throughout Boost Jam sources. Mostly corrected indentation, removed trailing spaces and updated comments.
[SVN r48445]
2008-08-29 12:59:49 +00:00
Jurko Gospodnetić
0373a36dc0 Updated Boost Jam with minor stylistic changes in end-user messages when reporting on target fate. Fixed a bug with T_FATE_ISTMP getting reported as T_FATE_ISTMP & T_FATE_NEEDTMP at the same time due to a missing break in a switch statement.
[SVN r48431]
2008-08-29 00:16:40 +00:00
Jurko Gospodnetić
98ad6fda62 Fixed a Boost Jam bug causing it to sometimes trigger actions depending on targets that have not been built yet. Test case included. Updated related code comments.
Bug was happening when we had a multifile action that got triggered to build its non-initial target. Then while that action was being executed all the other targets were reporting as 'already built' and were getting used by other actions prematurely. Quick-fixed by making all targets built by a single action list each other as 'included' causing anything else depending on any of these targets to automatically depend on all the others in the group as well.

The solution is not perfect as it might have some unexpected interactions with other uses of 'included' targets and now if any target in a group is not up to date then all of them will be rebuilt even if actually did not need the target that was up to date. On the other hand this should be a really rare use case as it would require the one target in a group to be up to date and be needed while another in the same group (i.e. built by the same action) to not be up to date.

[SVN r48426]
2008-08-28 19:20:27 +00:00
Jurko Gospodnetić
62cd6929b4 Minor stylistic Boost Jam & Boost Build module changes.
[SVN r48301]
2008-08-23 03:12:27 +00:00
Jurko Gospodnetić
a7aec314cb Added Boost Jam support for executing command lines longer than 2047 characters (up to 8191) characters when running on Windows XP or later OS version. Patch contributed by Franz Schnyder.
See http://support.microsoft.com/default.aspx?scid=kb;en-us;830473 for more detailed information on Windows cmd.exe shell command-line length limitations.

[SVN r47913]
2008-07-31 17:41:40 +00:00
Jurko Gospodnetić
489682cc4a Fixed a Boost Jam bug on Windows causing its SHELL command not to work correctly with some commands containing quotes. Caused by a 'funny feature' in the Windows popen() implementation causing it to remove external quotes in some cases similar to how the Windows cmd.exe shell command interpreter does it.
[SVN r46106]
2008-06-03 23:44:23 +00:00
Jurko Gospodnetić
c0a697600f Corrected a potential memory leak in Boost Jam's builtin_shell() function that would appear should Boost Jam ever start to release its allocated string objects. Minor stylistic changes.
[SVN r46105]
2008-06-03 23:23:49 +00:00
Jurko Gospodnetić
2ddff3daba Made all Boost Jam's ECHO commands automatically flush the standard output to make that output more promptly displayed to the user.
[SVN r46104]
2008-06-03 23:19:58 +00:00
Jurko Gospodnetić
26923f6d45 Corrected the comment in src/build.bat to list all the currently supported toolsets when building Boost Jam.
[SVN r46103]
2008-06-03 23:16:33 +00:00
K. Noel Belcourt
2f46c0abcb Change execunix.c to always use fork() instead of
vfork() on the Mac.  This works around known issues
with bjam on PPC under Tiger and a problem reported
by Rene with bjam on x86 under Leopard.

A future revision will change execvp() use to execve()
to enable the Mac to once again use the more efficient
vfork() on the Mac.



[SVN r45956]
2008-05-30 16:22:39 +00:00
Jurko Gospodnetić
aa6e09d93d Corrected a bug in Boost Jam's base Jambase script causing it to trim the error message displayed when its boost-build rule gets called multiple times.
[SVN r45660]
2008-05-22 15:50:28 +00:00
Jurko Gospodnetić
0c99cb166a Minor stylistic changes made to Boost Jam's base Jambase script. Mainly trimmed trailing spaces and wrapped comments at 80 lines.
[SVN r45659]
2008-05-22 15:49:01 +00:00
Jurko Gospodnetić
4811e221e1 Minor stylistic changes made to Boost Jam's base Jambase script. Mainly trimmed trailing spaces and wrapped comments at 80 lines.
[SVN r45658]
2008-05-22 15:47:38 +00:00
Vladimir Prus
a5598a1abf When importing from Python into an module with empty string as name,
import into root module.


[SVN r45603]
2008-05-21 12:00:06 +00:00
Jurko Gospodnetić
f6e31ac68e Patch for the NORMALIZE_PATH builtin Boost Jam rule as well as an appropriate update for the path.jam Boost Build module where that rule was being used to implement path.join and related operations.
As it was written before the rule had 'random' behavior in some borderline cases such as: not passing it a parameter, passing it a folder whose path starts with one or two backslashes (as opposed to slashes) or passing it an invalid rooted path with enough '..' path elements to take it 'before the root path'. In those cases it would cause an access violation, 'incorrectly' un-root the path (i.e. remove the leading slash) or simply remove a 'random' path modification respectively. Also the rule is now more tiny bit more efficient and much better documented.

  Invalid rooted paths with enough '..' path elements to take them 'before the root path' are now recognized and an empty list is returned.

  Due to this rule having such 'messy' behavior the path.join rule and its user make-NT rule had some twisted logic in them to work around all the problems this caused. This patch invalidates the logic in question and replaces it with a much simpler one (detailed comments added).

  Other NORMALIZE_PATH callers should not be affected since both the old and the new version work the same on 'regular' paths (i.e. those not mentioned above).

  The new functionality for recognizing Boost Jam versions has been used to make Boost Build scripts use the old path functionality when using Boost Jam older than 3.1.17 and use the new functionality otherwise. As consequence, now anyone using the trunk version of Boost Build and an older 3.1.17 version of Boost.Jam will need to recompile their Boost Jam executable.

  The patch does not cause any Boost Build or Boost Jam tests to fail.

  Added a related NORMALIZE_PATH Boost Jam test. Note that this test causes Boost Jam versions built prior to this patch to crash (access violation).

  Added additional internal Boost Build tests for the path.jam module testing how it handles some invalid Windows paths.


[SVN r45158]
2008-05-05 22:37:19 +00:00
Jurko Gospodnetić
84a9f25f9f Fixed a bug causing Boost Jam not to handle target file names specified as both short and long file names correctly. Bug fixed by making bindtarget() function map names to TARGETs by using their long file names.
When scanning directories and creating a list of all their content (filent.c) it would identify all the located files and folders using their long file names. On the other hand, referencing a target using its short file name inside a Jam script caused Boost Jam to reference those files twice using two separate TARGET structures - one identified using the file's short name and one using the file's long name.

  One bad example was the MkDir which would always attempt to create a folder identified by its short name even if that folder already existed (due to the NOUPDATE rule getting applied on the incorrect TARGET).

  The change does not affect targets whose names do not represent existing file names.

  Also, it seems to me that the short_path_to_long_path() call in file_dirscan() in the filent.c module should most likely be moved to file_info() in the filesys.c module. This would make mapping file names to file_info_t & TARGET structures consistent. However, I have not done this in this patch just to make the patch as minimal as possible.

  Prepared tests have been do nothing on non Windows platforms.


[SVN r45144]
2008-05-05 15:52:56 +00:00
Jurko Gospodnetić
80ce6cfa53 Minor stylistic changes preparing for a more substantial patch without cluttering it with this.
[SVN r45105]
2008-05-04 03:19:19 +00:00
Jurko Gospodnetić
3ee59de995 Typo corrections & minor stylistic comment changes.
[SVN r44900]
2008-04-29 22:49:36 +00:00
Roland Schwarz
3423e10887 relaxed test, ignoring case of drive letter.
Thanks to Mat Marcus for the fix.

[SVN r44551]
2008-04-18 18:11:03 +00:00
Jurko Gospodnetić
1b601354c0 Implemented a patch contributed by Igor Nazarenko reimplementing the list_sort() function to use a C qsort() function instead of a hand-crafted merge-sort algorithm. Makes some list sortings (e.g. 1,2,1,2,1,2,1,2,...) extremely faster, in turn significantly speeding up some project builds.
[SVN r44195]
2008-04-11 21:03:06 +00:00
Jurko Gospodnetić
d7407a9ee1 Fixed a bug with bjam not handling the '\' root Windows path correctly without its drive letter being specified. One effect could be seen by MkDir rule on such a path always attempting to create its base folder even if that folder already exists. For example if you attempted to create folder '\Projects\XYZ\BuildDir' it would incorrectly think that '\Projects' folder does not exist and attempt to create it - thus causing the whole build to fail due to the underlying OS mkdir command failing.
This was caused by the file_dirscan() function in the filent.c module not working correctly when passed '\' as its dir. It then messed up when formatting its file-selection parameter for the _findfirst()/findfirst() API and constructed it as '\/*' which caused that API to fail and return -1 which was in turn being interpreted as 'file not found'.


[SVN r44088]
2008-04-07 10:32:09 +00:00
Jurko Gospodnetić
556474bbb2 Solved the problem with child process returning the value 259 (Windows constant STILL_ACTIVE) causing bjam never to detect that it exited and therefore keep running in an endless loop. Done by relying on the Windows WaitForMultipleObjects() function to detect when a process has exited instead of GetExitCodeProcess(). The later function's MSDN article (http://msdn2.microsoft.com/en-us/library/ms683189(VS.85).aspx) warns about this problem.
Solved the problem with bjam going into an active wait state, hogging up processor resources, when waiting for one of its child processes to terminate while not all of its available child process slots are being used. To see this bug in action, try compiling a simple C++ program on a 2 processor PC with the -j 2 command-line option and watching how much processor resources bjam uses while linking. Was caused by treating unused process slots as used in the try_wait() function, causing the WaitForMultipleObjects() Windows API call to exit instantly with an error which was then getting incorrectly interpreted as a timeout, starting the whole cycle anew.

  Solved a race condition between bjam's output reading/child process termination detection and the child process's output generation/termination which could have caused bjam not to collect the terminated process's final output.

  Extracted all GetExitCodeProcess() API calls into one location so it no longer gets called in three separate places.

  Minor comment changes in code touched by previous fixes.


[SVN r44087]
2008-04-07 09:55:18 +00:00