[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: GNUstep make, linking to frameworks in the app wrapper
From: |
Richard Frith-Macdonald |
Subject: |
Re: GNUstep make, linking to frameworks in the app wrapper |
Date: |
Sat, 4 Mar 2023 15:58:49 +0000 |
> On 3 Mar 2023, at 17:11, Andreas Höschler <ahoesch@smartsoft.de> wrote:
>
> Now that I have moved the framework I cannot even build the app anymore
> because it can't find the header.
>
> cd <app project dir>
> make
>
> retina:TestApp3 ahoesch$ make install
> This is gnustep-make 2.4.0. Type 'make print-gnustep-make-help' for help.
> Making all for app TestApp3...
> Compiling file DocumentController.m ...
> clang: warning: /Build/TestFW/TestFW.framework/Headers: 'linker' input unused
> DocumentController.m:2:9: fatal error: 'TestFW/Person.h' file not found
> #import <TestFW/Person.h>
> ^
> 1 error generated.
>
>
> I tinkered around with)
>
> ADDITIONAL_INCLUDE_DIRS += /Build/TestFW/TestFW.framework/Headers
> ADDITIONAL_LIB_DIRS += /Build/TestApp3/TestApp3.app/Contents/Resources
I don't use frameworks (I think the gnustep-make documentation has always said
to use bindles instead), and certainly not within an app wrapper, but you might
try setting ADDITIONAL_FRAMEWORK_DIRS to point to the framework you want
gnustep-make to use.
> One approach would certainly be to get rid of GNUstep make and use xCode
> instead for this. But I would like to stick to GNUstep make if possible!? Is
> there a way to make the app look into the app wrapper for libs and frameworks?
I think, since frameworks are essentially dynamic libraries, you probably need
the load path to be specified by the LD_LIBRARY_PATH environment variable or
similar, and that probably need to be done before the binary starts executing.
But putting things in the app wrapper seems similar to packaging an entire
system standalone (in a single folder) and gnustep-make already has a
mechanism to do that ... the standalone filesystem layout in conjunction with
a GNUstep.conf file telling the software whwre to find everything.
This was for packaging gnustep applications for distribution on ms-windows, so
it's documented in README.MinGW
It's not quite what you want, because it expects *everything* inside the app
wrapper, and presumably you want some stuff in the normal locations, but I
expect you copuld simply adapt it by using a different filesystem layout where
instead of the domains SYSTEM,NETWORK,LOCAL all pointing into the app wrapper,
you just used one of them (eg NETWORK) to point there, and left the others
pointing to the normal locations.