tuist icon indicating copy to clipboard operation
tuist copied to clipboard

Mergeable library linker flags override user defined flags at target level

Open amarcadet opened this issue 2 years ago • 0 comments

What problem or need do you have?

In my project I need to set flags -ObjC -all_load at project or target level.

When adopting mergeable library, Tuist automatically generates the OTHER_LDFLAGS and override the build settings defined at the target (or project) level.

Capture below shows target and project level:

Capture d’écran 2024-02-13 à 19 46 47

Potential solution

Tuist could set $(inherited) in the build settings when adopting mergeable libraries, allowing OTHER_LDFLAGS at project level.

It could be a much harder task but there might be a need to a higher level of merge for the build settings to ensure that internal logic of Tuist can't break user defined settings.

Alternatively, Tuist could generated .xcconfig files like cocoapods do to set its settings instead of directly writing in target build settings and ensure that overridden settings at user level always included $(inherited).

macOS version

14.2.1

Tuist version

4.1.1

Xcode version

15.2

amarcadet avatar Feb 13 '24 18:02 amarcadet