Commit 2bbd1b82 authored by yoogx's avatar yoogx

Merge branch 'master' of https://github.com/OpenAADL/ocarina

parents d8cd7bfc bf46eacf
...@@ -54,11 +54,9 @@ install-exec-local: ...@@ -54,11 +54,9 @@ install-exec-local:
$(INSTALL) -d $(DESTDIR)$(datadir)/doc $(INSTALL) -d $(DESTDIR)$(datadir)/doc
$(INSTALL) -d $(DESTDIR)$(datadir)/doc/ocarina $(INSTALL) -d $(DESTDIR)$(datadir)/doc/ocarina
$(INSTALL_SCRIPT) ocarina-config $(DESTDIR)$(bindir) $(INSTALL_SCRIPT) ocarina-config $(DESTDIR)$(bindir)
$(INSTALL_DATA) $(srcdir)/ChangeLog $(DESTDIR)$(datadir)/doc/ocarina/ChangeLog_ocarina
uninstall-local: uninstall-local:
rm -f $(DESTDIR)$(bindir)/ocarina-config rm -f $(DESTDIR)$(bindir)/ocarina-config
rm -f $(DESTDIR)$(datadir)/doc/ocarina/ChangeLog_ocarina
release: release:
rm -rf release/ rm -rf release/
......
...@@ -432,7 +432,6 @@ if test ${dotests} = "true" ; then ...@@ -432,7 +432,6 @@ if test ${dotests} = "true" ; then
;; ;;
*) *)
if test -r ${gprfile} ; then if test -r ${gprfile} ; then
ocarina_gpr="`ocarina-config --projects`" ocarina_gpr="`ocarina-config --projects`"
command="gnatmake -P\"`${path_conv} ${gprfile}`\" -aP${ocarina_gpr} -XOBJ_DIR=\"`${path_conv} ${tmpdir}`\"" command="gnatmake -P\"`${path_conv} ${gprfile}`\" -aP${ocarina_gpr} -XOBJ_DIR=\"`${path_conv} ${tmpdir}`\""
...@@ -451,7 +450,13 @@ if test ${dotests} = "true" ; then ...@@ -451,7 +450,13 @@ if test ${dotests} = "true" ; then
"${command}" \ "${command}" \
"" \ "" \
"${actual_output}" "${actual_output}"
failures=`expr ${failures} + 1`
# We do not increase the number of
# failures for compiled files, as those
# are dependent on external conditions,
# e.g. enabling code coverage, etc.
# failures=`expr ${failures} + 1`
else else
./`basename ${file} .adb` >${actual_output} 2>&1 ./`basename ${file} .adb` >${actual_output} 2>&1
......
...@@ -200,6 +200,7 @@ AC_ARG_WITH(ocarina-runtimes, ...@@ -200,6 +200,7 @@ AC_ARG_WITH(ocarina-runtimes,
AS_HELP_STRING([--with-ocarina-runtimes=x], [enumerate runtimes]), AS_HELP_STRING([--with-ocarina-runtimes=x], [enumerate runtimes]),
[ [
RUNTIME_LIST="" RUNTIME_LIST=""
AM_CONDITIONAL(AADLIB, false)
AM_CONDITIONAL(PO_HI_ADA, false) AM_CONDITIONAL(PO_HI_ADA, false)
AM_CONDITIONAL(PO_HI_C, false) AM_CONDITIONAL(PO_HI_C, false)
AM_CONDITIONAL(POK, false) AM_CONDITIONAL(POK, false)
...@@ -209,7 +210,7 @@ AS_HELP_STRING([--with-ocarina-runtimes=x], [enumerate runtimes]), ...@@ -209,7 +210,7 @@ AS_HELP_STRING([--with-ocarina-runtimes=x], [enumerate runtimes]),
do do
case ${R} in case ${R} in
all ) all )
for P in polyorb-hi-ada polyorb-hi-c for P in aadlib polyorb-hi-ada polyorb-hi-c
do do
if test -d ${root}/resources/runtime/${P} if test -d ${root}/resources/runtime/${P}
then then
...@@ -219,15 +220,27 @@ AS_HELP_STRING([--with-ocarina-runtimes=x], [enumerate runtimes]), ...@@ -219,15 +220,27 @@ AS_HELP_STRING([--with-ocarina-runtimes=x], [enumerate runtimes]),
fi fi
done done
AM_CONDITIONAL(AADLIB, true)
AM_CONDITIONAL(PO_HI_ADA, true) AM_CONDITIONAL(PO_HI_ADA, true)
AM_CONDITIONAL(PO_HI_C, true) AM_CONDITIONAL(PO_HI_C, true)
;; ;;
none ) none )
AM_CONDITIONAL(AADLIB, false)
AM_CONDITIONAL(PO_HI_ADA, false) AM_CONDITIONAL(PO_HI_ADA, false)
AM_CONDITIONAL(PO_HI_C, false) AM_CONDITIONAL(PO_HI_C, false)
;; ;;
aadlib )
if test -d ${root}/resources/runtime/${R}
then
RUNTIME_LIST="${RUNTIME_LIST}${R} "
else
AC_MSG_ERROR([runtime ${R} not found])
fi
AM_CONDITIONAL(AADLIB, true)
;;
pok ) pok )
if test -d ${root}/resources/runtime/${R} if test -d ${root}/resources/runtime/${R}
then then
...@@ -268,7 +281,7 @@ AS_HELP_STRING([--with-ocarina-runtimes=x], [enumerate runtimes]), ...@@ -268,7 +281,7 @@ AS_HELP_STRING([--with-ocarina-runtimes=x], [enumerate runtimes]),
], ],
[ [
RUNTIME_LIST="" RUNTIME_LIST=""
for P in polyorb-hi-ada polyorb-hi-c for P in aadlib polyorb-hi-ada polyorb-hi-c
do do
if test -d ${root}/resources/runtime/${P} if test -d ${root}/resources/runtime/${P}
then then
...@@ -276,6 +289,7 @@ AS_HELP_STRING([--with-ocarina-runtimes=x], [enumerate runtimes]), ...@@ -276,6 +289,7 @@ AS_HELP_STRING([--with-ocarina-runtimes=x], [enumerate runtimes]),
fi fi
done done
AM_CONDITIONAL(AADLIB, test -d "${root}/resources/runtime/aadlib")
AM_CONDITIONAL(POK, test -d "${root}/resources/runtime/pok") AM_CONDITIONAL(POK, test -d "${root}/resources/runtime/pok")
AM_CONDITIONAL(PO_HI_ADA, test -d "${root}/resources/runtime/polyorb-hi-ada") AM_CONDITIONAL(PO_HI_ADA, test -d "${root}/resources/runtime/polyorb-hi-ada")
AM_CONDITIONAL(PO_HI_C, test -d "${root}/resources/runtime/polyorb-hi-c") AM_CONDITIONAL(PO_HI_C, test -d "${root}/resources/runtime/polyorb-hi-c")
......
...@@ -55,7 +55,6 @@ project Ocarina.Python is ...@@ -55,7 +55,6 @@ project Ocarina.Python is
for Library_Interface use ("ocarina.python_cmd"); for Library_Interface use ("ocarina.python_cmd");
for Library_Standalone use "standard"; for Library_Standalone use "standard";
-- for Library_Standalone use "encapsulated";
package Compiler renames Ocarina.Compiler; package Compiler renames Ocarina.Compiler;
package Binder renames Ocarina.Binder; package Binder renames Ocarina.Binder;
......
...@@ -52,8 +52,7 @@ project Ocarina is ...@@ -52,8 +52,7 @@ project Ocarina is
case Build is case Build is
when "debug" => when "debug" =>
for Default_Switches ("Ada") use for Default_Switches ("Ada") use
("-fPIC", ("-g",
"-g",
"-gnatfy", "-gnatfy",
"-gnatwae", "-gnatwae",
"-gnatoa", "-gnatoa",
...@@ -68,7 +67,6 @@ project Ocarina is ...@@ -68,7 +67,6 @@ project Ocarina is
when "release" => when "release" =>
for Default_Switches ("Ada") use for Default_Switches ("Ada") use
("-O2", ("-O2",
"-fPIC",
"-gnat12", "-gnat12",
"-gnata", "-gnata",
"-gnaty", "-gnaty",
......
...@@ -5,6 +5,14 @@ SUBDIRS = cheddar aadl_xml python ...@@ -5,6 +5,14 @@ SUBDIRS = cheddar aadl_xml python
################################################################################ ################################################################################
maybe-reconfig-aadlib:
@AADLIB_TRUE@maybe-reconfig-aadlib: reconfig-aadlib
reconfig-aadlib:
r_dir='aadlib'; \
test -f $(srcdir)/$${r_dir}/configure && exit 0 || true; \
test -d $(srcdir)/$${r_dir} || exit 0; \
cd $(srcdir)/$${r_dir} && ./support/reconfig
maybe-reconfig-polyorb-hi-ada: maybe-reconfig-polyorb-hi-ada:
@PO_HI_ADA_TRUE@maybe-reconfig-polyorb-hi-ada: reconfig-polyorb-hi-ada @PO_HI_ADA_TRUE@maybe-reconfig-polyorb-hi-ada: reconfig-polyorb-hi-ada
reconfig-polyorb-hi-ada: reconfig-polyorb-hi-ada:
...@@ -30,6 +38,17 @@ configure-pok: ...@@ -30,6 +38,17 @@ configure-pok:
test -f $${r_dir}/Makefile || exit 0; \ test -f $${r_dir}/Makefile || exit 0; \
cd $${r_dir} && $(MAKE) configure cd $${r_dir} && $(MAKE) configure
maybe-configure-aadlib:
@AADLIB_TRUE@maybe-configure-aadlib: configure-aadlib
configure-aadlib: reconfig-aadlib
r_dir='aadlib'; \
s_dir=`(cd $(srcdir) && pwd)`; \
test -f $${r_dir}/Makefile && exit 0 || true; \
test -x $(srcdir)/$${r_dir}/configure || exit 0; \
$(mkdir_p) $${r_dir} && cd $${r_dir} || exit 1; \
$${s_dir}/$${r_dir}/configure $(DEBUG_FLAG) $(DOC_FLAG) \
--with-ocarina-prefix='$(prefix)' --disable-ocarina-version-check
maybe-configure-polyorb-hi-ada: maybe-configure-polyorb-hi-ada:
@PO_HI_ADA_TRUE@maybe-configure-polyorb-hi-ada: configure-polyorb-hi-ada @PO_HI_ADA_TRUE@maybe-configure-polyorb-hi-ada: configure-polyorb-hi-ada
configure-polyorb-hi-ada: reconfig-polyorb-hi-ada configure-polyorb-hi-ada: reconfig-polyorb-hi-ada
...@@ -54,6 +73,13 @@ configure-polyorb-hi-c: reconfig-polyorb-hi-c ...@@ -54,6 +73,13 @@ configure-polyorb-hi-c: reconfig-polyorb-hi-c
################################################################################ ################################################################################
maybe-all-aadlib:
@AADLIB_TRUE@maybe-all-aadlib: all-aadlib
all-aadlib: configure-aadlib
r_dir='aadlib'; \
test -f $${r_dir}/Makefile || exit 0; \
cd $${r_dir} && $(MAKE) all
maybe-all-polyorb-hi-ada: maybe-all-polyorb-hi-ada:
@PO_HI_ADA_TRUE@maybe-all-polyorb-hi-ada: all-polyorb-hi-ada @PO_HI_ADA_TRUE@maybe-all-polyorb-hi-ada: all-polyorb-hi-ada
all-polyorb-hi-ada: configure-polyorb-hi-ada all-polyorb-hi-ada: configure-polyorb-hi-ada
...@@ -86,6 +112,13 @@ dvi-polyorb-hi-c: configure-polyorb-hi-c ...@@ -86,6 +112,13 @@ dvi-polyorb-hi-c: configure-polyorb-hi-c
################################################################################ ################################################################################
maybe-install-aadlib:
@AADLIB_TRUE@maybe-install-aadlib: install-aadlib
install-aadlib: all-aadlib
r_dir='aadlib'; \
test -f $${r_dir}/Makefile || exit 0; \
cd $${r_dir} && $(MAKE) DESTDIR="$(DESTDIR)" install
maybe-install-polyorb-hi-ada: maybe-install-polyorb-hi-ada:
@PO_HI_ADA_TRUE@maybe-install-polyorb-hi-ada: install-polyorb-hi-ada @PO_HI_ADA_TRUE@maybe-install-polyorb-hi-ada: install-polyorb-hi-ada
install-polyorb-hi-ada: all-polyorb-hi-ada install-polyorb-hi-ada: all-polyorb-hi-ada
...@@ -102,6 +135,13 @@ install-polyorb-hi-c: all-polyorb-hi-c ...@@ -102,6 +135,13 @@ install-polyorb-hi-c: all-polyorb-hi-c
################################################################################ ################################################################################
maybe-installcheck-aadlib:
@AADLIB_TRUE@maybe-installcheck-aadlib: installcheck-aadlib
installcheck-aadlib: all-aadlib
r_dir='aadlib'; \
test -f $${r_dir}/Makefile || exit 0; \
cd $${r_dir} && $(MAKE) installcheck
maybe-installcheck-polyorb-hi-ada: maybe-installcheck-polyorb-hi-ada:
@PO_HI_ADA_TRUE@maybe-installcheck-polyorb-hi-ada: installcheck-polyorb-hi-ada @PO_HI_ADA_TRUE@maybe-installcheck-polyorb-hi-ada: installcheck-polyorb-hi-ada
installcheck-polyorb-hi-ada: all-polyorb-hi-ada installcheck-polyorb-hi-ada: all-polyorb-hi-ada
...@@ -118,6 +158,13 @@ installcheck-polyorb-hi-c: all-polyorb-hi-c ...@@ -118,6 +158,13 @@ installcheck-polyorb-hi-c: all-polyorb-hi-c
################################################################################ ################################################################################
maybe-uninstall-aadlib:
@AADLIB_TRUE@maybe-uninstall-aadlib: uninstall-aadlib
uninstall-aadlib:
r_dir='aadlib'; \
test -f $${r_dir}/Makefile || exit 0; \
cd $${r_dir} && $(MAKE) DESTDIR="$(DESTDIR)" uninstall
maybe-uninstall-polyorb-hi-ada: maybe-uninstall-polyorb-hi-ada:
@PO_HI_ADA_TRUE@maybe-uninstall-polyorb-hi-ada: uninstall-polyorb-hi-ada @PO_HI_ADA_TRUE@maybe-uninstall-polyorb-hi-ada: uninstall-polyorb-hi-ada
uninstall-polyorb-hi-ada: uninstall-polyorb-hi-ada:
...@@ -135,6 +182,13 @@ uninstall-polyorb-hi-c: ...@@ -135,6 +182,13 @@ uninstall-polyorb-hi-c:
################################################################################ ################################################################################
maybe-clean-aadlib:
@AADLIB_TRUE@maybe-clean-aadlib: clean-aadlib
clean-aadlib:
r_dir='aadlib'; \
test -f $${r_dir}/Makefile || exit 0; \
cd $${r_dir} && $(MAKE) clean
maybe-clean-polyorb-hi-ada: maybe-clean-polyorb-hi-ada:
@PO_HI_ADA_TRUE@maybe-clean-polyorb-hi-ada: clean-polyorb-hi-ada @PO_HI_ADA_TRUE@maybe-clean-polyorb-hi-ada: clean-polyorb-hi-ada
clean-polyorb-hi-ada: clean-polyorb-hi-ada:
...@@ -151,6 +205,13 @@ clean-polyorb-hi-c: ...@@ -151,6 +205,13 @@ clean-polyorb-hi-c:
################################################################################ ################################################################################
maybe-distclean-aadlib:
@AADLIB_TRUE@maybe-distclean-aadlib: distclean-aadlib
distclean-aadlib:
r_dir='aadlib'; \
test -f $${r_dir}/Makefile || exit 0; \
cd $${r_dir} && $(MAKE) distclean
maybe-distclean-polyorb-hi-ada: maybe-distclean-polyorb-hi-ada:
@PO_HI_ADA_TRUE@maybe-distclean-polyorb-hi-ada: distclean-polyorb-hi-ada @PO_HI_ADA_TRUE@maybe-distclean-polyorb-hi-ada: distclean-polyorb-hi-ada
distclean-polyorb-hi-ada: distclean-polyorb-hi-ada:
...@@ -174,6 +235,13 @@ check-pok: configure-pok ...@@ -174,6 +235,13 @@ check-pok: configure-pok
test -f $${r_dir}/Makefile || exit 0; \ test -f $${r_dir}/Makefile || exit 0; \
cd $${r_dir} && $(MAKE) tests cd $${r_dir} && $(MAKE) tests
maybe-check-aadlib:
@AADLIB_TRUE@maybe-check-aadlib: check-aadlib
check-aadlib:
r_dir='aadlib'; \
test -f $${r_dir}/Makefile || exit 0; \
cd $${r_dir} && PATH="$(DESTDIR)$(bindir):$$PATH" $(MAKE) check
maybe-check-polyorb-hi-ada: maybe-check-polyorb-hi-ada:
@PO_HI_ADA_TRUE@maybe-check-polyorb-hi-ada: check-polyorb-hi-ada @PO_HI_ADA_TRUE@maybe-check-polyorb-hi-ada: check-polyorb-hi-ada
check-polyorb-hi-ada: check-polyorb-hi-ada:
...@@ -190,6 +258,18 @@ check-polyorb-hi-c: ...@@ -190,6 +258,18 @@ check-polyorb-hi-c:
################################################################################ ################################################################################
maybe-dist-aadlib:
@AADLIB_TRUE@maybe-dist-aadlib: dist-aadlib
dist-aadlib: configure-aadlib
r_dir='aadlib'; \
d_dir='aadlib-dist'; \
test -f $${r_dir}/Makefile || exit 0; \
cd $${r_dir} && $(MAKE) distdir "distdir=$${d_dir}" || exit 1; \
cd .. && chmod -R go=u-w $${r_dir}/$${d_dir} || exit 1; \
$(mkdir_p) $(distdir)/$${r_dir} || exit 1; \
cp -pR $${r_dir}/$${d_dir}/* $(distdir)/$${r_dir} || exit 1; \
rm -rf $${r_dir}/$${d_dir}
maybe-dist-polyorb-hi-ada: maybe-dist-polyorb-hi-ada:
@PO_HI_ADA_TRUE@maybe-dist-polyorb-hi-ada: dist-polyorb-hi-ada @PO_HI_ADA_TRUE@maybe-dist-polyorb-hi-ada: dist-polyorb-hi-ada
dist-polyorb-hi-ada: configure-polyorb-hi-ada dist-polyorb-hi-ada: configure-polyorb-hi-ada
...@@ -214,11 +294,11 @@ dist-polyorb-hi-c: configure-polyorb-hi-c ...@@ -214,11 +294,11 @@ dist-polyorb-hi-c: configure-polyorb-hi-c
cp -pR $${r_dir}/$${d_dir}/* $(distdir)/$${r_dir} || exit 1; \ cp -pR $${r_dir}/$${d_dir}/* $(distdir)/$${r_dir} || exit 1; \
rm -rf $${r_dir}/$${d_dir} rm -rf $${r_dir}/$${d_dir}
################################################################################ ################################################################################
# Soft dependenciy against runtimes # Soft dependenciy against runtimes
all-local: \ all-local: \
maybe-all-aadlib \
maybe-all-polyorb-hi-ada \ maybe-all-polyorb-hi-ada \
maybe-all-polyorb-hi-c maybe-all-polyorb-hi-c
...@@ -227,30 +307,37 @@ dvi: \ ...@@ -227,30 +307,37 @@ dvi: \
maybe-dvi-polyorb-hi-c maybe-dvi-polyorb-hi-c
install-data-local: \ install-data-local: \
maybe-install-aadlib \
maybe-install-polyorb-hi-ada \ maybe-install-polyorb-hi-ada \
maybe-install-polyorb-hi-c maybe-install-polyorb-hi-c
installcheck: \ installcheck: \
maybe-installcheck-aadlib \
maybe-installcheck-polyorb-hi-ada \ maybe-installcheck-polyorb-hi-ada \
maybe-installcheck-polyorb-hi-c maybe-installcheck-polyorb-hi-c
uninstall-local: \ uninstall-local: \
maybe-uninstall-aadlib \
maybe-uninstall-polyorb-hi-ada \ maybe-uninstall-polyorb-hi-ada \
maybe-uninstall-polyorb-hi-c maybe-uninstall-polyorb-hi-c
clean-local: \ clean-local: \
maybe-clean-aadlib \
maybe-clean-polyorb-hi-ada \ maybe-clean-polyorb-hi-ada \
maybe-clean-polyorb-hi-c maybe-clean-polyorb-hi-c
distclean-local: \ distclean-local: \
maybe-distclean-aadlib \
maybe-distclean-polyorb-hi-ada \ maybe-distclean-polyorb-hi-ada \
maybe-distclean-polyorb-hi-c maybe-distclean-polyorb-hi-c
maybe-check-runtimes: \ maybe-check-runtimes: \
maybe-check-pok \ maybe-check-pok \
maybe-check-aadlib \
maybe-check-polyorb-hi-ada \ maybe-check-polyorb-hi-ada \
maybe-check-polyorb-hi-c maybe-check-polyorb-hi-c
dist-hook: \ dist-hook: \
maybe-dist-aadlib \
maybe-dist-polyorb-hi-ada \ maybe-dist-polyorb-hi-ada \
maybe-dist-polyorb-hi-c maybe-dist-polyorb-hi-c
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- -- -- --
-- B o d y -- -- B o d y --
-- -- -- --
-- Copyright (C) 2006-2009 Telecom ParisTech, 2010-2015 ESA & ISAE. -- -- Copyright (C) 2006-2009 Telecom ParisTech, 2010-2016 ESA & ISAE. --
-- -- -- --
-- Ocarina is free software; you can redistribute it and/or modify under -- -- Ocarina is free software; you can redistribute it and/or modify under --
-- terms of the GNU General Public License as published by the Free Soft- -- -- terms of the GNU General Public License as published by the Free Soft- --
...@@ -39,14 +39,8 @@ package body Ocarina.Backends.Ada_Values is ...@@ -39,14 +39,8 @@ package body Ocarina.Backends.Ada_Values is
package OV renames Ocarina.AADL_Values; package OV renames Ocarina.AADL_Values;
Hex : constant String := "0123456789ABCDEF";
package VT is new GNAT.Table (Value_Type, Value_Id, No_Value + 1, 10, 10); package VT is new GNAT.Table (Value_Type, Value_Id, No_Value + 1, 10, 10);
subtype ULL is Unsigned_Long_Long;
procedure Add_ULL_To_Name_Buffer (U : ULL; B : ULL; S : Integer := 1);
----------- -----------
-- Reset -- -- Reset --
----------- -----------
...@@ -341,20 +335,6 @@ package body Ocarina.Backends.Ada_Values is ...@@ -341,20 +335,6 @@ package body Ocarina.Backends.Ada_Values is
return LV; return LV;
end "xor"; end "xor";
----------------------------
-- Add_ULL_To_Name_Buffer --
----------------------------
procedure Add_ULL_To_Name_Buffer (U : ULL; B : ULL; S : Integer := 1) is
Q : constant ULL := U / B;
R : constant ULL := U mod B;
begin
if Q /= 0 or else S > 1 then
Add_ULL_To_Name_Buffer (Q, B, S - 1);
end if;
Add_Char_To_Name_Buffer (Hex (Hex'First + Natural (R)));
end Add_ULL_To_Name_Buffer;
----------- -----------
-- Image -- -- Image --
----------- -----------
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- -- -- --
-- B o d y -- -- B o d y --
-- -- -- --
-- Copyright (C) 2012-2015 ESA & ISAE. -- -- Copyright (C) 2012-2016 ESA & ISAE. --
-- -- -- --
-- Ocarina is free software; you can redistribute it and/or modify under -- -- Ocarina is free software; you can redistribute it and/or modify under --
-- terms of the GNU General Public License as published by the Free Soft- -- -- terms of the GNU General Public License as published by the Free Soft- --
...@@ -39,14 +39,8 @@ package body Ocarina.Backends.ASN1_Values is ...@@ -39,14 +39,8 @@ package body Ocarina.Backends.ASN1_Values is
package OV renames Ocarina.AADL_Values; package OV renames Ocarina.AADL_Values;
Hex : constant String := "0123456789ABCDEF";
package VT is new GNAT.Table (Value_Type, Value_Id, No_Value + 1, 10, 10); package VT is new GNAT.Table (Value_Type, Value_Id, No_Value + 1, 10, 10);
subtype ULL is Unsigned_Long_Long;
procedure Add_ULL_To_Name_Buffer (U : ULL; B : ULL; S : Integer := 1);
--------- ---------
-- "*" -- -- "*" --
--------- ---------
...@@ -320,20 +314,6 @@ package body Ocarina.Backends.ASN1_Values is ...@@ -320,20 +314,6 @@ package body Ocarina.Backends.ASN1_Values is
return LV; return LV;
end "xor"; end "xor";
----------------------------
-- Add_ULL_To_Name_Buffer --
----------------------------
procedure Add_ULL_To_Name_Buffer (U : ULL; B : ULL; S : Integer := 1) is
Q : constant ULL := U / B;
R : constant ULL := U mod B;
begin
if Q /= 0 or else S > 1 then
Add_ULL_To_Name_Buffer (Q, B, S - 1);
end if;
Add_Char_To_Name_Buffer (Hex (Hex'First + Natural (R)));
end Add_ULL_To_Name_Buffer;
----------- -----------
-- Image -- -- Image --
----------- -----------
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- -- -- --
-- B o d y -- -- B o d y --
-- -- -- --
-- Copyright (C) 2008-2009 Telecom ParisTech, 2010-2015 ESA & ISAE. -- -- Copyright (C) 2008-2009 Telecom ParisTech, 2010-2016 ESA & ISAE. --
-- -- -- --
-- Ocarina is free software; you can redistribute it and/or modify under -- -- Ocarina is free software; you can redistribute it and/or modify under --
-- terms of the GNU General Public License as published by the Free Soft- -- -- terms of the GNU General Public License as published by the Free Soft- --
...@@ -39,14 +39,8 @@ package body Ocarina.Backends.C_Values is ...@@ -39,14 +39,8 @@ package body Ocarina.Backends.C_Values is
package OV renames Ocarina.AADL_Values; package OV renames Ocarina.AADL_Values;
Hex : constant String := "0123456789ABCDEF";
package VT is new GNAT.Table (Value_Type, Value_Id, No_Value + 1, 10, 10); package VT is new GNAT.Table (Value_Type, Value_Id, No_Value + 1, 10, 10);
subtype ULL is Unsigned_Long_Long;
procedure Add_ULL_To_Name_Buffer (U : ULL; B : ULL; S : Integer := 1);
--------- ---------
-- "*" -- -- "*" --
--------- ---------
...@@ -320,20 +314,6 @@ package body Ocarina.Backends.C_Values is ...@@ -320,20 +314,6 @@ package body Ocarina.Backends.C_Values is
return LV; return LV;
end "xor"; end "xor";
----------------------------
-- Add_ULL_To_Name_Buffer --
----------------------------
procedure Add_ULL_To_Name_Buffer (U : ULL; B : ULL; S : Integer := 1) is
Q : constant ULL := U / B;
R : constant ULL := U mod B;
begin
if Q /= 0 or else S > 1 then
Add_ULL_To_Name_Buffer (Q, B, S - 1);
end if;
Add_Char_To_Name_Buffer (Hex (Hex'First + Natural (R)));
end Add_ULL_To_Name_Buffer;
----------- -----------
-- Image -- -- Image --
----------- -----------
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
-- -- -- --
-- B o d y -- -- B o d y --
-- -- -- --
-- Copyright (C) 2010-2015 ESA & ISAE. -- -- Copyright (C) 2010-2016 ESA & ISAE. --
-- -- -- --
-- Ocarina is free software; you can redistribute it and/or modify under -- -- Ocarina is free software; you can redistribute it and/or modify under --
-- terms of the GNU General Public License as published by the Free Soft- -- -- terms of the GNU General Public License as published by the Free Soft- --
...@@ -38,14 +38,8 @@ package body Ocarina.Backends.MAST_Values is ...@@ -38,14 +38,8 @@ package body Ocarina.Backends.MAST_Values is
package OV renames Ocarina.AADL_Values; package OV renames Ocarina.AADL_Values;
Hex : constant String := "0123456789ABCDEF";
package VT is new GNAT.Table (Value_Type, Value_Id, No_Value + 1, 10, 10); package VT is new GNAT.Table (Value_Type, Value_Id, No_Value + 1, 10, 10);
subtype ULL is Unsigned_Long_Long;
procedure Add_ULL_To_Name_Buffer (U : ULL; B : ULL; S : Integer := 1);
--------- ---------
-- "*" -- -- "*" --
--------- ---------
...@@ -301,20 +295,6 @@ package body Ocarina.Backends.MAST_Values is ...@@ -301,20 +295,6 @@ package body Ocarina.Backends.MAST_Values is
return LV; return LV;
end "xor"; end "xor";
----------------------------
-- Add_ULL_To_Name_Buffer --
----------------------------
procedure Add_ULL_To_Name_Buffer (U : ULL; B : ULL; S : Integer := 1) is
Q : constant ULL := U / B;
R : constant ULL := U mod B;
begin
if Q /= 0 or else S > 1 then
Add_ULL_To_Name_Buffer (Q, B, S - 1);
end if;
Add_Char_To_Name_Buffer (Hex (Hex'First + Natural (R)));
end Add_ULL_To_Name_Buffer;