project Add_Attr6_Vars is

   type A_Type is
      ("1", "2", "3");
   A : A_Type := external ("A");
   type B_Type is
      ("B1", "B2", "B3");
   B : B_Type := external ("B");

end Add_Attr6_Vars;

with "add_attr6_vars";

project Add_Attr6 is

   type A_Type is
      ("1", "2", "3");
   type B_Type is
      ("B1", "B2", "B3");
   B : B_Type := external ("B");
   A : A_Type := external ("A");

   case B is

      when "B3" =>
         for Object_Dir use ".";

      when "B2" =>
         for Object_Dir use ".";

      when "B1" =>

         case A is

            when "3" =>
               for Object_Dir use ".";

            when "2" =>
               for Object_Dir use ".";

            when "1" =>
               for Object_Dir use "new_obj_dir";
         end case;
   end case;

end Add_Attr6;

