Skip to content

Commit 1f1a326

Browse files
committed
Avoid shared.gpr project file
as suggested by Alire documentation to minimize project file clashes.
1 parent cdf7493 commit 1f1a326

9 files changed

+39
-37
lines changed

.gitignore

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ po/Makefile
2020
b~*.ad*
2121
config.log
2222
config.status
23-
shared.gpr
23+
gtk_shared.gpr
2424
contrib/generated/*.ad?
2525
contrib/generated/tmp.ada
2626
src/Makefile.common

Makefile.in

+1-1
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ clean-generic:
142142
-${RM} .\#*
143143

144144
mostlyclean-generic: clean-generic
145-
-${RM} Makefile src/config.h shared.gpr
145+
-${RM} Makefile src/config.h gtkada_shared.gpr
146146
-${RM} testgtk/opengl/view_gl.adb
147147

148148
clean/%: force

configure

+2-2
Original file line numberDiff line numberDiff line change
@@ -4369,7 +4369,7 @@ fi
43694369

43704370
libdir='${prefix}/lib'
43714371

4372-
ac_config_files="$ac_config_files Makefile shared.gpr po/Makefile docs/gtkada_rm/html/static/index.html"
4372+
ac_config_files="$ac_config_files Makefile gtkada_shared.gpr po/Makefile docs/gtkada_rm/html/static/index.html"
43734373

43744374
cat >confcache <<\_ACEOF
43754375
# This file is a shell script that caches the results of configure
@@ -5077,7 +5077,7 @@ for ac_config_target in $ac_config_targets
50775077
do
50785078
case $ac_config_target in
50795079
"Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
5080-
"shared.gpr") CONFIG_FILES="$CONFIG_FILES shared.gpr" ;;
5080+
"gtkada_shared.gpr") CONFIG_FILES="$CONFIG_FILES gtkada_shared.gpr" ;;
50815081
"po/Makefile") CONFIG_FILES="$CONFIG_FILES po/Makefile" ;;
50825082
"docs/gtkada_rm/html/static/index.html") CONFIG_FILES="$CONFIG_FILES docs/gtkada_rm/html/static/index.html" ;;
50835083

configure.ac

+1-1
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ AM_PATH_GTK
4040

4141
libdir='${prefix}/lib'
4242

43-
AC_OUTPUT(Makefile shared.gpr po/Makefile docs/gtkada_rm/html/static/index.html)
43+
AC_OUTPUT(Makefile gtkada_shared.gpr po/Makefile docs/gtkada_rm/html/static/index.html)
4444

4545
AC_MSG_NOTICE([--------- Summary for Gtkada $PACKAGE_VERSION -----------------])
4646
AC_MSG_NOTICE(AC_HELP_STRING(

gtkada_gps.gpr

+3-3
Original file line numberDiff line numberDiff line change
@@ -25,13 +25,13 @@ with "testgtk/testgtk";
2525
with "src/gtkada";
2626
with "src/opengl/opengl";
2727
with "src/tools/tools";
28-
with "shared";
28+
with "gtkada_shared";
2929
with "contrib/contrib";
3030

3131
project GtkAda is
3232
for Source_Files use ();
3333
for Object_Dir use "src/obj";
3434

35-
package IDE renames Shared.IDE;
36-
package Documentation renames Shared.Documentation;
35+
package IDE renames GtkAda_Shared.IDE;
36+
package Documentation renames GtkAda_Shared.Documentation;
3737
end GtkAda;

shared.gpr.in gtkada_shared.gpr.in

+6-4
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323

2424
with "gtk";
2525

26-
project Shared is
26+
project GtkAda_Shared is
2727

2828
type Build_Type is ("Debug", "Production");
2929
Build : Build_Type := external ("BUILD", "@BUILD_TYPE@");
@@ -84,9 +84,11 @@ project Shared is
8484

8585
case Build is
8686
when "Debug" =>
87-
for Global_Configuration_Pragmas use Shared'Project_Dir & "src/gnat_debug.adc";
87+
for Global_Configuration_Pragmas use
88+
GtkAda_Shared'Project_Dir & "src/gnat_debug.adc";
8889
when "Production" =>
89-
for Global_Configuration_Pragmas use Shared'Project_Dir & "src/gnat.adc";
90+
for Global_Configuration_Pragmas use
91+
GtkAda_Shared'Project_Dir & "src/gnat.adc";
9092
end case;
9193
end Builder;
9294

@@ -111,4 +113,4 @@ project Shared is
111113
for Documentation_Dir use "html";
112114
end Documentation;
113115

114-
end Shared;
116+
end GtkAda_Shared;

src/gtkada.gpr

+16-16
Original file line numberDiff line numberDiff line change
@@ -21,32 +21,32 @@
2121
-- --
2222
------------------------------------------------------------------------------
2323

24-
with "../shared";
24+
with "../gtkada_shared";
2525

2626
library project GtkAda is
27-
case Shared.Need_Objective_C is
27+
case GtkAda_Shared.Need_Objective_C is
2828
when "yes" => for Languages use ("C", "Ada", "Objective-C");
2929
when "no" => for Languages use ("C", "Ada");
3030
end case;
3131

32-
Version := Shared.Version;
32+
Version := GtkAda_Shared.Version;
3333

3434
-- Put "generated" first, so that files are preferably taken from there
3535
-- even if they still exist in "."
3636
for Source_Dirs use ("generated", ".");
3737

38-
for Library_Kind use Shared.Library_Kind;
38+
for Library_Kind use GtkAda_Shared.Library_Kind;
3939
for Library_Name use "gtkada";
4040
for Library_Version use
41-
"lib" & Project'Library_Name & Shared.So_Ext & "." & Version;
41+
"lib" & Project'Library_Name & GtkAda_Shared.So_Ext & "." & Version;
4242

43-
case Shared.Library_Kind is
43+
case GtkAda_Shared.Library_Kind is
4444
when "static-pic" | "relocatable" =>
4545
-- Objects used for static-pic and relocatable are exactly the same
4646
for Object_Dir use "obj/gtkada/relocatable";
4747
for Library_Dir use "lib/gtkada/relocatable";
4848
when "static" =>
49-
case Shared.So_Ext is
49+
case GtkAda_Shared.So_Ext is
5050
when ".dll" | ".dylib" =>
5151
-- On Windows and Darwin, objects are always position
5252
-- independent.
@@ -60,22 +60,22 @@ library project GtkAda is
6060
end case;
6161
end case;
6262

63-
case Shared.Library_Kind is
63+
case GtkAda_Shared.Library_Kind is
6464
when "relocatable" =>
65-
for Leading_Library_Options use Shared.Ldflags;
66-
for Library_Options use Shared.Gtk_Libs;
65+
for Leading_Library_Options use GtkAda_Shared.Ldflags;
66+
for Library_Options use GtkAda_Shared.Gtk_Libs;
6767
when others =>
6868
null;
6969
end case;
7070

71-
package Builder renames Shared.Builder;
72-
package Naming renames Shared.Naming;
73-
package Compiler renames Shared.Compiler;
74-
package Binder renames Shared.Binder;
75-
package IDE renames Shared.IDE;
71+
package Builder renames GtkAda_Shared.Builder;
72+
package Naming renames GtkAda_Shared.Naming;
73+
package Compiler renames GtkAda_Shared.Compiler;
74+
package Binder renames GtkAda_Shared.Binder;
75+
package IDE renames GtkAda_Shared.IDE;
7676

7777
package Linker is
78-
for Linker_Options use Shared.Gtk_Libs;
78+
for Linker_Options use GtkAda_Shared.Gtk_Libs;
7979
end Linker;
8080

8181
package Install is

src/tools/tools.gpr

+6-6
Original file line numberDiff line numberDiff line change
@@ -22,20 +22,20 @@
2222
------------------------------------------------------------------------------
2323

2424
with "../gtkada";
25-
with "../../shared";
25+
with "../../gtkada_shared";
2626

2727
project Tools is
2828
for Main use ("gdialog.adb");
2929
for Object_Dir use "../obj/tools/";
3030

3131
package Builder is
32-
for Switches ("Ada") use Shared.Builder'Switches ("Ada");
32+
for Switches ("Ada") use GtkAda_Shared.Builder'Switches ("Ada");
3333
for Executable ("gdialog.adb") use "gtkada-dialog";
3434
end Builder;
3535

36-
package Compiler renames Shared.Compiler;
37-
package Binder renames Shared.Binder;
38-
package Linker renames Shared.Linker;
39-
package IDE renames Shared.IDE;
36+
package Compiler renames GtkAda_Shared.Compiler;
37+
package Binder renames GtkAda_Shared.Binder;
38+
package Linker renames GtkAda_Shared.Linker;
39+
package IDE renames GtkAda_Shared.IDE;
4040

4141
end Tools;

testgtk/testgtk.gpr

+3-3
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
-- --
2222
------------------------------------------------------------------------------
2323

24-
with "../shared";
24+
with "../gtkada_shared";
2525
with "../src/gtkada";
2626
with "task_project/task_project";
2727

@@ -36,10 +36,10 @@ project TestGtk is
3636
package Compiler is
3737
-- subprogram specs not required in testgtk
3838
for Switches ("Ada") use ("-g", "-O0", "-gnaty-s", "-gnatwJ")
39-
& Shared.Adaflags;
39+
& GtkAda_Shared.Adaflags;
4040
end Compiler;
4141

42-
package Linker renames Shared.Linker;
42+
package Linker renames GtkAda_Shared.Linker;
4343

4444
package Install is
4545
for artifacts ("share/examples/gtkada/testgtk") use

0 commit comments

Comments
 (0)