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

can't build release for android - Windows 7 #4170

Closed
InnerPeace080 opened this issue Nov 17, 2015 · 6 comments
Closed

can't build release for android - Windows 7 #4170

InnerPeace080 opened this issue Nov 17, 2015 · 6 comments
Labels
Platform: Windows Building on Windows. Resolution: Locked This issue was locked by the bot.

Comments

@InnerPeace080
Copy link
Contributor

hi . i follow tutorial at here (http://facebook.github.io/react-native/docs/signed-apk-android.html#content)

but when i run command "gradlew assembleRelease" in cmd (i use window 7 , 64 bit) .
it fail at line ':app:bundleReleaseJsAndAssets'

i have spend much time to find out what happen here. When i use --stacktrace , --info , and --debug flag as recommend . it say fail when run command "react-native bundle ..."

when i run above command alone , it stuck in 5 minute (that is timeout of create server as i founded) and return error : listen EACCES , port : -1

seem like a permision error, but i can't find anything else , i run command with admintrator .

Sorry about my english.

@InnerPeace080 InnerPeace080 changed the title can't build release for android can't build release for android - Windows 7 Nov 17, 2015
@AnnatarHe
Copy link

i have same issue like you....

@danhanfry
Copy link

Exactly the same, I give more details here
#4124

@InnerPeace080
Copy link
Contributor Author

i have just success when run command 'react-native bundle ...' alone (i change way to server and client work (PATH -->> PORT) in SocketInterface node modul (i change js code in 2 file : 'SocketInterface.js' and 'index.js')) .

capture

but it still fail when run command 'gradlew assembleRelease' :(((.

capture2

. and now. i ignore file 'react.gradle ' (delete line 'apply from: "react.gradle"' in file 'build.gradle') and do manual follow this
$ mkdir -p android/app/src/main/assets
$ react-native bundle --platform android --dev false --entry-file index.android.js \ --bundle-output android/app/src/main/assets/index.android.bundle \ --assets-dest android/app/src/main/res/
$ cd android && ./gradlew assembleRelease

and it fail at :
capture3

i create signing key as recommend (https://facebook.github.io/react-native/docs/signed-apk-android.html#content).
anybody have some suggestion?

@InnerPeace080
Copy link
Contributor Author

finally. i success to build release for android. i must write password, keyAlias... direct to build.gradle file (not use variable in gradle.properties anymore). i don't know why (so confusing):

capture5

and by use solution here : hzerica@32c755b

i success to run command ' gradlew assembleRelease '

this is 2 file that i modify ('index.js' and 'socketserver.js' in 'node_modules\react-native\packager\react-packager\src\SocketInterface')

SocketServer.js.txt
index.js.txt

you will want to delete line 'const ipc = require('node-ipc');' in 2 file (because i tried to use node-ipc , but not success )

@InnerPeace080
Copy link
Contributor Author

better solution #4071 .

@ismeteor
Copy link

I had installed react-native-cli fiexed this issue.

@facebook facebook locked as resolved and limited conversation to collaborators Jul 20, 2018
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Jul 20, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Platform: Windows Building on Windows. Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

6 participants