React-native-image-crop-picker: RSKimageCropper issue

Created on 28 Mar 2017  ·  25Comments  ·  Source: ivpusic/react-native-image-crop-picker

Version

Tell us which versions you are using:

  • react-native-image-crop-picker v0.12.8
  • react-native v0.42.0

Platform

Tell us to which platform this issue is related

  • iOS

Expected behaviour

run issue xcode 8.2 has no problem ,when i run in # xcode 8.3 ,it make problem

Actual behaviour

Redefinition of module 'RSKImageCropper' issue

Steps to reproduce

1.

2.

3.

Attachments

// stacktrace or any other useful debug info

Most helpful comment

@NewBen001 yes, but with the bad solution.
Just following the message's commit of https://github.com/ruslanskorb/RSKImageCropper/commit/7d5ea88c7e6fd7840cff598cc4cf7d9aafd027ac

Go to folder

node_modules/react-native-image-crop-picker/ios

rename the file

module.modulemap > RSKImageCropper.modulemap

then edit the file RSKImageCropper.xcodeproj/project.pbxproj
and add this line two times (in debug and release part Cf Commit):
MODULEMAP_FILE = "$(SRCROOT)/RSKImageCropper/RSKImageCropper.modulemap";

Clean and build. It should be works.

PS: It was a fail to me to switch on cocoapods, that's why i'm doing that and waiting for the fix.
I will try to work on a PR this week-end but not sure.

All 25 comments

@ivpusic

+1
seems this happened after updating xcode and macos today

2017-03-28 3 39 02

The same issue found, Xcode 8.3, macOS 10.12.4

+1
seems this happened after updating xcode and macos today

@ivpusic help!

Can confirm this is happening on Xcode 8.3, it is unrelated to the macOS update (I'm still on 10.12.3).
It seems that the module.modulemap exists both under node_modules folder and in Xcode's derived data folder, which result in the redefinition error.

See the path of the files here:
capture d ecran 2017-03-28 a 13 56 52

@iOSHw please try commit from @eiosca

@ivpusic what time will you fix this issue ?

@eiosca Did you fix this problem ?

@NewBen001 yes, but with the bad solution.
Just following the message's commit of https://github.com/ruslanskorb/RSKImageCropper/commit/7d5ea88c7e6fd7840cff598cc4cf7d9aafd027ac

Go to folder

node_modules/react-native-image-crop-picker/ios

rename the file

module.modulemap > RSKImageCropper.modulemap

then edit the file RSKImageCropper.xcodeproj/project.pbxproj
and add this line two times (in debug and release part Cf Commit):
MODULEMAP_FILE = "$(SRCROOT)/RSKImageCropper/RSKImageCropper.modulemap";

Clean and build. It should be works.

PS: It was a fail to me to switch on cocoapods, that's why i'm doing that and waiting for the fix.
I will try to work on a PR this week-end but not sure.

This question has affected my job......

I have same issue.. :/

modification of @eiosca solve issue <3

@eiosca could you send pull request?

@ivpusic Yeah, like i said i will try this week-end :-)

if someone can do it even sooner, PR will be welcome

I create a PR: #282, thanks to @eiosca! => It works well :)

If you want to use the PR until the merge, just do the following:

react-native unlink react-native-image-crop-picker

Edit your package.json:

"react-native-image-crop-picker": "git+https://github.com/magrinj/react-native-image-crop-picker.git#fix-rkimagecropper",

Then

react-native link react-native-image-crop-picker

And Replace pod 'RSKIMageCropper in your podfile by (until it will be released on cocoapods):

pod 'RSKImageCropper', :git => 'https://github.com/ruslanskorb/RSKImageCropper.git', :branch => 'master'

Update:
RSKImageCropper was release in 1.6.1 with the fix, you can now use all version over 1.6.1

@ivpusic any way to access this from rn 0.29?

@cwRichardKim you could fork the repo to a point in time where it was RN 0.29 compatible, and do the same changes that were done in PR #282.

@habovh ended up upgrading to .42. it was a nightmare, but finally managed to get it to work

If you use cocoa pods and you try to build it in release mode, you're going to get a failed compilation, because you need to change this in you Podfile (until it will be released on cocoapods):
From

pod 'RSKImageCropper'

To

pod 'RSKImageCropper', :git => 'https://github.com/ruslanskorb/RSKImageCropper.git', :branch => 'master'

Update:
RSKImageCropper was release in 1.6.1 with the fix, you can now use all version over 1.6.1

RSKImageCropper 1.6.1 has the issue fixed and works fine with Xcode 8.3.1

Was this page helpful?
0 / 5 - 0 ratings

Related issues

pavsidhu picture pavsidhu  ·  3Comments

xuchao321 picture xuchao321  ·  3Comments

victorwpbastos picture victorwpbastos  ·  3Comments

co-de picture co-de  ·  3Comments

equesteo picture equesteo  ·  3Comments