comp.lang.ada
 help / color / mirror / Atom feed
* I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?
@ 2023-06-25  4:37 Kenneth Wolcott
  2023-06-25  5:23 ` Kenneth Wolcott
  2023-06-25 10:15 ` Simon Wright
  0 siblings, 2 replies; 10+ messages in thread
From: Kenneth Wolcott @ 2023-06-25  4:37 UTC (permalink / raw)


Hi;

I have gnat 13.1.0 on my M1 Mac;

(thank you, Simon! <GRIN>)

I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?

I can find the Ada libraries (*.ad[sb]) but it sometimes is hard to (reliably) find all of the GNAT Ada libraries in external documentation.

I hope that this is not a stupid question.

Perhaps there is a gnatmake flag or gnat doc that I'm just not seeing.

Thanks,
Ken Wolcott

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?
  2023-06-25  4:37 I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they? Kenneth Wolcott
@ 2023-06-25  5:23 ` Kenneth Wolcott
  2023-06-25 10:15 ` Simon Wright
  1 sibling, 0 replies; 10+ messages in thread
From: Kenneth Wolcott @ 2023-06-25  5:23 UTC (permalink / raw)


On Saturday, June 24, 2023 at 9:37:37 PM UTC-7, Kenneth Wolcott wrote:
> Hi; 
> 
> I have gnat 13.1.0 on my M1 Mac; 
> 
> (thank you, Simon! <GRIN>) 
> 
> I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they? 
> 
> I can find the Ada libraries (*.ad[sb]) but it sometimes is hard to (reliably) find all of the GNAT Ada libraries in external documentation. 
> 
> I hope that this is not a stupid question. 
> 
> Perhaps there is a gnatmake flag or gnat doc that I'm just not seeing. 
> 
> Thanks, 
> Ken Wolcott

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?
  2023-06-25  4:37 I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they? Kenneth Wolcott
  2023-06-25  5:23 ` Kenneth Wolcott
@ 2023-06-25 10:15 ` Simon Wright
  2023-06-25 15:28   ` Simon Wright
                     ` (2 more replies)
  1 sibling, 3 replies; 10+ messages in thread
From: Simon Wright @ 2023-06-25 10:15 UTC (permalink / raw)


Kenneth Wolcott <kennethwolcott@gmail.com> writes:

> I have gnat 13.1.0 on my M1 Mac;
>
> (thank you, Simon! <GRIN>)

:bow:

> I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?

If you just want to insect them, see below: if you want to alter them,
that'd be a bit tricker. As far as I can remember, GNAT Pro releases
provide for rebuilding the runtime, but the FSF builds don't.

> I can find the Ada libraries (*.ad[sb]) but it sometimes is hard to
> (reliably) find all of the GNAT Ada libraries in external
> documentation.

