Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

member of multiple groups indicates a malformed project or loss of compilerFlags #782

Open
mobileben opened this issue Feb 13, 2020 · 3 comments

Comments

@mobileben
Copy link

We are looking to move away from pods. As part of the process, we care converting the pods to yml so we can generate Xcode project files. This is a precautionary step in case we ever want to be able to debug a pod.

I'm working on FBSDKCoreKit, which has one file which doesn't use ARC. However, I am having a difficult time getting it to work right.

It's either my syntax/ordering or perhaps a bug.

If I use this to define the sources

    sources:
      - path: ../Pods/FBSDKCoreKit/FBSDKCoreKit/FBSDKCoreKit/Internal_NoARC/FBSDKDynamicFrameworkLoader.m
        compilerFlags: "-fno-objc-arc"
      - path: ../Pods/FBSDKCoreKit/FBSDKCoreKit/FBSDKCoreKit
        includes: "**/*.[hm]"
        excludes: Internal_NoARC/FBSDKDynamicFrameworkLoader.m

I receive a warning like the following. The build will work, however.

2020-02-13 14:03:55.266 xcodebuild[4804:1782108] warning: The file reference for "../Pods/FBSDKCoreKit/FBSDKCoreKit/FBSDKCoreKit/Internal_NoARC" is a member of multiple groups ("FBSDKCoreKit" and ""); this indicates a malformed project. Only the membership in one of the groups will be preserved (but membership in targets will be unaffected). If you want a reference to the same file in more than one group, please add another reference to the same path.

Note that I've gotten rid of the excludes and the same error message will result.

I tried to re-order, but ordering does seem to matter, since if I re-order like the following

    sources:
      - path: ../Pods/FBSDKCoreKit/FBSDKCoreKit/FBSDKCoreKit
        includes: "**/*.[hm]"
        excludes: Internal_NoARC/FBSDKDynamicFrameworkLoader.m
      - path: ../Pods/FBSDKCoreKit/FBSDKCoreKit/FBSDKCoreKit/Internal_NoARC/FBSDKDynamicFrameworkLoader.m
        compilerFlags: "-fno-objc-arc"

-fno-objc-arc will not be set.

Screen Shot 2020-02-13 at 2 09 14 PM

Is my syntax incorrect? Or is this a case where xcodegen cannot properly handle it? Or do I just accept the warning and ignore it?

@mobileben
Copy link
Author

This warning can also happen if you have a 2 paths that are the same, but use different groups.

@grigorye
Copy link

Just in case, I've just faced the following warning when invoking xcodebuild for our project:

The file reference for "UnitTests/Resources" is a member of multiple groups ("UnitTests" and "");

and was able to get rid of it by adding createIntermediateGroups: true option to the options: section of .yml.

@thislooksfun
Copy link

I can also confirm, adding createIntermediateGroups: true fixed it for me as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants