[DEV] Solution to android.git.kernel.org being hacked - XPERIA X10 Android Development

For people who want to make AOSP ROMs and Not cyanogenMod based ROMs
I have a present for you
Till the android.git.kernel.org is down
I have found a alternative
I have edited the Original "Repo" File to allow flawless syncing of google's resources
They can be found
https://github.com/spaarc/tools_repo
simply use
curl https://github.com/spaarc/tools_repo/blob/master/repo > ~/bin/repo
OR
curl https://github.com/spaarc/tools_repo/repo > ~/bin/repo
and to set git INIT use this command
repo init -u https://github.com/android/platform_manifest.git -b gingerbread
That is about it
Happy Building

First!
And what?

Prodigy said:
First!
And what?
Click to expand...
Click to collapse
How old are you? Stop this first thing. It's getting annoying. Especially when that reply is pointless.
And just read and understand that text.
spaarc provides a solution to get AOSP sources. That's it.

i was so excited when i saw this!!
but its times out on the "repo init -u https://github.com/android/platform_manifest.git -b gingerbread"
looks like its still trying to go to kernel.org
any ideas?

this repo isnt working
i keep getting error at line 1

Related

[REF]HowTo build CM9 from source

Made the CM wiki a little easier to understand. Most is taken from here:
http://teamhacksung.org/wiki/index.php/CyanogenMod9:GT-I9100:How_to_build
First off you will need Ubuntu 64-bit for this to work (or one of the many ubuntu editions) I recommend the 11.10 version (will work on 10.x also), as it's the newest stable to date. 32-bit won't work. I'm using Xubuntu 64 bit, and it uses the same terminal codes of course.
Install ADB
Install the Android SDK.
NOTE: You do not need to setup the SDK with an ADV etc., just download and install to get the tools (e.g. adb).
Install the Build Packages
Open the terminal in ubuntu and paste the following code snippets:
To add sun-java to repo (works on various ubuntu versions):
Code:
sudo add-apt-repository ppa:ferramroberto/java
sudo apt-get update
To get the needed build packages:
Code:
sudo apt-get install git-core gnupg flex bison gperf libsdl1.2-dev libesd0-dev libwxgtk2.6-dev squashfs-tools build-essential zip curl libncurses5-dev zlib1g-dev sun-java6-jdk pngcrush schedtool g++-multilib lib32z1-dev lib32ncurses5-dev lib32readline5-dev gcc-4.3-multilib g++-4.3-multilib
NOTE: gcc-4.3-multilib g++-4.3-multilib is no longer available for Ubuntu 11.04/11.10 64-bit, but should still build without issue. On 11.10 lib32readline5-dev is no longer available, but lib32readline-gplv2-dev is there instead. Just install it with "apt-get install lib32readline-gplv2-dev"
Create the Directories
You will need to set up some directories in your build environment.
To create them paste these in terminal:
Code:
mkdir -p ~/bin
mkdir -p ~/android/system
Install the Repository
Enter the following in terminal to download make executable the "repo" binary:
Code:
curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo
chmod a+x ~/bin/repo
NOTE: You may need to reboot for these changes to take effect.
Now enter the following to initialize the repository:
Code:
cd ~/android/system/
repo init -u git://github.com/CyanogenMod/android.git -b ics
repo sync -j16
Retrieve the galaxys2 repo
Code:
. build/envsetup.sh
brunch cm_galaxys2-userdebug
Copy proprietary files
NOTE: This only needs to be done the first time you build, but it's recommended to redo it when TeamHacksung makes some changes to these in their nightlies (which may occur quite often as of now)..
You will need to have a galaxys2 with the latest nightly of CM9 installed, and ADB working on the computer. This script will copy the proprietary files from the device.
Connect the device to the computer and ensure that ADB is working properly.
Paste this into terminal:
Code:
cd ~/android/system/device/samsung/galaxys2/
./extract-files.sh
NOTE: If some hardware isn't working, like camcorder or FM radio, you will need to find the updated prop blobs.
Get prebuilts
Code:
~/android/system/vendor/cm/get-prebuilts
Building CyanogenMod
First, check for updates in the source:
Paste into terminal:
Code:
cd ~/android/system/
repo sync
Configure Build & Compile
Now, the environment must be configured to build and the ROM compiled, from code, for the galaxys2.
Paste into terminal:
Code:
. build/envsetup.sh && brunch cm_galaxys2-userdebug
--------------------
End of tutorial
--------------------
Nice guide, just installed ubuntu on my VAIO to do this kind of stuff.
Thnx
On to setting stuff up...
You should consider getting the build script (build.sh) from teamhacksung's github (https://github.com/teamhacksung/buildscripts) and placing it in your android/system folder.
It allows you to use commands like ./build.sh [devicename] [kernel] to build the version of CM7 you want and optionally will compile your own kernel (if you also have the c1 and aries kernel source)
Other commands it supports:
./build.sh clean - to clear the output folders for a clean build
./build.sh prepare - to pull the latest version of Rom Manager
When I build for the SGS2 my sequence of events are always:
repo sync -j16
./build.sh clean
then either:
./build.sh galaxys2 kernel
if kernel code has changed, or
./build.sh galaxys2
if kernel code has not changed.
Click to expand...
Click to collapse
And after the mentioned build sequence posted above to finalize everything you run the command "build/envsetup.sh && brunch galaxys2" or is that obsolete now ?
HarryRag said:
And after the mentioned build sequence posted above to finalize everything you run the command "build/envsetup.sh && brunch galaxys2" or is that obsolete now ?
Click to expand...
Click to collapse
run all those in terminal... Remember the .
Sent from my GT-I9100 using XDA Premium App
HarryRag said:
And after the mentioned build sequence posted above to finalize everything you run the command "build/envsetup.sh && brunch galaxys2" or is that obsolete now ?
Click to expand...
Click to collapse
If you use the teamhacksung build.sh script then, yes, it is obsolete.
Novek said:
Remember the .
Click to expand...
Click to collapse
Yes, don't forget the period (.) at the start of the ./build.sh command or it won't run.
I was indeed revering to the build.sh from teamhacksung, thnx.
Got another question, is about: repo sync -j16
What does the -j16 stand for?
I'm aware of the . from ./ , just using linux for the first time to do this kind of stuff, using it a few years now for game/web server and playing some around with it.
Novek said:
First of, this is a re-written guide from the cyanogenmod wiki found here. All credit goes to them!
Click to expand...
Click to collapse
the link you gave is for sgs1.
change it with this: http://wiki.cyanogenmod.com/wiki/Samsung_Galaxy_S_II:_Compile_CyanogenMod_(Linux)
HarryRag said:
Got another question, is about: repo sync -j16
What does the -j16 stand for?
Click to expand...
Click to collapse
To be honest, I don't know. I tried searching the man pages etc but could never find the answer. I use it because it is what is listed on the CM wiki. I have also seen people use -j40 or no setting. They all work.
NISIM2337 said:
the link you gave is for sgs1.
change it with this: http://wiki.cyanogenmod.com/wiki/Samsung_Galaxy_S_II:_Compile_CyanogenMod_(Linux)
Click to expand...
Click to collapse
Yes, the SGS2 wiki page was published today. It does not contain the teamhacksung buildscript details though as that is specific to teamhacksung.
Well just made to build my first Kang using ./build.sh galaxys2 kernel
Just for now i'm testing to see what the difference is with the other building options.
For doing the ADB install part i started with a Howtoforge page about setting up android app builds since it has a good and very detailed part on how to exactly do all the adb installing stuff etc. (which would stand for this part of the turorial *Install ADB*), very newby friendly
HarryRag said:
What does the -j16 stand for?
Click to expand...
Click to collapse
I think it's the number of the simultaneous connections that will be opened to the server.
Code:
echo "Example: ./build.sh galaxys2 (prebuilt kernel + android)"
echo "Example: ./build.sh galaxys2 kernel (kernel + android)"
As i understand the following from build.sh good. It means that with just the "./build.sh galaxys2" is for stock CM7 kernel as from the source/github after running the sync.
but is "./build.sh galaxys2 kernel (kernel + android)" then for an custom made kernel with tweaks or is this one just for when there is a (bigger) update for the CM7 kernel?
I think you should realse a rom based on cm.
Sent from my GT-I9100 using Tapatalk
Removed...
DvTonder said:
Yes, the SGS2 wiki page was published today. It does not contain the teamhacksung buildscript details though as that is specific to teamhacksung.
Click to expand...
Click to collapse
ok, sorry.
Don't remove anything, don't except defeat, everyone is equal here!
Sent from my Samsung Galactic iPhone Killing Machine S II
Novek said:
Removed due to public harrasment from the "pros"...
Click to expand...
Click to collapse
Wow, that is unexpected! And unfortunate! I was going to follow your extensive guide this evening, such a shame you took it away. I did not notice any harassment here, but i'm sorry you felt it. Hope maybe you and the "pros" can sort this out, because i think such a topic would be really valuable here!!!
mbroeders said:
Wow, that is unexpected! And unfortunate! I was going to follow your extensive guide this evening, such a shame you took it away. I did not notice any harassment here, but i'm sorry you felt it. Hope maybe you and the "pros" can sort this out, because i think such a topic would be really valuable here!!!
Click to expand...
Click to collapse
Agreed : this has great value
Sent from my GT-I9100 using XDA Premium App
Novek said:
Removed due to public harrasment from the "pros"...
Click to expand...
Click to collapse
Please, give us some names, we will know "pros" who don't like to share with others.
Some advanced devs just want to keep there secrets in order to make believe it's too hard for others ...
They would like us to re-invent everything when it exists already. Thats not my vision of linux freedom ...
Or please say us why they insult you ?
Sent from my GT-I9100 using XDA Premium App

