[Ada] gnatmake and gnatclean with projects are obsolete
Arnaud Charlet
charlet@adacore.com
Wed Jan 7 10:02:00 GMT 2015
A new warning is now issued when gnatmake or gnatclean sre invoke with -P
indicationg that it is now obsolete and that the support will be removed
in the next release.
Support for project files is an advanced feature that is no longer properly
supported by gnatmake, instead the proper support has been moved to the
gprbuild tool, which contains a separate, cleaner code base, and also
extra dependencies (e.g. on xmlada, and potentially gnatcoll in the future).
Tested on x86_64-pc-linux-gnu, committed on trunk
2015-01-07 Vincent Celier <celier@adacore.com>
* clean.adb (Gnatclean): Warn that 'gnatclean -P' is obsolete.
* make.adb (Initialize): Warn that 'gnatmake -P' is obsolete.
-------------- next part --------------
Index: make.adb
===================================================================
--- make.adb (revision 219191)
+++ make.adb (working copy)
@@ -6486,6 +6486,14 @@
Make_Failed ("-i and -D cannot be used simultaneously");
end if;
+ -- Warn about 'gnatmake -P'
+
+ if Project_File_Name /= null then
+ Write_Line
+ ("warning: gnatmake -P is obsolete and will not be available " &
+ "in the next release. Use gprbuild instead.");
+ end if;
+
-- If --subdirs= is specified, but not -P, this is equivalent to -D,
-- except that the directory is created if it does not exist.
Index: clean.adb
===================================================================
--- clean.adb (revision 219191)
+++ clean.adb (working copy)
@@ -1383,6 +1383,14 @@
if Project_File_Name /= null then
+ -- Warn about 'gnatclean -P'
+
+ if Project_File_Name /= null then
+ Put_Line
+ ("warning: gnatclean -P is obsolete and will not be available " &
+ "in the next release. Use gprclean instead.");
+ end if;
+
-- A project file was specified by a -P switch
if Opt.Verbose_Mode then
More information about the Gcc-patches
mailing list