Commit Graph

118 Commits

Author SHA1 Message Date
Thomas Nagy b1f5c0f814
Create installation tasks directly
Task generators created from other task generators may be
skipped during partial builds. This change re-enables
install_task as a task attribute and provides a task
object with input and output nodes which can be re-used
by other tasks.
2016-05-06 15:54:36 +02:00
Thomas Nagy 5511593318
Move boring Build.inst construction details to the class 2016-05-06 11:12:54 +02:00
Thomas Nagy 9991004343
Extract Build.inst.run_now 2016-05-06 09:57:01 +02:00
Thomas Nagy 20b62a4eea
docs 2016-05-06 09:11:31 +02:00
Thomas Nagy eb62ce7620
Set post_mode=POST_LAZY by default to process the next build groups once build files are present 2016-04-30 15:10:16 +02:00
Thomas Nagy a7dac255af
Fix an error in the progress bar 2016-04-30 14:24:46 +02:00
Thomas Nagy b59a04a086
Moved the garbage collection code to the object owner 2016-04-28 20:12:20 +02:00
Thomas Nagy 3e86ea6cb8
Fixed an accidental dependency on inst.dest 2016-04-28 00:33:34 +02:00
Thomas Nagy 1eaa87413d
Refactor bld.install_as/bld.install_files/bld.symlink_as to use actual task objects 2016-04-28 00:23:54 +02:00
Thomas Nagy 8520dd65bb
Code cleanup 2016-04-19 22:00:21 +02:00
Thomas Nagy e35d3628d2
Add EnvContext to simplify configuration-dependent command definition 2016-04-11 23:28:33 +02:00
Thomas Nagy a08aff6bff
Format debug/info records lazily 2016-03-19 14:46:22 +01:00
Thomas Nagy 83c237ffe0
Redundant repr() call 2016-03-12 12:35:09 +01:00
Thomas Nagy d81dfac34e
docs 2016-03-12 12:32:27 +01:00
Thomas Nagy b4437f3b51
Exception handling enhancements 2016-02-28 14:23:54 +01:00
Thomas Nagy 7e16c7cb1e
Removed bld.returned_tasks 2016-02-15 23:52:11 +01:00
Thomas Nagy 437bfda8d1
Use waflib.Build.SAVED_ATTRS for serialization and initialization
The purpose is to make it easier to serialize additional dicts
on BuildContext instances.
2016-02-14 11:10:38 +01:00
Thomas Nagy 6124ee6975
Removed an old and unnecessary wrapper for objects in deps_man 2016-02-09 22:03:20 +01:00
Thomas Nagy f7ed95d60e
Missing configuration files should raise an instance of WafError 2016-02-08 22:41:12 +01:00
Thomas Nagy d23490287a
Code simplifications - use enumerate 2016-01-06 14:53:18 +01:00
Thomas Nagy e36420d68b
No chmod value for symlink_as at this time 2016-01-02 01:10:08 +01:00
Thomas Nagy 96a4487a57 New option to install files when symlinks are not possible 2015-12-24 22:45:27 +01:00
Thomas Nagy 5a3a89b4de Stop adding incompatible task data into the same dict objects 2015-12-24 18:36:48 +01:00
Thomas Nagy 7681bddfb7 Remove Node.sig and Node.cache_sig 2015-12-23 17:55:44 +01:00
Thomas Nagy cd7579a727
Do not try to post all task generator when installing, that will not work 2015-11-10 19:47:19 +01:00
Thomas Nagy 0357db5156
Fail faster on invalid install_files inputs - Issue 1639 2015-10-15 20:07:05 +02:00
Thomas Nagy 4708b1b730
Workaround for an IronPython pickle bug 2015-10-07 01:11:36 +02:00
Thomas Nagy 140453a959
Prevent installation tasks having postpone=False from running twice 2015-07-07 20:58:58 +02:00
Thomas Nagy 1b65d73c56
Unraised exception in get_targets, get_tgen_by_name already raises one 2015-03-05 03:16:28 +01:00
Thomas Nagy 7ffd53b803
Use EnvironmentError more often 2014-10-30 19:09:53 +01:00
Thomas Nagy 1979e7425c
Cosmetic changes 2014-10-04 02:02:38 +02:00
Thomas Nagy 6ffde12338
Use os.path.join to enable builds from drive letters X:\ 2014-08-30 13:05:46 +02:00
Thomas Nagy 81ce0b6c17
max path limitation in file installation - Issue 1469 2014-08-04 15:17:28 +02:00
Thomas Nagy e48ed4d37a
Issue 1465 2014-07-14 19:59:01 +02:00
Syl 2db34905bd fixed --make-waf with python3 2014-07-06 17:41:54 +02:00
Matt Hoosier 78c9384e1c
Improve support for BuildContext.install_*() to overwrite exiting files
A request such as:

  def build(bld):
    bld.install_files('/usr/share/foo/', bld.path.find_node('foo.txt'),
                      chmod=0444)

