Skip to content
This repository has been archived by the owner on Sep 17, 2021. It is now read-only.

Build failed in RN 0.45.1 (iOS) #169

Closed
sajjadrad opened this issue Jul 11, 2017 · 13 comments
Closed

Build failed in RN 0.45.1 (iOS) #169

sajjadrad opened this issue Jul 11, 2017 · 13 comments

Comments

@sajjadrad
Copy link

Hi,
I have some problems in building in xcode. First there was some errors about importing React in RNSVG. after solving that now this error occurs:
clang: error: linker command failed with exit code 1 (use -v to see invocation)
This happened after linking react-native-svg.

xcodebuild command:
The following build commands failed: CompileC build/Foo.build/Release-iphonesimulator/foo.build/Objects-normal/x86_64/AppDelegate.o foo/AppDelegate.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler

react-native run-ios command:
The following build commands failed: Ld build/Build/Products/Debug-iphonesimulator/Foo.app/Foo normal x86_64

RN : 0.45.1
iOS

@sajjadrad
Copy link
Author

After unlinking react-native-svg, app starts normally but with RNSVG not found error.

@csdwd
Copy link

csdwd commented Jul 11, 2017

I also encountered the same problem.
clang: error: linker command failed with exit code 1 (use -v to see invocation)

 "react": "16.0.0-alpha.12",
    "react-native": "0.46.1",
    "react-native-pathjs-charts": "0.0.29",
    "react-navigation": "^1.0.0-beta.11"

@marzolfb
Copy link
Contributor

There's an incompatibility problem between the version of react-native-svg this lib uses (~5.2.0) and the react-native-svg version (~5.3.0) that is compatible with the latest stable react-native version (0.46.1). Once #170 gets completed, merged in, and a new version of this lib gets pushed to npm, hopefully the errors seen on this issue will disappear.

@sajjadrad
Copy link
Author

@marzolfb Thanks for answer, how much time do you estimate for these actions?

@marzolfb
Copy link
Contributor

@sajjadrad Just pushed a new version to npm a little bit ago. Give it a try and let me know how it goes.

@sajjadrad
Copy link
Author

@marzolfb I upgraded your package to 0.0.30 and rn-svg to 5.3 but I have same error after linking while building.

@marzolfb
Copy link
Contributor

I will likely need some more details to help. What are your installed versions of dependencies - what is the out of this

npm list react react-native react-native-svg paths-js

?

Also, what is your Xcode version?

Also, I assume you experience this with your own app and trying to use this library but have you tried building/running the example app? Do you experience the same issue?

@sajjadrad
Copy link
Author

├── react@16.0.0-alpha.12 ├── react-native@0.46.1 ├─┬ react-native-pathjs-charts@0.0.30 │ ├── paths-js@0.4.5 │ └── react-native-svg@5.3.0 └── react-native-svg@5.3.0

Xcode 8.3.1

Example app works properly. I think I have problems with react-native-svg package. It installed twice 🤔

@sajjadrad
Copy link
Author

sajjadrad commented Jul 13, 2017

I uninstalled react-native-pathjs-charts and react-native-svg and install react-native-pathjs-charts again. this is my list output now:

├── react@16.0.0-alpha.12 ├── react-native@0.46.1 └─┬ react-native-pathjs-charts@0.0.30 ├── paths-js@0.4.5 └── react-native-svg@5.3.0

After linking react-native-svg with react-native link react-native-svg command, I have clang: error: linker command failed with exit code 1 (use -v to see invocation) error again :(

@marzolfb
Copy link
Contributor

What happens if you start from scratch:

rm -rm node_modules
npm install
react-native link react-native-svg
react-native run-ios

Same error?

What other troubleshooting steps have you tried?

Is there any more to the error chain that could be helpful?

@sajjadrad
Copy link
Author

Same error after linking, and run ok after unlink react-native-svg

@marzolfb
Copy link
Contributor

What are the differences between the example app and your app? Is the source/package.json for your app available somewhere publicly that I (and/or others) could try to reproduce the problem you are experiencing?

@sajjadrad
Copy link
Author

@marzolfb I checked react-native-svg issues and found this.

After removing RNSVG-TV schema, it works.

Thanks

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

No branches or pull requests

3 participants