【问题标题】:How to " run make bootstrap" while opening Kickstarter source codeHow to " run make bootstrap" while opening Kickstarter source code
【发布时间】:2022-11-09 12:59:13
【问题描述】:

I encountered this google service missing error when I try to run the app Kickstarter from GitHub in Android Studio.

Tried to look for answers and I found that I am supposed to run "make bootstrap" but I really can't quite understand how you do it (I'm still a novice in coding/android/github in general).

Here is the error:

File google-services.json is missing. The Google Services Plugin cannot function without it.
Searched Location:
C:\Users\naufa\AndroidStudioProjects\android-oss\app\src\external\min21\debug\google-services.json 
C:\Users\naufa\AndroidStudioProjects\android-oss\app\src\externalMin21\debug\google-services.json
C:\Users\naufa\AndroidStudioProjects\android-oss\app\src\debug\externalMin21\google-services.json
C:\Users\naufa\AndroidStudioProjects\android-oss\app\src\external\debug\google-services.json
C:\Users\naufa\AndroidStudioProjects\android-oss\app\src\external\min21\google-services.json
C:\Users\naufa\AndroidStudioProjects\android-oss\app\src\external\min21Debug\google-services.json
C:\Users\naufa\AndroidStudioProjects\android-oss\app\src\externalMin21\google-services.json
C:\Users\naufa\AndroidStudioProjects\android-oss\app\src\debug\google-services.json
C:\Users\naufa\AndroidStudioProjects\android-oss\app\src\externalMin21Debug\google-services.json
C:\Users\naufa\AndroidStudioProjects\android-oss\app\src\external\google-services.json
C:\Users\naufa\AndroidStudioProjects\android-oss\app\src\externalDebug\google-services.json
C:\Users\naufa\AndroidStudioProjects\android-oss\app\google-services.json

The scenario was:

I imported the project into Android Studio, when I try to run the app, the error above pops up. I browsed for solutions and found out that I need to run "make bootstrap" in some sort of terminal/CMD, but I have zero ideas on how to do that. I don't even know what a bootstrap is.

There was a lot of different answers that I have no idea how to do since the answers was meant for non-beginners. I'm so confused, some help would be greatly appreciated.

I'm running Windows 11 64-bit, if there is any other info I should provide please do tell me. Here's the Clone link if anyone would like to open it in Android Studio: https://github.com/kickstarter/android-oss.git

I know someone had the same problem but I just can't understand that answer/solution so it would be really helpful if someone can explain in easy words.

  • Hi @Lalit! Welcome to SO. "There was a lot of different answers" Please do link all the resources you came through while researching on your own, in the question itself. "I just can't understand that answer/solution" -> We need to know what you looked at before commenting :)
  • This is the single/ best solution I had found same as mine other didn't even had this problem so it is difficult to find an actual solution

标签: android google-play-services


【解决方案1】:

Bootstrap is a set of initial files required to build the project. Since you miss the "bootstrap" you get the error.

make bootstrap refers to a command that will build the needed files for you.

GNU Make is a tool which controls the generation of executables and other non-source files of a program from the program's source files.

and bootstrap is a step in the project's Makefile that controls building the files for you. make bootstrap command basically asks the make software to run the bootstrap step from the Makefile.

From the issue thread it seems you can't do it directly from Windows. You need WSL which is just linux bash for windows.

Once you install WSL, install make and ruby. Run these commands one by one:

sudo apt update
sudo apt install ruby-full make

This should add ruby and make.

Then clone the kickstart project again (through WSL this time). cd into it (again through WSL) and run make bootstrap.

It will take a moment, once the bootstraps are built you can proceed to run AndroidStudio as usual.

That's what the issue thread on GitHub explains. I hope this made it simpler for you!

  • " Make bootstrap "do I just use this command like this ? And cd into it what does that mean ? (I am completely new in all this )
  • And I had to run all these ( Ruby , make and other ) commands in WSL ? - BTW THANK YOU SOOOO MUCH YOU MAKE IT A LOT LOT LOT EASIER I am REALLY GREATFUL OF YOU
  • WSL is like cmd, when you install it you get a window where you can run commands. After you install ruby and make, you can cd into the folder (cd means change directory, basically move into the folder where the project is) where you cloned the project. And type make bootstrap in the window and press enter. It will do the thing for you. Once done you can close wsl and open project in Android Studio. I did that and the app builds fine for me.
  • yes, install ruby and make in WSL, also run the make bootstrap in WSL. Rest all things are in normal Android Studio.
  • For cd can I just right click on the project folder (where I cloned it) and open wsl command because I know no other way of cd or if there are other can u tell ?
猜你喜欢
  • 2019-11-24
  • 2022-12-26
  • 2022-12-16
  • 2022-12-27
  • 2022-12-28
  • 2022-11-09
  • 2022-12-02
  • 2022-12-02
  • 2022-12-01
相关资源
最近更新 更多