From: Simon Wright <simon@pushface.org>
Subject: Re: Exporting linker options from library GPR
Date: Thu, 15 Feb 2018 08:49:41 +0000
Date: 2018-02-15T08:49:41+00:00 [thread overview]
Message-ID: <lyh8qik57e.fsf@pushface.org> (raw)
In-Reply-To: 836a0b01-419e-4b53-a15c-75bc7d41b462@googlegroups.com
[-- Attachment #1: Type: text/plain, Size: 1002 bytes --]
Lucretia <laguest9000@googlemail.com> writes:
Do you think we should raise an issue on github for this discussion? (to
take it off the group)
> I have it building on Mac OS X as a static lib, but the options are
> controlled from the makefile.
When I built it as a dynamic library, I got (with some builds) an ACCVIO
during elaboration, which I took to be down to failing to initialize
libsdlada.dylib (it's not built as an SAL).
> To make it consistent, I'd either have to remove the sdl2-config call
> for other all other OSes and get the flags from the script and copy
> them across, hoping they are correct. Or, the sdl2-config needs to be
> callable and expandable from the gpr file, which I don't think is
> possible.
>
> So, before I push the changes, can anyone tell me if this is possible?
As a possible alternative, the attached makefile fragment works out
whether you're on Darwin or not, so you could decide in the makefile how
to get the options & then pass them through to the gpr.
[-- Attachment #2: Mkaefile fragment --]
[-- Type: text/plain, Size: 294 bytes --]
DARWIN = $(shell if gcc -v 2>&1 | grep darwin >/dev/null 2>&1; then \
echo 1; \
else \
echo 0; \
fi)
FLAGS = $(shell if [ $(DARWIN) -eq 1 ]; then \
echo "-framework SDL2"; \
else \
echo "result of sdl2-config"; \
fi)
all:
@echo $(FLAGS)
next prev parent reply other threads:[~2018-02-15 8:49 UTC|newest]
Thread overview: 31+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-19 14:25 Exporting linker options from library GPR Simon Wright
2018-01-19 16:10 ` Dmitry A. Kazakov
2018-01-19 17:25 ` Simon Wright
2018-01-20 18:15 ` Stephen Leake
2018-02-13 9:43 ` Luke A. Guest
2018-02-13 18:37 ` Lucretia
2018-02-13 20:30 ` Simon Wright
2018-02-13 20:37 ` Simon Wright
2018-02-14 6:29 ` Luke A. Guest
2018-02-13 20:42 ` Simon Wright
2018-02-14 7:10 ` Luke A. Guest
2018-02-14 9:33 ` Simon Wright
2018-02-14 9:59 ` Luke A. Guest
2018-02-15 1:04 ` Lucretia
2018-02-15 8:49 ` Simon Wright [this message]
2018-02-15 10:06 ` Lucretia
2018-02-15 11:39 ` Simon Wright
2018-02-15 15:22 ` Lucretia
2018-02-15 15:24 ` Lucretia
2018-02-15 18:38 ` Lucretia
2018-02-15 18:42 ` Lucretia
2018-02-15 20:52 ` Simon Wright
2018-02-15 23:14 ` Luke A. Guest
2018-02-16 8:29 ` Simon Wright
2018-02-16 23:26 ` Stephen Leake
2018-02-17 7:49 ` Simon Wright
2018-02-17 14:51 ` Lucretia
2018-02-17 15:43 ` Simon Wright
2018-02-17 15:52 ` Lucretia
2018-02-16 7:29 ` Lucretia
2018-02-13 9:50 ` Luke A. Guest
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox