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

Flipper-Glog (0.3.6) build fails if Xcode application name contains a blank space #29203

Closed
therealgilles opened this issue Jun 24, 2020 · 17 comments
Labels
Needs: Triage 🔍 Stale There has been a lack of activity on this issue and it may be closed soon.

Comments

@therealgilles
Copy link

therealgilles commented Jun 24, 2020

Description

The build of Flipper-Glog (0.3.6) using 'pod install' fails if the Xcode application name contains a blank space.

React Native version:

react-native info
info Fetching system and libraries information...
System:
OS: macOS 10.16
CPU: (8) x64 Intel(R) Core(TM) i5-8259U CPU @ 2.30GHz
Memory: 87.17 MB / 8.00 GB
Shell: 3.2.57 - /bin/bash
Binaries:
Node: 12.9.1 - ~/.nvm/versions/node/v12.9.1/bin/node
Yarn: Not Found
npm: 6.14.5 - ~/.nvm/versions/node/v12.9.1/bin/npm
Watchman: 4.7.0 - /usr/local/bin/watchman
Managers:
CocoaPods: 1.9.3 - /usr/local/bin/pod
SDKs:
iOS SDK:
Platforms: iOS 14.0, DriverKit 20.0, macOS 10.16, tvOS 14.0, watchOS 7.0
Android SDK: Not Found
IDEs:
Android Studio: Not Found
Xcode: 12.0/12A6159 - /usr/bin/xcodebuild
Languages:
Java: 11.0.2 - /usr/bin/javac
Python: 2.7.16 - /usr/bin/python
npmPackages:
@react-native-community/cli: Not Found
react: 16.11.0 => 16.11.0
react-native: 0.62.2 => 0.62.2
npmGlobalPackages:
react-native: Not Found

Steps To Reproduce

  1. Name the Xcode application something like 'Xcode-beta 12.0'.
  2. Run: sudo xcode-select --switch /Applications/Xcode-beta\ 12.0.app
  3. Run: pod install

Expected Results

I would expect Flipper-Glog (0.3.6) to build properly, whatever the Xcode application name is.

Instead, it fails as follows:

checking for arm-apple-darwin-gcc... /Applications/Xcode-beta 12.0.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc -arch armv7 -isysroot /Applications/Xcode-beta 12.0.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS14.0.sdk
checking whether the C compiler works... no
/Users/USER/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6/missing: Unknown `--is-lightweight' option
Try `/Users/USER/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6/missing --help' for more information
configure: WARNING: 'missing' script is too old or missing
configure: error: in `/Users/USER/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6':
configure: error: C compiler cannot create executables
See `config.log' for more details

