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

[glog] During pod install: ./configure: No such file or directory #20772

Closed
3 tasks done
iwasrobbed-ks opened this issue Aug 21, 2018 · 3 comments
Closed
3 tasks done
Labels
Bug Platform: iOS iOS applications. Resolution: For Stack Overflow A question for Stack Overflow. Applying this label will cause issue to be closed. Resolution: Locked This issue was locked by the bot.

Comments

@iwasrobbed-ks
Copy link

iwasrobbed-ks commented Aug 21, 2018

Reproducible?

Yes, I had a colleague follow the instructions in the repo below on their computer and it gave them the same error.

https://github.com/rob-keepsafe/RNGlogIssue

Environment

  React Native Environment Info:
    System:
      OS: macOS High Sierra 10.13.6
      CPU: x64 Intel(R) Core(TM) i7-4870HQ CPU @ 2.50GHz
      Memory: 1.58 GB / 16.00 GB
      Shell: 5.3 - /bin/zsh
    Binaries:
      Node: 8.7.0 - ~/.nvm/versions/node/v8.7.0/bin/node
      Yarn: 1.3.2 - /usr/local/bin/yarn
      npm: 6.4.0 - ~/.nvm/versions/node/v8.7.0/bin/npm
    SDKs:
      iOS SDK:
        Platforms: iOS 11.4, macOS 10.13, tvOS 11.4, watchOS 4.3
    IDEs:
      Xcode: 9.4.1/9F2000 - /usr/bin/xcodebuild
    npmPackages:
      react: 16.0.0-beta.5 => 16.0.0-beta.5
      react-native: ^0.56.0 => 0.56.0
    npmGlobalPackages:
      react-native-cli: 2.0.1

Error Description

While running pod install, it errors on glog with the error below.

Note: the file source shown below is located at: node_modules/react-native/scripts/ios-configure-glog.sh

Installing glog (0.3.4)
[!] /bin/bash -c
set -e
#!/bin/bash
set -e

PLATFORM_NAME="${PLATFORM_NAME:-iphoneos}"
CURRENT_ARCH="${CURRENT_ARCH}"

if [ -z "$CURRENT_ARCH" ] || [ "$CURRENT_ARCH" == "undefined_arch" ]; then
    # Xcode 10 beta sets CURRENT_ARCH to "undefined_arch", this leads to incorrect linker arg.
    # it's better to rely on platform name as fallback because architecture differs between simulator and device

    if [[ "$PLATFORM_NAME" == *"simulator"* ]]; then
        CURRENT_ARCH="x86_64"
    else
        CURRENT_ARCH="armv7"
    fi
fi

export CC="$(xcrun -find -sdk $PLATFORM_NAME cc) -arch $CURRENT_ARCH -isysroot $(xcrun -sdk $PLATFORM_NAME --show-sdk-path)"
export CXX="$CC"

# Remove automake symlink if it exists
if [ -h "test-driver" ]; then
    rm test-driver
fi

./configure --host arm-apple-darwin

# Fix build for tvOS
cat << EOF >> src/config.h

/* Add in so we have Apple Target Conditionals */
#ifdef __APPLE__
#include <TargetConditionals.h>
#include <Availability.h>
#endif

/* Special configuration for AppleTVOS */
#if TARGET_OS_TV
#undef HAVE_SYSCALL_H
#undef HAVE_SYS_SYSCALL_H
#undef OS_MACOSX
#endif

/* Special configuration for ucontext */
#undef HAVE_UCONTEXT_H
#undef PC_FROM_UCONTEXT
#if defined(__x86_64__)
#define PC_FROM_UCONTEXT uc_mcontext->__ss.__rip
#elif defined(__i386__)
#define PC_FROM_UCONTEXT uc_mcontext->__ss.__eip
#endif
EOF

/bin/bash: line 27: ./configure: No such file or directory

Relevant section of Podfile:

react_pod 'React', npm_path: 'react-native', subspecs: %w[
    Core
    CxxBridge
    RCTImage
    RCTNetwork
    RCTText
    RCTLinkingIOS
    RCTWebSocket
    RCTAnimation
  ]
# Required by ReactNative
react_pod 'yoga', npm_path: 'react-native/ReactCommon/yoga'
react_pod 'DoubleConversion', npm_path: 'react-native/third-party-podspecs'
react_pod 'glog', npm_path: 'react-native/third-party-podspecs'
react_pod 'Folly', npm_path: 'react-native/third-party-podspecs'
@hramos hramos added the Platform: iOS iOS applications. label Aug 21, 2018
@Unoken
Copy link

Unoken commented Nov 20, 2018

Same error :(, i wasted 2 days for this, try some solutions but none work. @rob-keepsafe : do you resolved this?

@juansimon18
Copy link

juansimon18 commented Jan 23, 2019

@Unoken could you try this: It worked for me:
sudo xcode-select --switch /Applications/Xcode.app
Check the original answer on SO: https://stackoverflow.com/questions/53028367/glog-configure-warning-missing-script-is-too-old-or-missing

@Salakar
Copy link
Contributor

Salakar commented Apr 10, 2019

👋 hey all; thanks for raising this issue and also for posting a way to fix the issue.

Given @juansimon18 response above I'm inclined to think this is a local dev environment issue rather than being specific to React Native; admittedly the error message could maybe specify how to resolve the issue as above (but I'm not sure this is something that can be done from React Native, unfortunately).

Because of this; I'm going to go ahead and close this for now.

Thank you

@Salakar Salakar closed this as completed Apr 10, 2019
@Salakar Salakar added the Resolution: For Stack Overflow A question for Stack Overflow. Applying this label will cause issue to be closed. label Apr 10, 2019
@facebook facebook locked as resolved and limited conversation to collaborators Apr 10, 2020
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Apr 10, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug Platform: iOS iOS applications. Resolution: For Stack Overflow A question for Stack Overflow. Applying this label will cause issue to be closed. Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

6 participants