comp.lang.ada
 help / color / mirror / Atom feed
From: mockturtle <framefritti@gmail.com>
Subject: gpr and Makefiles
Date: Mon, 27 Jan 2020 08:22:40 -0800 (PST)
Date: 2020-01-27T08:22:40-08:00	[thread overview]
Message-ID: <033b9157-cc60-42cd-a7a8-ee4313029752@googlegroups.com> (raw)

Dear.all, 
I have a question about the interaction between gprbuild and Makefile. I googled a bit and found mostly how to use gprbuild inside a Makefile, but, in a sense, I am interested in the other way around.

More precisely, among all my source files there is one package (say, foo.ads) that it is actually generated by an external file (say, bar.txt) using an utility (call it "convert").  The matter is a bit more complex, but this is the core of the issue.  

I can express the dependency between foo.ads and bar.txt in a Makefile like

foo.ads: bar.txt
       convert --from=bar.txt --to=foo.ads

What I would like is having gprbuild checking if bar.txt is newer than foo.ads; if it is, run convert and after that proceed with the actual building.

Is this possible?

I also checked Gem #152 (https://www.adacore.com/gems/gem-152-defining-a-new-language-in-a-project-file) about defining a new language inside a gpr file, but I am not sure it can be a solution.

Thank you in advance for your help

Riccardo


             reply	other threads:[~2020-01-27 16:22 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-01-27 16:22 mockturtle [this message]
2020-01-27 17:49 ` gpr and Makefiles Shark8
2020-01-27 19:32   ` mockturtle
2020-01-27 19:46   ` Simon Wright
2020-01-27 20:30     ` mockturtle
2020-01-27 20:28   ` mockturtle
2020-01-28 11:57     ` briot.emmanuel
replies disabled

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