Will currently cause an IOError (especially on Windows) upon repeated
requests to invoke 'waf install'. This is due to a wedged state in
which the first 'waf intall' makes the destination file with 0444
permissions, but the OS (again, especially Windows) refuses to honor
subsequent attempts to write the file as the current
InstallContext.do_install() handles this attempt.

This changeset adjusts InstallContext.do_install() so that its
behavior is more similar to the familiar 'install' program used during
an Autotools programs' "make install" phase. That is, we now
explicitly attempt to temporarily adjust the permissions of the target
file to include user-writability (0644) for the moment of overwrite.
This has no observable effect on the end result; the last bit of
InstallContext.do_install() forcibly resets the target file to the
user's requested permission mask anyway.

Signed-off-by: Thomas Nagy <tnagy2pow10@gmail.com>
2014-06-29 22:25:16 +02:00
Thomas Nagy f4185e7a26 Added global file installation pointcut 2014-02-17 00:26:58 +01:00
Thomas Nagy d413616400 The progress bar should always appear on stderr 2014-01-23 22:22:15 +01:00
Thomas Nagy fbb7a0e720
Merge from Jerome's branch 2014-01-16 02:03:53 +01:00
Thomas Nagy a29f775851 Merge from Jerome's branch 2014-01-14 02:31:08 +01:00
Thomas Nagy 9ec230fb4d cleanup 2013-09-29 23:45:36 +02:00
Thomas Nagy dedafdfa81 Disabled the pickle gc optimization by default (computers are fast enough now, and it can be reenabled if necessary) 2013-09-10 21:28:25 +02:00
Thomas Nagy 5c6d626048 removed the cache from the task level, it usually degrades performance and is better implemented on the compiler level 2013-05-26 10:14:49 +02:00
Thomas Nagy 5b3dc2c5ab apidoc fixes 2013-05-25 22:49:22 +02:00
Thomas Nagy 6d570f08bd use os.remove instead of os.unlink for consistency 2013-05-18 19:51:45 +02:00
Thomas Nagy 174b01bba9 Issue 1313 extra check_dir call causing uninstall failures 2013-05-16 08:33:05 +02:00
Thomas Nagy 7eef6588af Use Utils.readf/Utils.writef whenever possible 2013-03-14 13:45:10 +01:00
Thomas Nagy 083b6e138e Issue 1234 2012-12-15 00:32:20 +01:00
Anthony Baire 2c22ec2a59 fixed `waf clean` to preserve config files from all environments
Signed-off-by: Thomas Nagy <tnagy2pow10@gmail.com>
2012-10-05 00:07:59 +02:00
Thomas Nagy 85d863bd52 Issue 1205 2012-10-02 03:43:58 +02:00
Thomas Nagy 56636cf5ff Removed a function too early - this is what happens when no example is present 2012-09-17 23:30:22 +02:00
Thomas Nagy 41c52e3f4e return the task generator instance (much more intuitive) 2012-09-15 21:27:50 +02:00
Thomas Nagy 54e3a901dd docs 2012-09-15 12:53:47 +02:00
Thomas Nagy 69edfa1675 bld.func -> bld.rule() 2012-09-15 12:16:53 +02:00
Anthony Baire c5bc3197f0 added Build.func to allow creating task generator using the decorator notation
Signed-off-by: Thomas Nagy <tnagy2pow10@gmail.com>
2012-09-15 12:14:25 +02:00
Thomas Nagy 3ee50382fb use the compact pickle files (faster) 2012-07-30 18:35:17 +02:00
Thomas Nagy 315973e243 Build::get_all_task_gen 2012-04-13 01:24:43 +02:00
Thomas Nagy 6db0d97fba Fix related to Issue 1124 2012-04-12 08:30:45 +02:00
Thomas Nagy 898872699d removed the macro DLL_EXPORT for gcc/g++ on windows and cleaned up a few TODO entries 2012-04-07 10:54:40 +02:00
Thomas Nagy 19f6fb2595 Issue 1124 2012-04-07 09:59:05 +02:00
Thomas Nagy c7a41fc9f6 Issue 1128 2012-03-25 10:33:57 +02:00
Thomas Nagy 67a3320c4a accept lists in bld.add_manual_dependency 2012-03-24 11:37:48 +01:00
Thomas Nagy 1134de1bb5 Issue 1120 2012-02-25 16:47:30 +01:00
Thomas Nagy d8f192fbc2 remove more except: lines 2012-02-11 14:31:00 +01:00
Thomas Nagy 19adba7841 added a warning for ant_glob on the build directory 2011-12-02 19:13:30 +01:00
Thomas Nagy a115091e20 docs 2011-11-18 00:33:25 +01:00
Thomas Nagy 71efd9b435 a more robust way of loading environment variants 2011-10-16 08:41:21 +02:00
Thomas Nagy 44a967e326 Initial commit 2011-09-10 11:13:51 +02:00