X-Git-Url: http://bilbo.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/237fd22b56db7d1c67360c37559ce3aab16a002d..51e5a45d4be05b7c01d28ce109505cd5e7444e46:/tools/smpi/generate_smpi_defines.pl diff --git a/tools/smpi/generate_smpi_defines.pl b/tools/smpi/generate_smpi_defines.pl index b867236042..34c366afde 100755 --- a/tools/smpi/generate_smpi_defines.pl +++ b/tools/smpi/generate_smpi_defines.pl @@ -1,6 +1,6 @@ #!/usr/bin/env perl # -# Copyright (c) 2016-2021. The SimGrid Team. All rights reserved. +# Copyright (c) 2016-2023. The SimGrid Team. All rights reserved. # # This program is free software; you can redistribute it and/or modify it # under the terms of the license (GNU LGPL) which comes with this package. @@ -31,7 +31,7 @@ if (defined $options{f}) { $commentChar="!" } -print "$commentChar Copyright (c) 2016-2021. The SimGrid Team. All rights reserved.\n"; +print "$commentChar Copyright (c) 2016-2023. The SimGrid Team. All rights reserved.\n"; print "\n"; print "$commentChar This program is free software; you can redistribute it and/or modify it\n"; print "$commentChar under the terms of the license (GNU LGPL) which comes with this package.\n"; @@ -50,11 +50,11 @@ sub output_macro { # This is a GCC extension. The last statement is the value of the expression # in parentheses. if (defined $options{f}) { - print "#define ". lc($id) ." smpi_trace_set_call_location(__FILE__,__LINE__); call ". ucfirst $id ."\n"; - print "#define ". uc($id) ." smpi_trace_set_call_location(__FILE__,__LINE__); call ". ucfirst $id ."\n"; + print "#define ". lc($id) ." smpi_trace_set_call_location(__FILE__,__LINE__,\"". lc($id) ."\"); call ". ucfirst $id ."\n"; + print "#define ". uc($id) ." smpi_trace_set_call_location(__FILE__,__LINE__,\"". uc($id) ."\"); call ". ucfirst $id ."\n"; } else { - print "#define $id(...) (smpi_trace_set_call_location(__FILE__, __LINE__), $id(__VA_ARGS__))\n"; + print "#define $id(...) (smpi_trace_set_call_location(__FILE__, __LINE__, \"$id\"), $id(__VA_ARGS__))\n"; } }