Guide on how I build my own CM9 test builts

A follow up on this - http://forum.xda-developers.com/showpost.php?p=28177937&postcount=1768 - in the CM9 FXP thread, have I promised to make a little guide.
Guide how I build CM9 for my Mango.
For the first time you try to build CM9.
Create ~/bin and download repo to that directory. Afterwards set executable bit to make it possible to ”execute”.
Code:
mkdir -p ~/bin
curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo
chmod a+x ~/bin/repo
Now reboot the computer.
Create ~/android/system amd initialize the repository.
Code:
mkdir -p ~/android/system
cd ~/android/system/
repo init -u git://github.com/CyanogenMod/android.git -b ics
repo sync
Setup the environmental settings and initialize the Mango build.
Code:
. build/envsetup.sh
brunch mango
Setup the environmental settings and initialize the Mango build.
Code:
git clone git://github.com/TheMuppets/proprietary_vendor_semc.git -b ics ~/android/system/vendor/semc
cd ~/android/system/device/semc/mango/
./setup-makefiles.sh
Download the prebuilts
Code:
~/android/system/vendor/cm/get-prebuilts
Check for new changes
Code:
cd ~/android/system/
repo sync
Setup the environment again and build the ROM (takes long time)
Code:
. build/envsetup.sh
brunch mango
You will now find the build here (change DATE into the date).
~/android/system/out/target/product/mango/cm-9-DATE-UNOFFICIAL-mango.zip
The next times you try to build it, you only need to do the following.
Delete build.prop, if not will build.prop not get generated.
Code:
rm -f ~/android/system/out/target/product/mango/system/build.prop
Syncronise the git repositories.
Code:
cd ~/android/system/
repo sync
Setup the environmental settings.
Code:
. build/envsetup.sh
Configure/build.
Code:
brunch mango
You will now find the build here (change DATE into the date).
~/android/system/out/target/product/mango/cm-9-DATE-UNOFFICIAL-mango.zip
If you are trying to build it on a 32bit system, you should change line 374 in ~/android/system/device/semc/msm7x30-common/releasetools/common.py
from:
Code:
cmd = ["java", "-Xmx2048m", "-jar",
to:
Code:
cmd = ["java", "-Xmx1024m", "-jar",
If you get into any trouble, please let me know, I may have missed something.
EDIT (July 2. 2012): I have made a patch to msm7x30-common, so you do not need to edit the file (with this patch does it automatically check if you run on a 64bit or a 32bit system):
http://code.google.com/p/freexperia/issues/detail?id=527
EDIT (July 6. 2012): If there has been an update on git://github.com/koush/proprietary_vendor_semc.git (like there has been today), shall you do the following (pull the updates):
Code:
cd ~/android/system/vendor/semc
git pull
EDIT (July 8. 2012): Adding the following, just before "</manifest>" in ".repo/local_manifest.xml" and the proprietary files will also get updated, when you make a normal "repo sync". Got this idea after talking to Andreas (so thank you Andreas).
Code:
<project name="TheMuppets/proprietary_vendor_semc" path="vendor/semc" remote="github" revision="ics" />
EDIT (July 11. 2012): Changed the proprietary repository from git://github.com/koush/proprietary_vendor_semc.git to git://github.com/TheMuppets/proprietary_vendor_semc.git
allright, i have already synched the cm9 repo. about 5.8 gbs
can you tell me what folders does it include?
edit:took me a few days to download, just don't want to download again
gandhar said:
allright, i have already synched the cm9 repo. about 5.8 gbs
can you tell me what folders does it include?
Click to expand...
Click to collapse
Are you thinking of the "clean" repo?
My ~/android/system/ consists of the following (remember the hidden directories):
abi
android
bionic
bootable
build
dalvik
development
device
external
frameworks
hardware
kernel
libcore
ndk
out
packages
prebuilt
sdk
system
vendor
.repo
.repoconfig
Makefile
You should be able to move your current directory and "just" sync it, to get it up to date.
hnl_dk said:
Are you thinking of the "clean" repo?
My ~/android/system/ consists of the following (remember the hidden directories):
abi
android
bionic
bootable
build
dalvik
development
device
external
frameworks
hardware
kernel
libcore
ndk
out
packages
prebuilt
sdk
system
vendor
.repo
.repoconfig
Makefile
Click to expand...
Click to collapse
allright, out of these except for kernel, out and .repoconfig i have all the others synced.
will using
Code:
repo init -u git://github.com/CyanogenMod/android.git -b ics
repo sync
work?
i am missing kernel, out and .repoconfig
gandhar said:
allright, out of these except for kernel, out and .repoconfig i have all the others synced.
will using
Code:
repo init -u git://github.com/CyanogenMod/android.git -b ics
repo sync
work?
i am missing kernel, out and .repoconfig
Click to expand...
Click to collapse
They are possibly first created when running brunch the first time. So it should be fine.
successfully building, but getting loads of warnings..
is that normal for the first build?
will report if it boots after compile is over.
gandhar said:
successfully building, but getting loads of warnings..
is that normal for the first build?
will report if it boots after compile is over.
Click to expand...
Click to collapse
There are lots of warnings.
Personally I usually remove all that warnings (using the -Werror option, so warnings get treated as errors) in the projects I am working on. But I understand why it can be a big problem with CM9, that is based on many different projects.
Looking forward to hear if you get a successful built.
hnl_dk said:
There are lots of warnings.
Personally I usually remove all that warnings (using the -Werror option, so warnings get treated as errors) in the projects I am working on. But I understand why it can be a big problem with CM9, that is based on many different projects.
Looking forward to hear if you get a successful built.
Click to expand...
Click to collapse
building will take some time...
well, most warnings are 'some variable has been set but not used', is that much significant?
gandhar said:
building will take some time...
well, most warnings are 'some variable has been set but not used', is that much significant?
Click to expand...
Click to collapse
Yes, first build takes a lot of time... the next times it will be a lot faster.
No that is not very significant, but things like that should still get fixed, to to make it easier to find the significant things.
The less warnings the more easy it is to spot what is important. This also goes for things that should get changed when upgrading to a new major version of the toolchain.
succesfull build!
phone:coconut-wt19i
time: 56 mins for the complete build.
cpu: 2.9 ghz - 4 cores
os:ubuntu 12.04 64 bit
backed up the phone.
boots into recovery
errorless install.
gandhar said:
phone:coconut-wt19i
time: 56 mins for the complete build.
cpu: 2.9 ghz - 4 cores
os:ubuntu 12.04 64 bit
backed up the phone.
boots into recovery
errorless install.
Click to expand...
Click to collapse
Super, looking forward to hear if everything is going to run as as should
hnl_dk said:
Super, looking forward to hear if everything is going to run as as should
Click to expand...
Click to collapse
running fine.
but i see some dependencies missing from the libs needed from
http://wiki.cyanogenmod.com/wiki/Template:Build_from_source_(CM9)
downloading them, will build again later..
is that the reason for the warnings?
gandhar said:
running fine.
but i see some dependencies missing from the libs needed from
http://wiki.cyanogenmod.com/wiki/Template:Build_from_source_(CM9)
downloading them, will build again later..
is that the reason for the warnings?
Click to expand...
Click to collapse
looks like a nice guide that is working with most devices, will save that link
No, the warnings are simply that you rarely find "clean" code, where most warnings have been fixed.
You also need to think of all the code from external projects.
You also only get many of the warnings, if you do not compile the code for some specific platforms.
hnl_dk said:
looks like a nice guide that is working with most devices, will save that link
No, the warnings are simply that you rarely find "clean" code, where most warnings have been fixed.
You also need to think of all the code from external projects.
You also only get many of the warnings, if you do not compile the code for some specific platforms.
Click to expand...
Click to collapse
saw that guide after i started checking for dependencies.
1.hey i see two zips in the output,
one cm-9-20120702-UNOFFICIAL-coconut and other cm_coconut-ota-eng.gandhar
the second is bigger.
i used the first one. why is the second one built i wonder?
2.i think of compiling aosp from source too, but the out folder is 11.3 gbs, what about that?
i do not want to end up falling short on space.
3.this is a system related question, how much will it hinder performance if i move the source to a different internal hd from the main one and build from there?
gandhar said:
saw that guide after i started checking for dependencies.
1.hey i see two zips in the output,
one cm-9-20120702-UNOFFICIAL-coconut and other cm_coconut-ota-eng.gandhar
the second is bigger.
i used the first one. why is the second one built i wonder?
Click to expand...
Click to collapse
Try to read the name ;-)
OTA - Over The Air... I guess that it can mbe used tfor OTA updates, like the mobile companies makes.
gandhar said:
2.i think of compiling aosp from source too, but the out folder is 11.3 gbs, what about that?
i do not want to end up falling short on space.
Click to expand...
Click to collapse
You could do a "make clear", but if you have enough space, would I keep it, so you do not need to wait for the already up to date files.
gandhar said:
3.this is a system related question, how much will it hinder performance if i move the source to a different internal hd from the main one and build from there?
Click to expand...
Click to collapse
There will be no problem with performance, as long as you move it to a HDD that is not too slow.
EDIT (July 2. 2012): I have made a patch to msm7x30-common, so you do not need to edit the file (with this patch does it automatically check if you run on a 64bit or a 32bit system):
http://code.google.com/p/freexperia/issues/detail?id=527
i do a repo sync again, at end of it i get errors on changed files. i think its not replacing the old files.
it's red text
error: bootable/recovery/: CyanogenMod/android_bootable_recovery checkout f8fc12e741d566af215407f35cfc52e5c1cc0023
error: build/: CyanogenMod/android_build checkout df7d6893a59e62c15dd20e306d8280b16969097c
error: external/openssl/: CyanogenMod/android_external_openssl checkout d4004ae717232b83ea445f74c881d9ddc24f589d
error: frameworks/base/: CyanogenMod/android_frameworks_base checkout e0a8c35c1572f0f0dbbda4d871d0a919a79cbe3f
error: hardware/samsung/: CyanogenMod/android_hardware_samsung checkout 23280fc439163a1971956167217283c4ae70bce3
error: packages/apps/Camera/: CyanogenMod/android_packages_apps_Camera checkout 644384a979ec9bd6b237e9031d5afbf592d3056b
error: packages/apps/Settings/: CyanogenMod/android_packages_apps_Settings checkout a946d9a905d460fa9d6c153e031285b566f8d223
error: system/core/: CyanogenMod/android_system_core checkout 389a2fa1d7e4bb8b6be411f272de2e8c92817964
gandhar said:
i do a repo sync again, at end of it i get errors on changed files. i think its not replacing the old files.
it's red text
error: bootable/recovery/: CyanogenMod/android_bootable_recovery checkout f8fc12e741d566af215407f35cfc52e5c1cc0023
error: build/: CyanogenMod/android_build checkout df7d6893a59e62c15dd20e306d8280b16969097c
error: external/openssl/: CyanogenMod/android_external_openssl checkout d4004ae717232b83ea445f74c881d9ddc24f589d
error: frameworks/base/: CyanogenMod/android_frameworks_base checkout e0a8c35c1572f0f0dbbda4d871d0a919a79cbe3f
error: hardware/samsung/: CyanogenMod/android_hardware_samsung checkout 23280fc439163a1971956167217283c4ae70bce3
error: packages/apps/Camera/: CyanogenMod/android_packages_apps_Camera checkout 644384a979ec9bd6b237e9031d5afbf592d3056b
error: packages/apps/Settings/: CyanogenMod/android_packages_apps_Settings checkout a946d9a905d460fa9d6c153e031285b566f8d223
error: system/core/: CyanogenMod/android_system_core checkout 389a2fa1d7e4bb8b6be411f272de2e8c92817964
Click to expand...
Click to collapse
Have not tried that.
You can try to do a "repo forall -c git reset --hard" this "resets" all the repositories (removes all changes, also if something has been corrupted).
hnl_dk said:
Have not tried that.
You can try to do a "repo forall -c git reset --hard" this "resets" all the repositories.
Click to expand...
Click to collapse
will it redownload?

Guide on how I build my own CM10 test builts

This is a follow up on my "old" "Guide on how I build my own CM9 test builts" thread.
Guide how I build CM10 for my Mango.
For the first time you try to build CM10.
Create ~/bin and download repo to that directory. Afterwards set executable bit to make it possible to ”execute”.
Code:
mkdir -p ~/bin
curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo
chmod a+x ~/bin/repo
Now reboot the computer.
Create ~/android/system and initialize the repository.
Code:
mkdir -p ~/android/system
cd ~/android/system/
repo init -u git://github.com/CyanogenMod/android.git -b jellybean
Unpack the attached local_manifest.xml.bz2 and place local_manifest.xml into ~/android/system/.repo
Synchronise towards the current git repositories.
Code:
repo sync
Setup the environmental settings and initialize the Mango build.
Code:
. build/envsetup.sh
breakfast mango
Initialize the Mango build.
Code:
cd ~/android/system/device/semc/mango/
./setup-makefiles.sh
Download the prebuilts
Code:
~/android/system/vendor/cm/get-prebuilts
Check for new changes
Code:
cd ~/android/system/
repo sync
Setup the environment again and build the ROM (takes long time)
Code:
. build/envsetup.sh
brunch mango
You will now find the build here (change DATE into the date).
~/android/system/out/target/product/mango/cm-10-DATE-UNOFFICIAL-mango.zip
The next times you try to build it, you only need to do the following.
Delete build.prop, if not will build.prop not get generated.
Code:
rm -f ~/android/system/out/target/product/mango/system/build.prop
Syncronise the git repositories.
Code:
cd ~/android/system/
repo sync
Setup the environmental settings.
Code:
. build/envsetup.sh
Configure/build.
Code:
brunch mango
You will now find the build here (change DATE into the date).
~/android/system/out/target/product/mango/cm-10-DATE-UNOFFICIAL-mango.zip
EDIT (August 14. 2012): If the boot.img is not booting, is it most likely due to the bootloader bug.
To make it "work", do the following (replace mango with your own device)
Code:
cd out/target/product/mango/
rm -f ./boot.img ./combinedroot.cpio ./combinedroot.fs ./ramdisk.img
cp ./root/logo.rle ./root/waste_of_space1
cp ./root/logo.rle ./root/waste_of_space2
cp ./combinedroot/logo.rle ./combinedroot/waste_of_space1
cp ./combinedroot/logo.rle ./combinedroot/waste_of_space2
cd ../../../..
brunch mango
just a technical: is it really necessary to reboot the computer after downloading the repo binary? and if so, why is that??
bokrug said:
just a technical: is it really necessary to reboot the computer after downloading the repo binary? and if so, why is that??
Click to expand...
Click to collapse
It is only necessary on some Linux distributions, where you will not be able to execute anything from that directory, before a reboot. You can try to see if you can do it without. If it is working, do you not need it.
hnl_dk said:
It is only necessary on some Linux distributions, where you will not be able to execute anything from that directory, before a reboot. You can try to see if you can do it without. If it is working, do you not need it.
Click to expand...
Click to collapse
There's no really need to reboot - edit .bashrc in your home directory and add
Code:
export PATH=~/bin/:$PATH
Save, then run:
Code:
source ~/.bashrc
It have to work on all distros
pikpok said:
There's no really need to reboot - edit .bashrc in your home directory and add
Code:
export PATH=~/bin/:$PATH
Save, then run:
Code:
source ~/.bashrc
It have to work on all distros
Click to expand...
Click to collapse
I just want to show the "universal" way.
Not everyone is using bash
hnl_dk said:
I just want to show the "universal" way.
Not everyone is using bash
Click to expand...
Click to collapse
If someone use another shell, e.g. zsh, then he'll know what files he have to edit IMO rebooting is wasting time.
pikpok said:
If someone use another shell, e.g. zsh, then he'll know what files he have to edit IMO rebooting is wasting time.
Click to expand...
Click to collapse
no it is not, as you do not need to edit any files. It will work automatically.
It is as much a waste of time to edit the resource-definition scripts.
hnl_dk said:
no it is not, as you do not need to edit any files. It will work automatically.
It is as much a waste of time to edit the resource-definition scripts.
Click to expand...
Click to collapse
Reboot - about 1 min
Edit one file and paste single command in terminal - for me it's 10secs
But it comes to offtop discussion, so it would be better to end it now
@edit - now when I think about it... bin in home folder won't be added to PATH automatically, at least in Arch Linux. Maybe Ubuntu is more "intelligent" :laugh:
pikpok said:
Reboot - about 1 min
Edit one file and paste single command in terminal - for me it's 10secs
But it comes to offtop discussion, so it would be better to end it now
@edit - now when I think about it... bin in home folder won't be added to PATH automatically, at least in Arch Linux. Maybe Ubuntu is more "intelligent" :laugh:
Click to expand...
Click to collapse
It does not take that long for me to make a reboot
No matter what, is it always good to have more methods to make something work.
It did the last time I tried Arch Linux... and no I am not using Ubuntu (too flashy for me )
Assuming that there is an entry in your ~/.profile that adds ~/bin to PATH, a reboot won't do anything that logout/login wouldn't. Furthermore, logout/login (in this case) won't do anything that sourcing ~/.profile wouldn't. So, simply issuing "source ~/.profile" is sufficient on most distributions. If you are using a distribution or a shell that doesn't do this by default, then you probably already know what you need to do.
I do, however, commend hnl_dk's efforts to make things simpler for newcomers to Android and Linux, even if it's not the the "fastest" or the "best" way. Whenever you start getting into one of those "what if?" arguments, things tend to spiral out of control. Sometimes it's better to just make a few assumptions and go with what is most likely to work.
A reboot might be a bit of an overkill, though. :laugh:
Can't run 64-bit prebuilts on my 32-bit Linux
I have a 32-bit Linux box so get the errors:
/bin/bash: prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.6/bin/arm-linux-androideabi-gcc: cannot execute binary file
Had a quick look around, but are there gcc etc. prebuilts for 32-bit Linux boxes?
TIA,
AK-A
ak-a said:
I have a 32-bit Linux box so get the errors:
/bin/bash: prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.6/bin/arm-linux-androideabi-gcc: cannot execute binary file
Had a quick look around, but are there gcc etc. prebuilts for 32-bit Linux boxes?
TIA,
AK-A
Click to expand...
Click to collapse
Did you try to build it as described?
It is working fine on my 32bit debian machine.
If not, please describe hos you try it build it.
hnl_dk said:
Did you try to build it as described?
It is working fine on my 32bit debian machine.
If not, please describe hos you try it build it.
Click to expand...
Click to collapse
Yeah, followed the instructions as per the first post. Will re-try and see if I missed/messed something and report back.
Hey !!! Do you think I should post my AOSP errors in this thread...so that its easier for us to keep track..?? :highfive:
As this is a Tutorial Thread for "how to build cm10 on your own" I don't think it makes sense posting errormessages of errm. "android open source project"? As I am writing this I recognize that I do not really understand what you mean.
CosmoDroid said:
Hey !!! Do you think I should post my AOSP errors in this thread...so that its easier for us to keep track..?? :highfive:
Click to expand...
Click to collapse
Like Snoopo is saying, should that be in this thread. Compiling AOSP is not as "user friendly" as CM, as our devices are officially supported by CM and not AOSP.
If you want, can you make a new thread about compiling "AOSP - Jelly bean".
i always stop at "repo sync"
i always stop at "repo sync"
and it always tell me
"Fetching projects: 21% (66/313) fatal: unable to connect to github.com:
github.com[0: 207.97.227.239]: errno=??????"
can you help me
thanks
shufuking said:
i always stop at "repo sync"
and it always tell me
"Fetching projects: 21% (66/313) fatal: unable to connect to github.com:
github.com[0: 207.97.227.239]: errno=??????"
can you help me
thanks
Click to expand...
Click to collapse
Same also happens for me, then I try again and again and again and then it is working.
Lots of people are accessing github, and there is only a limited "whole" for the data to get through.
hnl_dk said:
Same also happens for me, then I try again and again and again and then it is working.
Lots of people are accessing github, and there is only a limited "whole" for the data to get through.
Click to expand...
Click to collapse
thanks for your suggestion
finally i make it.
another question.
when i perform " brunch smultron"
i got lots of "cannot execute binary file"
and final "make: *** [out/target/product/smultron/obj/lib/crtbegin_static.o] Error 126"
do you know what it means?
shufuking said:
thanks for your suggestion
finally i make it.
another question.
when i perform " brunch smultron"
i got lots of "cannot execute binary file"
and final "make: *** [out/target/product/smultron/obj/lib/crtbegin_static.o] Error 126"
do you know what it means?
Click to expand...
Click to collapse
without more details, my best guess is that you may be building it on a FAT32 or NTFS partition?
then there is a good chance that linux is not able to read the executable bits.

Resync CM sources for build error

Hey,
While there were no nightlies for SGS2 I thought I would give building myself a go. I managed to churn out my first build on the same day as CM started their nightlies, but I quite like the idea of making my own. No changes to it, it is just nice to have done it myself.
After the first build, I tried to resync the git repo. Following this guide, http://teamhacksung.org/wiki/index.php/CyanogenMod10:How_to_build, I did
Code:
cd ~/android/system && repo sync -j16
all set to ./build.sh i9100,
But the repo sync keeps failing. I get this error:
Code:
repo sync -j16
Fetching projects: 100% (309/309), done.
error: Cannot remove project "device/samsung/i9100": uncommitted changes are present
commit changes, then run sync again
[email protected]:~/android/system$ sudo repo sync -j16
sudo: repo: command not found
Before I had that error, I got a similar error, but with the device/galaxys2-common directory instead. In true "i'm not really sure what I'm doing" fashion I deleted that directory in the hope that would fix it. It did not.
Could someone let me know what im doing wrong/where I'm going wrong. On Ubunutu 12.04.
Thanks

Building AOSP using CM device files

Hello
I'm trying to build AOSP 6.0.1 using your CM device files (CM13 has been successfully built for my device, Huawei P8). I'm not too experienced with this so some help is appreciated. Right now I have synced the google repo
repo init -u https://android.googlesource.com/platform/manifest -b android-6.0.1_r80
cd .repo
git clone https://github.com/CM-Huawei-P8-Development/local_manifests_gra_l09
cd local_manifests_gra_l09
cd ../..
repo sync
This is where I'm now. The confusion is about am I supposed to also download or sync the device files from https://github.com/CM-Huawei-P8-Development/device_gra_l09 (the device tree)
Also is this https://github.com/CM-Huawei-P8-Development/kernel needed to be downloaded separately? I see in the hwgra-l09-dev.xml file that the repos are indeed listed but will it also work for AOSP?
I'm following a guide for Sony device and it says that next I'm supposed to
source build/envsetup.sh && lunch <--- here something device specific maybe?
and
make –j 8
What am I missing ?

Categories

Resources