This seems due to the configure script not being able to handle spaces in the application name (and it's probably true for other unusual characters too).

@madeinquant
Copy link

Encountered a same error message, but Xcode application name doesn't contain a black space.

xcode-select --print-path
/Applications/Xcode.app/Contents/Developer

checking whether make supports nested variables... yes
checking for arm-apple-darwin-gcc... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc -arch armv7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS13.6.sdk
checking whether the C compiler works... no
/Users/nelson/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6/missing: Unknown --is-lightweight' option Try /Users/nelson/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6/missing --help' for more information
configure: WARNING: 'missing' script is too old or missing
configure: error: in /Users/nelson/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6': configure: error: C compiler cannot create executables See config.log' for more details

@williamgurzoni
Copy link

That's really weird, but just renaming the Xcode, removing the blank space worked for me as well.

@therealgilles
Copy link
Author

It's actually not that weird. If the application name is not properly quoted in the script, the blank space will break the syntax and the script will fail.

@gilador
Copy link

gilador commented Dec 24, 2020

Encountered a same error message, but Xcode application name doesn't contain a black space.

xcode-select --print-path
/Applications/Xcode.app/Contents/Developer

checking whether make supports nested variables... yes
checking for arm-apple-darwin-gcc... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc -arch armv7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS13.6.sdk
checking whether the C compiler works... no
/Users/nelson/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6/missing: Unknown --is-lightweight' option Try /Users/nelson/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6/missing --help' for more information
configure: WARNING: 'missing' script is too old or missing
configure: error: in /Users/nelson/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6': configure: error: C compiler cannot create executables See config.log' for more details

@madeinquant Thanks that was it!
For those who didnt understand, In case you named your xcode directory something like 'Xcode 12.2' you need to change it to Xcode12.2.app. Then you need to change your active developer path to the new path which is: sudo xcode-select --switch /Applications/Xcode12.2.app/Contents/Developer

@shivarajsb
Copy link

Encountered a same error message, but Xcode application name doesn't contain a black space.
xcode-select --print-path
/Applications/Xcode.app/Contents/Developer
checking whether make supports nested variables... yes
checking for arm-apple-darwin-gcc... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/cc -arch armv7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS13.6.sdk
checking whether the C compiler works... no
/Users/nelson/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6/missing: Unknown --is-lightweight' option Try /Users/nelson/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6/missing --help' for more information
configure: WARNING: 'missing' script is too old or missing
configure: error: in /Users/nelson/Library/Caches/CocoaPods/Pods/Release/Flipper-Glog/0.3.6-1dfd6': configure: error: C compiler cannot create executables See config.log' for more details

@madeinquant Thanks that was it!
For those who didnt understand, In case you named your xcode directory something like 'Xcode 12.2' you need to change it to Xcode12.2.app. Then you need to change your active developer path to the new path which is: sudo xcode-select --switch /Applications/Xcode12.2.app/Contents/Developer

Woah! This was the issue. I had XCode inside of my SSD which had a whitespace in the name and that was causing the issue. Thanks a lot man

@pajtimid
Copy link

pajtimid commented Apr 7, 2021

In my case, just selecting Command Line Tools on Xcode Settings and it will fix.

Screen Shot 2021-04-07 at 14 52 54

@aimekabu
Copy link

i ju

That's really weird, but just renaming the Xcode, removing the blank space worked for me as well.

Work for me

@wjatx
Copy link

wjatx commented Sep 8, 2021

In my case, just selecting Command Line Tools on Xcode Settings and it will fix.

Screen Shot 2021-04-07 at 14 52 54

This worked for me. Thanks!

@code-fi
Copy link

code-fi commented Dec 1, 2021

After all attempts and no luck, try restarting the mac

@arvenjadeaguilar
Copy link

In my case, just selecting Command Line Tools on Xcode Settings and it will fix.

Screen Shot 2021-04-07 at 14 52 54

this works in my case

@iozkan-mn
Copy link

In my case. Docker was using the 8081 port so the xcode was not able to work. When I stoped the docker container pod install worked properly

@aikhan
Copy link

aikhan commented Apr 6, 2022

In my case, just selecting Command Line Tools on Xcode Settings and it will fix.

Screen Shot 2021-04-07 at 14 52 54

This worked for

Thanks

@sajal4me
Copy link

In my case I have just disable the Roseta in to the Ternimal then run pod install

I am on M1 pro v 12.2.1 (21D62)

@DodoSpringLove
Copy link

i try to run pod install on Mac mini(Late 2014) macOS Monterey version 12.3 (21E230) and i always have this issues ,my Xcode version is 13.3.1
image
That's really weird, same macOS version and same Xcode version on my mac book pro works fine.anybody can help help pls.

image

@DodoSpringLove
Copy link

is solve my issues:#32291

@github-actions
Copy link

This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 7 days.

@github-actions github-actions bot added the Stale There has been a lack of activity on this issue and it may be closed soon. label May 16, 2023
@github-actions
Copy link

This issue was closed because it has been stalled for 7 days with no activity.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs: Triage 🔍 Stale There has been a lack of activity on this issue and it may be closed soon.
Projects
None yet
Development

No branches or pull requests