They're in {prefix}/lib/gcc/{target}/{release}/adainclude/ - i.e., in
your case (unless you've moved the install)

   /opt/gcc-13.1.0-aarch64/lib/gcc/aarch64-apple-darwin21/13.1.0/adainclude/

But you say you know that. I wonder whether it's the crunched filenames
that are confusing? (a legacy of the days when DOS 8.3 filenames were
required for a large part of GNAT's target audience). You can find the
crunched filename for a package using gnatkr (gnat krunch):

   $ gnatkr gnatkr ada.sequential_io.ads
   a-sequio.ads

(you don't actually need whatever's after the final period to be the
actual file extension: you could use '.open' or just '.').

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?
  2023-06-25 10:15 ` Simon Wright
@ 2023-06-25 15:28   ` Simon Wright
  2023-06-25 17:00   ` Kenneth Wolcott
  2023-06-25 21:49   ` Keith Thompson
  2 siblings, 0 replies; 10+ messages in thread
From: Simon Wright @ 2023-06-25 15:28 UTC (permalink / raw)


Simon Wright <simon@pushface.org> writes:

>    $ gnatkr gnatkr ada.sequential_io.ads
>    a-sequio.ads

Only one 'gnatkr', ofc!

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?
  2023-06-25 10:15 ` Simon Wright
  2023-06-25 15:28   ` Simon Wright
@ 2023-06-25 17:00   ` Kenneth Wolcott
  2023-06-25 21:49   ` Keith Thompson
  2 siblings, 0 replies; 10+ messages in thread
From: Kenneth Wolcott @ 2023-06-25 17:00 UTC (permalink / raw)


Thank you Simon!

On Sunday, June 25, 2023 at 3:15:54 AM UTC-7, Simon Wright wrote:
> Kenneth Wolcott writes: 
> 
> > I have gnat 13.1.0 on my M1 Mac; 
> > 
> > (thank you, Simon! <GRIN>)
> :bow:
> > I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?
> If you just want to insect them, see below: if you want to alter them, 
> that'd be a bit tricker. As far as I can remember, GNAT Pro releases 
> provide for rebuilding the runtime, but the FSF builds don't.
> > I can find the Ada libraries (*.ad[sb]) but it sometimes is hard to 
> > (reliably) find all of the GNAT Ada libraries in external 
> > documentation.
> They're in {prefix}/lib/gcc/{target}/{release}/adainclude/ - i.e., in 
> your case (unless you've moved the install) 
> 
> /opt/gcc-13.1.0-aarch64/lib/gcc/aarch64-apple-darwin21/13.1.0/adainclude/ 

This is all the information that I needed, thank you!

> But you say you know that. I wonder whether it's the crunched filenames 
> that are confusing? (a legacy of the days when DOS 8.3 filenames were 
> required for a large part of GNAT's target audience). You can find the 
> crunched filename for a package using gnatkr (gnat krunch): 
> 
> $ gnatkr gnatkr ada.sequential_io.ads 
> a-sequio.ads 

This is nice, thank you!

> (you don't actually need whatever's after the final period to be the 
> actual file extension: you could use '.open' or just '.').

Ken Wolcott

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?
  2023-06-25 10:15 ` Simon Wright
  2023-06-25 15:28   ` Simon Wright
  2023-06-25 17:00   ` Kenneth Wolcott
@ 2023-06-25 21:49   ` Keith Thompson
  2023-06-26 18:56     ` Jere
  2 siblings, 1 reply; 10+ messages in thread
From: Keith Thompson @ 2023-06-25 21:49 UTC (permalink / raw)


Simon Wright <simon@pushface.org> writes:
[...]
> But you say you know that. I wonder whether it's the crunched filenames
> that are confusing? (a legacy of the days when DOS 8.3 filenames were
> required for a large part of GNAT's target audience). You can find the
> crunched filename for a package using gnatkr (gnat krunch):
>
>    $ gnatkr ada.sequential_io.ads
[fixed typo]
>    a-sequio.ads
>
> (you don't actually need whatever's after the final period to be the
> actual file extension: you could use '.open' or just '.').

Which raises a question: Why does GNAT still use crunched filenames?  It
probably makes sense to continue to support them (does anyone use GNAT
on MS-DOS?), but I wouldn't think it would be difficult to use full file
names on the vast majority of systems that support them.  It's not a
huge deal, but using full file names where possible would be less
annoying.

-- 
Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com
Will write code for food.
void Void(void) { Void(); } /* The recursive call of the void */

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?
  2023-06-25 21:49   ` Keith Thompson
@ 2023-06-26 18:56     ` Jere
  2023-06-26 19:35       ` Kenneth Wolcott
  2023-06-26 19:48       ` Simon Wright
  0 siblings, 2 replies; 10+ messages in thread
From: Jere @ 2023-06-26 18:56 UTC (permalink / raw)


On Sunday, June 25, 2023 at 5:49:11 PM UTC-4, Keith Thompson wrote:
> Simon Wright writes: 
> [...]
> > But you say you know that. I wonder whether it's the crunched filenames 
> > that are confusing? (a legacy of the days when DOS 8.3 filenames were 
> > required for a large part of GNAT's target audience). You can find the 
> > crunched filename for a package using gnatkr (gnat krunch): 
> >
> > $ gnatkr ada.sequential_io.ads 
> [fixed typo]
> > a-sequio.ads 
> > 
> > (you don't actually need whatever's after the final period to be the 
> > actual file extension: you could use '.open' or just '.').
> Which raises a question: Why does GNAT still use crunched filenames? It 
> probably makes sense to continue to support them (does anyone use GNAT 
> on MS-DOS?), but I wouldn't think it would be difficult to use full file 
> names on the vast majority of systems that support them. It's not a 
> huge deal, but using full file names where possible would be less 
> annoying. 

Unless they changed how the GNAT compiler works in the last few years, then my guess is inertia
to do that.   Right before the pandemic hit, I had the neat idea of doing my own bare metal 
runtime and to use normal uncrunched names.  The RTS compiled just fine doing that.  However,
when I tried to use the RTS to build a full fledged program, it failed to find the package in the RTS.
I don't recall if it failed at compile time or link time, but crunching the names and recompiling the
RTS fixed the issue.  So something in their compiler requires the crunched names, or if they have
since changed that, used to require it.

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?
  2023-06-26 18:56     ` Jere
@ 2023-06-26 19:35       ` Kenneth Wolcott
  2023-06-26 19:48       ` Simon Wright
  1 sibling, 0 replies; 10+ messages in thread
From: Kenneth Wolcott @ 2023-06-26 19:35 UTC (permalink / raw)


> Simon Wright writes: 
> $ gnatkr ada.sequential_io.ads 
> a-sequio.ads 

Simon, Keith, Jere:

Yes, the crunched names are annoying.  Too bad that they seem to be required even now...

I'm now writing a Perl script (later to be converted to Ada) which does the "unkrunch" :-)

Seems like a missing utility for humans to use Ada :-)

Thanks,
Ken

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?
  2023-06-26 18:56     ` Jere
  2023-06-26 19:35       ` Kenneth Wolcott
@ 2023-06-26 19:48       ` Simon Wright
  2023-06-26 20:00         ` Kenneth Wolcott
  1 sibling, 1 reply; 10+ messages in thread
From: Simon Wright @ 2023-06-26 19:48 UTC (permalink / raw)


Jere <jhb.chat@gmail.com> writes:

> On Sunday, June 25, 2023 at 5:49:11 PM UTC-4, Keith Thompson wrote:
>> Simon Wright writes: 
>> [...]
>> > But you say you know that. I wonder whether it's the crunched filenames 
>> > that are confusing? (a legacy of the days when DOS 8.3 filenames were 
>> > required for a large part of GNAT's target audience). You can find the 
>> > crunched filename for a package using gnatkr (gnat krunch): 
>> >
>> > $ gnatkr ada.sequential_io.ads 
>> [fixed typo]
>> > a-sequio.ads 
>> > 
>> > (you don't actually need whatever's after the final period to be the 
>> > actual file extension: you could use '.open' or just '.').
>> Which raises a question: Why does GNAT still use crunched filenames? It 
>> probably makes sense to continue to support them (does anyone use GNAT 
>> on MS-DOS?), but I wouldn't think it would be difficult to use full file 
>> names on the vast majority of systems that support them. It's not a 
>> huge deal, but using full file names where possible would be less 
>> annoying. 
>
> Unless they changed how the GNAT compiler works in the last few years,
> then my guess is inertia
> to do that.  Right before the pandemic hit, I had the neat idea of
> doing my own bare metal
> runtime and to use normal uncrunched names.  The RTS compiled just
> fine doing that.  However,
> when I tried to use the RTS to build a full fledged program, it failed
> to find the package in the RTS.
> I don't recall if it failed at compile time or link time, but
> crunching the names and recompiling the
> RTS fixed the issue.  So something in their compiler requires the
> crunched names, or if they have
> since changed that, used to require it.

The package in the compiler that deals with crunched names is Rtsfind,
https://github.com/gcc-mirror/gcc/blob/master/gcc/ada/rtsfind.ads

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they?
  2023-06-26 19:48       ` Simon Wright
@ 2023-06-26 20:00         ` Kenneth Wolcott
  0 siblings, 0 replies; 10+ messages in thread
From: Kenneth Wolcott @ 2023-06-26 20:00 UTC (permalink / raw)


Simon;

> The package in the compiler that deals with crunched names is Rtsfind, 
> https://github.com/gcc-mirror/gcc/blob/master/gcc/ada/rtsfind.ads

Thank you!
Ken

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2023-06-26 20:00 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-06-25  4:37 I have gnat 13.1.0 on my M1 Mac; I'd like to have my own Ada+GNAT *.ad[sb] library files, where are they? Kenneth Wolcott
2023-06-25  5:23 ` Kenneth Wolcott
2023-06-25 10:15 ` Simon Wright
2023-06-25 15:28   ` Simon Wright
2023-06-25 17:00   ` Kenneth Wolcott
2023-06-25 21:49   ` Keith Thompson
2023-06-26 18:56     ` Jere
2023-06-26 19:35       ` Kenneth Wolcott
2023-06-26 19:48       ` Simon Wright
2023-06-26 20:00         ` Kenneth Wolcott

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox