comp.lang.ada
 help / color / mirror / Atom feed
* Cross-Compiling Ada to Netware with GNAT
@ 2006-03-22 23:38 darrylbleau
  2006-03-23  3:01 ` Steve
  2006-03-23  4:33 ` Jeffrey R. Carter
  0 siblings, 2 replies; 8+ messages in thread
From: darrylbleau @ 2006-03-22 23:38 UTC (permalink / raw)


Hello all,

Exploring using Ada as a replacement language for C, however, one of
our requirements is that we need to be able to run our programs on
Novell Netware. So, one of the first aspects of the feasilbility study
is to get an Ada program running on Netware. We've been so far
unsuccessful, so I was hoping someone here could help point us in the
right direction.

Currently, we cross compile our C programs using gcc and link
everything into an elf32-i386 object file. Then, we use nlmconv to
convert this into an NLM (Netware's executable format). So, we tried
this approach to cross compile Ada programs, linking the object file
that gnatmake generated together with libgnat.a and libgcc_eh.a.
However, nlmconv errors out with an 'invalid operation' and lists
missing symbols related to C, this seems to be from using the wrong
header files (using the Linux headers, not the Netware ones), so we're
missing 'stdout and stdin' among others. Netware, of course, won't run
the generated NLM.

I've only been researching Ada for about a month in my spare time, but
everyplace I read can't stop talking about how portable it is, so I'm
thinking there must be an easy way to make this work, I'm just not sure
how. I did read about compiling a compiler on the target platform
itself and using this to compile programs with, is that the direction I
should be taking instead of cross compiling? Though it would seem that
you should be able to cross compile to any gcc supported platform (of
which Netware is). In any event, I'm at a bit of a loss, can anyone
help?




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

* Re: Cross-Compiling Ada to Netware with GNAT
  2006-03-22 23:38 Cross-Compiling Ada to Netware with GNAT darrylbleau
@ 2006-03-23  3:01 ` Steve
  2006-03-23 16:43   ` darrylbleau
  2006-03-23  4:33 ` Jeffrey R. Carter
  1 sibling, 1 reply; 8+ messages in thread
From: Steve @ 2006-03-23  3:01 UTC (permalink / raw)


<darrylbleau@gmail.com> wrote in message 
news:1143070697.388445.48160@i39g2000cwa.googlegroups.com...
> Hello all,
>
> Exploring using Ada as a replacement language for C, however, one of
> our requirements is that we need to be able to run our programs on
> Novell Netware. So, one of the first aspects of the feasilbility study
> is to get an Ada program running on Netware. We've been so far
> unsuccessful, so I was hoping someone here could help point us in the
> right direction.
>
> Currently, we cross compile our C programs using gcc and link
> everything into an elf32-i386 object file. Then, we use nlmconv to
> convert this into an NLM (Netware's executable format). So, we tried
> this approach to cross compile Ada programs, linking the object file
> that gnatmake generated together with libgnat.a and libgcc_eh.a.
> However, nlmconv errors out with an 'invalid operation' and lists
> missing symbols related to C, this seems to be from using the wrong
> header files (using the Linux headers, not the Netware ones), so we're
> missing 'stdout and stdin' among others. Netware, of course, won't run
> the generated NLM.
>
> I've only been researching Ada for about a month in my spare time, but
> everyplace I read can't stop talking about how portable it is, so I'm
> thinking there must be an easy way to make this work, I'm just not sure
> how. I did read about compiling a compiler on the target platform
> itself and using this to compile programs with, is that the direction I
> should be taking instead of cross compiling? Though it would seem that
> you should be able to cross compile to any gcc supported platform (of
> which Netware is). In any event, I'm at a bit of a loss, can anyone
> help?
>

The places I would look for an answer to these questions (not in order):
  #1 comp.lang.ads (which you've already done)
  #2 The GNATLIST mailing list (gnatlist@hermes.gwu.edu)
  #3 The gcc mailing list (http://gcc.gnu.org/lists.html)
  #4 Contact AdaCore (http://www.adacore.com/home/)

If you are serious and have the funds to support using Ada, contacting 
AdaCore is your best bet.  The last I knew you could get trial support from 
AdaCore and evaluate their full product.

I hope this helps,
Steve
(The Duck)





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

* Re: Cross-Compiling Ada to Netware with GNAT
  2006-03-22 23:38 Cross-Compiling Ada to Netware with GNAT darrylbleau
  2006-03-23  3:01 ` Steve
@ 2006-03-23  4:33 ` Jeffrey R. Carter
  2006-03-23 16:47   ` darrylbleau
  2006-04-02 13:50   ` Marco
  1 sibling, 2 replies; 8+ messages in thread
From: Jeffrey R. Carter @ 2006-03-23  4:33 UTC (permalink / raw)


darrylbleau@gmail.com wrote:
> I've only been researching Ada for about a month in my spare time, but
> everyplace I read can't stop talking about how portable it is, so I'm
> thinking there must be an easy way to make this work, I'm just not sure
> how. I did read about compiling a compiler on the target platform
> itself and using this to compile programs with, is that the direction I
> should be taking instead of cross compiling? Though it would seem that
> you should be able to cross compile to any gcc supported platform (of
> which Netware is). In any event, I'm at a bit of a loss, can anyone
> help?

The portability mentioned is usually of the sort that one can easily write 
programs that work on any platform with an Ada compiler, not the sort that there 
are compilers for every platform, though there are compilers for most.

I suspect there's probably a fairly easy way to get a version of GNAT that will 
produce output suitable for nlmconv, but as a last resort you could look into a 
compiler that generates C as its intermediate language, such as the one from 
Sofcheck:

http://www.sofcheck.com/products/adamagic.html

-- 
Jeff Carter
"Son of a window-dresser."
Monty Python & the Holy Grail
12



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

* Re: Cross-Compiling Ada to Netware with GNAT
  2006-03-23  3:01 ` Steve
@ 2006-03-23 16:43   ` darrylbleau
  2006-03-24 12:39     ` Stephen Leake
  0 siblings, 1 reply; 8+ messages in thread
From: darrylbleau @ 2006-03-23 16:43 UTC (permalink / raw)


Thanks for the ideas, I've posted to the gcc mailing list, perhaps
they'll have some ideas.

I don't really want to contact a commercial entity quite yet, as we
aren't even sure if we want to use Ada at this point. Unless AdaCore
was willing to develop a Netware compiler and let me evaluate it
without cost, which I doubt :).




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

* Re: Cross-Compiling Ada to Netware with GNAT
  2006-03-23  4:33 ` Jeffrey R. Carter
@ 2006-03-23 16:47   ` darrylbleau
  2006-04-02 13:50   ` Marco
  1 sibling, 0 replies; 8+ messages in thread
From: darrylbleau @ 2006-03-23 16:47 UTC (permalink / raw)


That's an interesting proposition, and perhaps one that would provide
the most flexibility. Everything has a C compiler, right? :). Thanks
for the idea.




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

* Re: Cross-Compiling Ada to Netware with GNAT
  2006-03-23 16:43   ` darrylbleau
@ 2006-03-24 12:39     ` Stephen Leake
  0 siblings, 0 replies; 8+ messages in thread
From: Stephen Leake @ 2006-03-24 12:39 UTC (permalink / raw)


"darrylbleau@gmail.com" <darrylbleau@gmail.com> writes:

> Thanks for the ideas, I've posted to the gcc mailing list, perhaps
> they'll have some ideas.
>
> I don't really want to contact a commercial entity quite yet, as we
> aren't even sure if we want to use Ada at this point. Unless AdaCore
> was willing to develop a Netware compiler and let me evaluate it
> without cost, which I doubt :).

It doesn't cost you anything to ask them. If they get 10 such calls
this year, maybe they _will_ develop a Netware compiler!

-- 
-- Stephe



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

* Re: Cross-Compiling Ada to Netware with GNAT
  2006-04-02 13:50   ` Marco
@ 2006-04-02 13:05     ` Georg Bauhaus
  0 siblings, 0 replies; 8+ messages in thread
From: Georg Bauhaus @ 2006-04-02 13:05 UTC (permalink / raw)


Marco wrote:
> Jeffrey > I suspect there's probably a fairly easy way to get a version
> of GNAT that will
>> produce output suitable for nlmconv, but as a last resort you could look into a
>> compiler that generates C as its intermediate language, such as the one from
>> Sofcheck:
>>
>> http://www.sofcheck.com/products/adamagic.html
> 
>    I have never used this product but it seems that it would be kind of
> a pain to "debug" or integrate from the generated code back to the
> source code (by the way what marketing guy came up with those horrible
> product names).

It is quite common for C to be a target language.
The C files refer back to the original sources
via #line directives, for example. This has worked well
for several decades, in several setups.




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

* Re: Cross-Compiling Ada to Netware with GNAT
  2006-03-23  4:33 ` Jeffrey R. Carter
  2006-03-23 16:47   ` darrylbleau
@ 2006-04-02 13:50   ` Marco
  2006-04-02 13:05     ` Georg Bauhaus
  1 sibling, 1 reply; 8+ messages in thread
From: Marco @ 2006-04-02 13:50 UTC (permalink / raw)



Jeffrey > I suspect there's probably a fairly easy way to get a version
of GNAT that will
> produce output suitable for nlmconv, but as a last resort you could look into a
> compiler that generates C as its intermediate language, such as the one from
> Sofcheck:
>
> http://www.sofcheck.com/products/adamagic.html

   I have never used this product but it seems that it would be kind of
a pain to "debug" or integrate from the generated code back to the
source code (by the way what marketing guy came up with those horrible
product names).

Maybe the OP could figure out how to keep Netware-nlmconv happy and
create some kind of thunking mechanism that could be linked in, it
seems that most of the code should not matter or could be isolated.  --
( companies still use netware?)




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

end of thread, other threads:[~2006-04-02 13:50 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-03-22 23:38 Cross-Compiling Ada to Netware with GNAT darrylbleau
2006-03-23  3:01 ` Steve
2006-03-23 16:43   ` darrylbleau
2006-03-24 12:39     ` Stephen Leake
2006-03-23  4:33 ` Jeffrey R. Carter
2006-03-23 16:47   ` darrylbleau
2006-04-02 13:50   ` Marco
2006-04-02 13:05     ` Georg Bauhaus

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