Closed Ivanov89 closed 5 years ago
@Ivanov89 thx for reporting. appreciate it!
any X.X.X-alphaX is considering "pre release" and might be unstable. however your error above seems really strange.
tested 0.24.0-alpha9
under multiple conditions and it looks ok including rnv new
command
could you specify what command/steps you executed? I don't see ReNative SUMMARY box in you log above (that would help)
Also check if your issue is not related to: https://stackoverflow.com/questions/48928498/configure-error-c-compiler-cannot-create-executables-react-native
Few questions to help us understand your issue:
rnv new
?npx rnv status
outputNote: SUMMARY box appears at the end of your log.. should look something like this:
$ rnv status - Done! 🚀
┌──────────────────────────────────────────────────────────────────────────────┐
│ 🚀 SUMMARY | 8/7/2019, 1:04:53 PM │
│ $ rnv status │
├──────────────────────────────────────────────────────────────────────────────┤
│ Project Name: hello-renative │
│ Project Version: 0.1.0 │
│ App Config: helloWorld │
│ Supported Platfroms: ios, android, androidtv, androidwear, │
│ web, tizen, tizenmobile, tvos, webos, macos, windows, tizenwatch, │
│ kaios, firefoxos, firefoxtv │
│ Master Template: renative-template-hello-world │
│ Env Info: darwin | x64 | node v10.15.3 | rnv v0.24.0-alpha9 │
│ Executed Time: 0h:0m:0s:23ms │
│ │
│ All good as 🦄 │
│ │
└──────────────────────────────────────────────────────────────────────────────┘
Hi @pavjacko , may be you didn't understand me :)
I created the project from my working machine with 0.24.0-alpha5
and pushed it to the github.
From my home machine I updated RNV to 0.24.0-alpha9
I cloned my repo (with the previous version of RNV) in my home machine, started the server and when I made:
rnv run -p ios
it crashed with the upper error
This is the summery box:
$ rnv status - Done! 🚀 ┌──────────────────────────────────────────────────────────────────────────────┐ │ 🚀 SUMMARY | 8/7/2019, 2:36:09 PM │ │ $ rnv status │ ├──────────────────────────────────────────────────────────────────────────────┤ │ Project Name: cmslobbyapp │ │ Project Version: 0.1.0 │ │ App Config: helloWorld │ │ Supported Platfroms: ios, android, androidtv, androidwear, │ │ web, tizen, tizenmobile, tvos, webos, macos, windows, tizenwatch, │ │ kaios, firefoxos, firefoxtv │ │ Master Template: renative-template-hello-world │ │ Env Info: darwin | x64 | node v12.4.0 | rnv v0.24.0-alpha5 │ │ Executed Time: 0h:0m:0s:130ms │ │ │ │ All good as 🦄 │ │ │ └──────────────────────────────────────────────────────────────────────────────
But locally I am using RNV: v0.24.0-alpha9
@Ivanov89
ah! right :) that's easy. always use npx ...
when running from project
this ensures that your rnv
version is exact match
for example you create new project with 0.24.0-alpha5
that project is compatible with 0.24.0-alpha5
then you upgrade your rnv
to 0.24.0-alpha9
but your old project might not be compatible.
when running from project you have 2 options:
1) rnv run -p ....
=> uses your global 0.24.0-alpha9
to run your 0.24.0-alpha5
project = BAD
2) npx rnv run -p ...
=> uses your local (per-project) 0.24.0-alpha5
to run your 0.24.0-alpha5
project = GOOD
so run npm i
and then you can use npx rnv ...
that allows you run compatible rnv
for each project
you can upgrade rnv
per project basis from your package.json
Ok, when I change RNV version in package.json
, how that version is applied - automatically when hit rnv start
?
yes, but AFAIK it is the other way around. Change it on plugins.json and that will autoupdate package.json
Updated the RNV version in plugins.json to be the same as on my machine:
"plugins": { "renative": { "version": "0.24.0-alpha9", "path": "node_modules/renative" },
And still have an error when I run rnv run -p ios:
`Installing glog (0.3.5) [!] /bin/bash -c set -e
#
set -e
PLATFORM_NAME="${PLATFORM_NAME:-iphoneos}" CURRENT_ARCH="${CURRENT_ARCH}"
if [ -z "$CURRENT_ARCH" ] || [ "$CURRENT_ARCH" == "undefined_arch" ]; then
# 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"
if [ -h "test-driver" ]; then rm test-driver fi
./configure --host arm-apple-darwin
cat << EOF >> src/config.h
/ Add in so we have Apple Target Conditionals /
/ Special configuration for AppleTVOS /
/ Special configuration for ucontext /
EOF
EXPORTED_INCLUDE_DIR="exported/glog" mkdir -p exported/glog cp -f src/glog/log_severity.h "$EXPORTED_INCLUDE_DIR/" cp -f src/glog/logging.h "$EXPORTED_INCLUDE_DIR/" cp -f src/glog/raw_logging.h "$EXPORTED_INCLUDE_DIR/" cp -f src/glog/stl_logging.h "$EXPORTED_INCLUDE_DIR/" cp -f src/glog/vlog_is_on.h "$EXPORTED_INCLUDE_DIR/"
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for arm-apple-darwin-strip... no
checking for strip... strip
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking for arm-apple-darwin-gcc... /Library/Developer/CommandLineTools/usr/bin/cc -arch armv7 -isysroot
checking whether the C compiler works... no
xcrun: error: SDK "iphoneos" cannot be located
xcrun: error: SDK "iphoneos" cannot be located
xcrun: error: SDK "iphoneos" cannot be located
xcrun: error: unable to lookup item 'Path' in SDK 'iphoneos'
/Users/Ivanov/Library/Caches/CocoaPods/Pods/External/glog/2263bd123499e5b93b5efe24871be317-aefd1/missing: Unknown --is-lightweight' option Try
/Users/Ivanov/Library/Caches/CocoaPods/Pods/External/glog/2263bd123499e5b93b5efe24871be317-aefd1/missing --help' for more information
configure: WARNING: 'missing' script is too old or missing
configure: error: in /Users/Ivanov/Library/Caches/CocoaPods/Pods/External/glog/2263bd123499e5b93b5efe24871be317-aefd1': configure: error: C compiler cannot create executables See
config.log' for more details
⚠️ $ rnv run -p ios - WARNING: Error: process exited with code 1
┌──────────────────────────────────────────────────────────────────────────────┐
│ 🚀 SUMMARY | 8/7/2019, 3:45:40 PM │
│ $ rnv run -p ios │
├──────────────────────────────────────────────────────────────────────────────┤
│ Project Name: cmslobbyapp │
│ Project Version: 0.1.0 │
│ App Config: helloWorld │
│ Supported Platfroms: ios, android, androidtv, androidwear, │
│ web, tizen, tizenmobile, tvos, webos, macos, windows, tizenwatch, │
│ kaios, firefoxos, firefoxtv │
│ Master Template: renative-template-hello-world │
│ Env Info: darwin | x64 | node v12.4.0 | rnv v0.24.0-alpha9 │
│ Platform: ios │
│ Executed Time: 0h:7m:44s:105ms │
│ │
│ ⚠️ $ rnv run -p ios - WARNING: Error: process exited with code 1
│ ⚠️ $ rnv run -p ios - WARNING: Looks like pod install is not enough! Let's try pod update! Error: Error: process exited with code 1
│ 🛑 $ rnv run -p ios - ERRROR! process exited with code 1
Error: process exited with code 1
at ChildProcess.
Tried to go into platformTemplates/ios
and run "pod update" or "pod install" but there are another errors:
[!] Invalid
Podfile` file: syntax error, unexpected '}', expecting =>
{{PLUGIN_WARNINGS}}
^
/Volumes/B/PROJECTS/CMSLobbyApp/fowl-play-casino/platformTemplates/ios/Podfile:7: syntax error, unexpected '}', expecting =>
{{PLUGIN_SUBSPECS}}
^
/Volumes/B/PROJECTS/CMSLobbyApp/fowl-play-casino/platformTemplates/ios/Podfile:14: syntax error, unexpected '}', expecting =>
{{PLUGIN_PATHS}}
^
/Volumes/B/PROJECTS/CMSLobbyApp/fowl-play-casino/platformTemplates/ios/Podfile:22: syntax error, unexpected '}', expecting =>.
{{PLUGIN_WARNINGS}}
-------------------------------------------`
@Ivanov89 your project is generated with 0.24.0-alpha5
but your logs says rnv v0.24.0-alpha9
So can you follow these steps:
STEP 1 (ensure correct dependency)
your package.json
should have:
"devDependecies" : {
...
"rnv": "0.24.0-alpha9"
...
}
STEP 2 (clean your project)
rnv clean
STEP 3 (install everything)
npm i
STEP 4 (run clean ios build with npx)
npx rnv run -p ios -r
that should remove any obvious issues and help pinpoint the problem if still exists
also error above indicates that there is issue with corrupted Podfile. this glog error is just manifestation of it. if above steps don't fix your problem can you share logs from the beginning of run up to the point of Installing glog (0.3.5)
to see if there is anything suspicious in task execution history
@Ivanov89 Ah ok I see now... looks like you're using ejected platforms mode
ok before you do above can you run:
rnv platform connect
will give you status of your platforms. if you see (ejected) on ios pick it to make sure you using connected mode
should look similar:
❓ This will point platformTemplates folders from your local project to ReNative managed one. Select platforms you would like to connect comma separated
-[1] ios - (connected)
-[2] android - (connected)
-[3] androidtv - (connected)
-[4] web - (connected)
-[5] macos - (connected)
...
and try above suggestion
if you still have issues please provide logs from start of your command up to the point of Installing glog (0.3.5)
to check if there there isn't something suspicious in task execution
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Guys, what is happened? I have a brand new RNV project made with RNV:
0.24.0-alpha5
version on my Mac on work.Now I just updated the RNV today in my home Mac and the version is:
0.24.0-alpha9
Trying to run it on: iOS and it stop when Installing glog (0.3.5) with:
`[!] /bin/bash -c set -e
!/bin/bash
Copyright (c) Facebook, Inc. and its affiliates.
#
This source code is licensed under the MIT license found in the
LICENSE file in the root directory of this source tree.
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.
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
include
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
Prepare exported header include
EXPORTED_INCLUDE_DIR="exported/glog" mkdir -p exported/glog cp -f src/glog/log_severity.h "$EXPORTED_INCLUDE_DIR/" cp -f src/glog/logging.h "$EXPORTED_INCLUDE_DIR/" cp -f src/glog/raw_logging.h "$EXPORTED_INCLUDE_DIR/" cp -f src/glog/stl_logging.h "$EXPORTED_INCLUDE_DIR/" cp -f src/glog/vlog_is_on.h "$EXPORTED_INCLUDE_DIR/"
checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for arm-apple-darwin-strip... no checking for strip... strip checking for a thread-safe mkdir -p... ./install-sh -c -d checking for gawk... no checking for mawk... no checking for nawk... no checking for awk... awk checking whether make sets $(MAKE)... yes checking whether make supports nested variables... yes checking for arm-apple-darwin-gcc... /Library/Developer/CommandLineTools/usr/bin/cc -arch armv7 -isysroot checking whether the C compiler works... no xcrun: error: SDK "iphoneos" cannot be located xcrun: error: SDK "iphoneos" cannot be located xcrun: error: SDK "iphoneos" cannot be located xcrun: error: unable to lookup item 'Path' in SDK 'iphoneos' /Users/Ivanov/Library/Caches/CocoaPods/Pods/External/glog/2263bd123499e5b93b5efe24871be317-aefd1/missing: Unknown
--is-lightweight' option Try
/Users/Ivanov/Library/Caches/CocoaPods/Pods/External/glog/2263bd123499e5b93b5efe24871be317-aefd1/missing --help' for more information configure: WARNING: 'missing' script is too old or missing configure: error: in/Users/Ivanov/Library/Caches/CocoaPods/Pods/External/glog/2263bd123499e5b93b5efe24871be317-aefd1': configure: error: C compiler cannot create executables
Please, give me an info how to downgrade to some specific older stable version, because every time something is broken on the last version and I cannot used your framework for my project. Thank you !