C/C++ compilation error - Asus Transformer TF700

Got below error message when trying to compile C++ helloworld program
[email protected]:~/Documents/c++program$ g++ helloworld.cpp -o hello
In file included from /usr/include/c++/4.7/arm-linux-gnueabihf/./bits/os_defines.h:40:0,
from /usr/include/c++/4.7/arm-linux-gnueabihf/./bits/c++config.h:414,
from /usr/include/c++/4.7/iostream:39,
from helloworld.cpp:1:
/usr/include/features.h:357:25: fatal error: sys/cdefs.h: No such file or directory
compilation terminated.
I tried updating my g++ compiler but no lock
sudo apt-get install g++
Anybody worked this issue before? Appreciate your guidance...

Try reinstalling libc6.
sudo apt-get install --reinstall libc6-dev
Sent from whatever device I happened to pick up.

Clegs said:
Try reinstalling libc6.
sudo apt-get install --reinstall libc6-dev
Sent from whatever device I happened to pick up.
Click to expand...
Click to collapse
I believe build-essential is available so if you're still having trouble try:
Code:
sudo apt-get install build-essential
That should pull in all you generally need to get going.

Related

[GUIDE] how to setup AOSP build envirnoment and download source

Here is a quick guide on how to set up aosp build envirnoment and download the source, there are video's below the guide
This guide is for Ubuntu, Xubuntu, Kubuntu and Lubuntu.
Setting up Build envirnoment
You will need python, git, java jdk, build packages
Python: (chekking version)
Code:
python --version
Git:
Code:
sudo apt-get install git-core
Java jdk6:
Code:
sudo add-apt-repository "deb http://archive.canonical.com/ lucid partner"
sudo apt-get update
sudo apt-get install sun-java6-jdk
The build packages:
Code:
sudo apt-get install git-core gnupg flex bison gperf build-essential \
zip curl zlib1g-dev libc6-dev libncurses5-dev x11proto-core-dev \
libx11-dev libreadline6-dev libgl1-mesa-dev tofrodos python-markdown \
libxml2-utils
Downloading the source
Installing Repo:
Code:
mkdir ~/bin
PATH=~/bin:$PATH
curl https://dl-ssl.google.com/dl/googlesource/git-repo/repo > ~/bin/repo
chmod a+x ~/bin/repo
Installing repo client:
Code:
cd ~/Desktop
mkdir ics
cd ics
Code:
CM9:
repo init -u git://github.com/CyanogenMod/android.git -b ics
ICS:
repo init -u https://android.googlesource.com/platform/manifest -b android-4.0.1_r1
Downloading the source:
Code:
repo sync
Appreciate the work, but there are loads of guides like this, and this is the initial part that is already covered by android.com and wiki.cyanogenmod.com
Add something more, and it'ld be better
cdesai said:
Appreciate the work, but there are loads of guides like this, and this is the initial part that is already covered by android.com and wiki.cyanogenmod.com
Add something more, and it'ld be better
Click to expand...
Click to collapse
just wanted to share this here had some free time.
RafayelG said:
just wanted to share this here had some free time.
Click to expand...
Click to collapse
Then start getting more deep, as you are free!
cdesai said:
Then start getting more deep, as you are free!
Click to expand...
Click to collapse
ye but no phone atm and exams start next week made the video's yesterday evening.
RafayelG said:
ye but no phone atm and exams start next week made the video's yesterday evening.
Click to expand...
Click to collapse
Yea i know how it feels, the same here, best of luck for the exams

[HOWTO] Install Java 7 on Ubuntu 12.04

I'm not sure if this is in the right spot (if not I apologize), but I figure it is because this relates directly to building Android.
When I upgraded to Ubuntu 12.04, all the sudden I couldn't install Java (sha256sum mismatch jdk-7u3-linux-x64.tar.gz), which means I can't do much deving. Well I searched through the interweb and finally found a solution.
First:
Code:
sudo add-apt-repository ppa:eugenesan/java
sudo apt-get update
sudo apt-get install oracle-java7-installer
By now, you have probably gotten an error and the terminal has stated that Java was not installed. No problem.
Second:
Download Java directly from Oracle: http://www.oracle.com/technetwork/java/javase/downloads/jdk-7u3-download-1501626.html
Now, move what you just downloaded to /var/cache/oracle-java7-installer/
Third:
Code:
sudo gedit /var/lib/dpkg/info/oracle-java7-installer.postinst
Now scroll down and find the following:
Code:
echo "Downloading..."
rm -f $FILENAME
WGETRC=wgetrc wget $PARTNER_URL \
|| fp_exit_with_error "download failed"
rm -f wgetrc
echo "Download done."
Now put a # next to each line between "Downloading..." and "Downloading done."
Code:
echo "Downloading..."
#rm -f $FILENAME
#WGETRC=wgetrc wget $PARTNER_URL \
#|| fp_exit_with_error "download failed"
#rm -f wgetrc
echo "Download done."
Save, and go back to your terminal.
Finally, do:
Code:
sudo apt-get install oracle-java7-installer
Java should now install properly.
Source:
http://www.ubuntugeek.com/how-to-install-oracle-java-7-in-ubuntu-12-04.html (most helpful info is in the comments)
Make long story short, it didn't execute commands as root? Shame on Java!
Is it working on other distroes debian based like Mint?
umb3rts said:
Make long story short, it didn't execute commands as root? Shame on Java!
Is it working on other distroes debian based like Mint?
Click to expand...
Click to collapse
Haven't tried on any other distros.
Sent from my ADR6400L using xda premium
AFAIK you need java 6 installed to build android. Not to mention Ubuntu 12.04 is still in the final stages of beta lol.
Well for what I do java 7 is fine with me
Sent from my ADR6400L using xda premium
THANK YOU SO MUCH. took me a good 2 hours to find this guide. Now I can finally install curl. wtff..
So this is for 64-bit right? That's what I'm using
sparksco said:
So this is for 64-bit right? That's what I'm using
Click to expand...
Click to collapse
I guess. I'm running 64 and it works.
Sent from my Galaxy Nexus using xda premium
Installing java on Ubuntu 12.04
This is what work for me for installing java in Ubuntu 12.04
sudo rm /var/lib/dpkg/info/oracle-java7-installer*
sudo apt-get purge oracle-java7-installer*
sudo rm /etc/apt/sources.list.d/*java*
sudo apt-get update
sudo add-apt-repository ppa:webupd8team/java
sudo apt-get update
sudo apt-get install oracle-java7-installer
http://askubuntu.com/questions/1263...-x64-tar-gz-error-when-trying-to-install-orac

[How To] Setup ABE For Compiling Android Roms From Source (CM11) UPDATED 11/1/14

Setup ABE (Android Build Environment To Compile Roms) ​
For this you tutorial you need to be running Ubuntu 13.10 64-Bit (32-Bit Will Not Work).
Does Not Matter if you are running this in a virtual machine or not. (Will work on Both)
Also I will also be showing a Guide to Syncing CM11 Repo and TamsuiCM11 Repo.
Instructions (Read Carefully):
First, let's set up the correct JDK.
Many of you probably have some kind of wrong Java installed unless you're starting with a fresh Ubuntu base, and even then maybe.
Let's get rid of that. Copy and paste this into a Terminal window:
Code:
sudo apt-get purge openjdk-\* icedtea-\* icedtea6-\*
Follow the instructions to remove OpenJDK. If you must keep it, it's possible. But I'm not going to tell you how to do it here. I don't want any chance of confusion or mistake.
Now copy and paste the following into the Terminal:
Code:
sudo add-apt-repository ppa:webupd8team/java
This will add the correct PPA to your system for updated builds of Java 6 JDK that are compatible with 13.10. No more unrecognized Java version errors! And it will update automatically with the rest of your system.
Next, we actually need to install the package. More copy-paste:
Code:
sudo apt-get update && sudo apt-get install oracle-java6-installer
Ok, back to a fresh Terminal prompt. Time for installing the guts to build stuff in Ubuntu:
Code:
sudo apt-get install git-core lzop ccache gnupg flex bison gperf build-essential zip curl zlib1g-dev zlib1g-dev:i386 libc6-dev lib32ncurses5 lib32z1 lib32bz2-1.0 lib32ncurses5-dev x11proto-core-dev libx11-dev:i386 libreadline6-dev:i386 lib32z-dev libgl1-mesa-glx:i386 libgl1-mesa-dev g++-multilib mingw32 tofrodos python-markdown libxml2-utils xsltproc readline-common libreadline6-dev libreadline6 lib32readline-gplv2-dev libncurses5-dev lib32readline5 lib32readline6 libreadline-dev libreadline6-dev:i386 libreadline6:i386 bzip2 libbz2-dev libbz2-1.0 libghc-bzlib-dev lib32bz2-dev libsdl1.2-dev libesd0-dev squashfs-tools pngcrush schedtool libwxgtk2.8-dev python gcc g++ cpp gcc-4.8 g++-4.8
When that is done installing, run the following command in your Terminal window:
Code:
sudo ln -s /usr/lib/i386-linux-gnu/mesa/libGL.so.1 /usr/lib/i386-linux-gnu/libGL.so
That's it on the package side of things.
You guessed it, time for more Terminal. This really is the easiest way, seriously. And it's totally worth it when you're basking in the glory of a bunch of people on XDA.
The binary for a program called "repo" will let you talk to git servers and download all that precious source code. That second part after the && allows it to be executable:
Code:
mkdir ~/bin && curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo && chmod a+x ~/bin/repo
Use your favorite text editor to open ~/.bashrc
I like nano:
Code:
sudo nano ~/.bashrc
At the very bottom, add the following line:
Code:
export PATH=~/bin:$PATH
Save it. In nano that would be Ctrl-O and then Enter. Then Ctrl-X to exit back to a prompt. Restart bash:
Code:
source ~/.bashrc
In the terminal, navigate to where you would like to store the Android source code. The directions below will make it in your home folder, but if you have limited space, you may want to create it somewhere else. Faster is better, i.e. SSD would be best, USB external is basically unusable. Here we go:
Code:
mkdir ~/cm11
cd ~/cm11
We will configure your information, your name and email address, In terminal type:
Code:
git config --global user.name your name
git config --global user.email your email
Now you're going to initialize the repo. Here's where you decide the flavor of Android you want to build for, ie AOKP, CyanogenMod, AOSP etc. The following, for the purposes of this tutorial, will initialize for Stable CM11:
Code:
repo init -u git://github.com/CyanogenMod/android.git -b stable/cm-11.0
Almost there. Last step, but it's a doozy. You're going to get the source. Prepare yourself, mere mortal. 10+ GB of downloading await you. Don't worry, it's automated. Go to sleep. Eat something. Perhaps you have heard of this new thing the kids are doing called "going outside"? Yeah, I didn't think so. Me neither. The final terminal command, to be run from your android directory:
Code:
repo sync
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
After that is done its time to Sync TamsuiCM11 Repo:
Go into your file browser and to your username then your cm11 folder, once there press Ctrl+H on your keyboard. Go into the folder .repo and make a folder called:
Code:
local_manifests
Once done exit out of the repo folder and press Ctrl+H on your keyboard once again.
Now its time you configure the local manifest, this will download all necessary files for the devices in this forum.
Type this in terminal:
Code:
. build/envsetup.sh
[B]breakfast jlo[/B] (For Xperia J) [B]tapioca[/B] (For Xperia Tipo) [B]mesona[/B] (For Xperia Miro) [B]nanhu_ds[/B] (For Xperia E)
gedit ~/cm11/.repo/local_manifests/local_manifest.xml
Now go to this link: https://github.com/TamsuiCM11/local_manifest/blob/master/tamsui.xml
Copy everything in the file into the open window of gedit hit save and close.
Go back to Terminal and type:
Code:
repo sync
This will download all necessary files, once done type the following into terminal:
Code:
cd ~/cm11/vendor/cm
. get-prebuilts
croot
Finally type:
Code:
[B]brunch jlo[/B] (For Xperia J) [B]tapioca[/B] (For Xperia Tipo) [B]mesona[/B] (For Xperia Miro) [B]nanhu_ds[/B] (For Xperia E
It will begin to build, if you run into any errors, do some research before creating tons of threads.
THANK ME IF I HELPED!
Thanks a lot for the how to. I'm just "syncing" (don't know if this is how it is said, just entered the command that downloads 10Gb) and it is doing the job! Don't know why this has only 5 "thanks", I found it very useful!!
JUST ONE QUESTION!! If I type breakfast tapioca it gives me "no such file or directory" error. If I type "tapioca_ss" it gives me no problems. Is it right?
Thanks
phn1993 said:
Thanks a lot for the how to. I'm just "syncing" (don't know if this is how it is said, just entered the command that downloads 10Gb) and it is doing the job! Don't know why this has only 5 "thanks", I found it very useful!!
JUST ONE QUESTION!! If I type breakfast tapioca it gives me "no such file or directory" error. If I type "tapioca_ss" it gives me no problems. Is it right?
Thanks
Click to expand...
Click to collapse
In your home folder, look in cm11/devices. If there's a folder called tapioca_ss, then you need to use tapioca_ss. If there's a folder called tapioca, then you need to use tapioca.
Yes, this guide is very useful, but unfortunately, you can only thank a post once (I did)!
NSDCars5 said:
In your home folder, look in cm11/devices. If there's a folder called tapioca_ss, then you need to use tapioca_ss. If there's a folder called tapioca, then you need to use tapioca.
Yes, this guide is very useful, but unfortunately, you can only thank a post once (I did)!
Click to expand...
Click to collapse
Yes, I noticed!! Thanks!!
One last question (new it's true lol): I get "make" errors (ERROR 1) when compiling audio drivers. I don't know why, but I'm trying to repeat the how to as root!
phn1993 said:
Yes, I noticed!! Thanks!!
One last question (new it's true lol): I get "make" errors (ERROR 1) when compiling audio drivers. I don't know why, but I'm trying to repeat the how to as root!
Click to expand...
Click to collapse
I don't think you should do this as root; I've seen some guides that say doing so might deter the building process.
And you're welcome.
NSDCars5 said:
I don't think you should do this as root; I've seen some guides that say doing so might deter the building process.
And you're welcome.
Click to expand...
Click to collapse
I finally decided to repeat all the guide! I think I've just found the problem!! Thanks again

[How to][Build ZOMBI ][ TF700T ][ UBUNTU BASED 64bit]

This will guide you thought the setup of Mint. The setup of your build environment, and finely the output of a flashable CMB ROM for your 700
First anything that starts with a bullet point is just for your reference.. Do not copy these things into your bash window...
Anything that is a code is copied one line at a time into your bash window and than enter
Now Install Mint 64 bit and a PC.. We will need at least a 250 GB hard drive...
This is a work in progress so let me know if anyone has any questions...
Make sure unless it says to that you run all these commands in the home folder....
You can Find Mint here Click Me
Update System
Code:
sudo apt-get update
Code:
sudo apt-get upgrade
Build Env
Code:
sudo apt-get install git-core gnupg flex bison gperf libsdl1.2-dev libesd0-dev libwxgtk2.8-dev squashfs-tools build-essential zip curl
Code:
sudo apt-get install libncurses5-dev zlib1g-dev pngcrush schedtool libxml2 libxml2-utils xsltproc android-tools-fastboot android-tools-adb
Code:
sudo apt-get install g++-multilib lib32z1-dev lib32ncurses5-dev lib32readline-gplv2-dev gcc-multilib meld lzop ccache gedit
Code:
mkdir -p ~/bin
Code:
mkdir -p ~/android/system/zombi
Code:
curl http://commondatastorage.googleapis.com/git-repo-downloads/repo > ~/bin/repo
Code:
chmod a+x ~/bin/repo
Code:
export PATH=${PATH}:~/bin
Code:
gedit ~/.bashrc
Copy & Paste at bottom of bashrc on its own line
Code:
export PATH=${PATH}:~/bin
END-Paste
Code:
cd ~/android/system/zombi
Code:
repo init -u git://github.com/zombi-x/platform_manifest.git -b lp5.1
You will be prompt to give your email and name just follow the steps on screen
Then run the init command again
Code:
repo init -u git://github.com/zombi-x/platform_manifest.git -b lp5.1
Prepare to wait for a massive download 3 to 10 hours depending on your internet speed...
Code:
repo sync
OPEN JDK
Code:
sudo apt-get install openjdk-7-jdk
Ccache
Code:
gedit ~/.bashrc
Copy & Paste at bottom of bashrc on its own line
Code:
export USE_CCACHE=1
Code:
export CCACHE_DIR=~/ccache
END-Paste
Code:
source ~/.bashrc
Code:
ccache -M 50G
Building a ROM
Code:
cd ~/android/system/zombi
Make sure your in sync with the repo, you will do this every time right before you build.
Code:
repo sync
Code:
source build/envsetup.sh
Code:
lunch
Pick the number of the rom you would like to build
the -j* is how may cpu cores you would like to give to the build process
So -j2 would tell the build process that you have 2 core you would like to use to build
Code:
make clean && make bacon -j2
The flash-able zip will be in the out folder of your build directory
Code:
XDA:DevDB Information
How to build zombi for your TF700T, ROM for the Asus Transformer TF700
Contributors
lj50036, sbdags, hardslog
ROM OS Version: 5.1.x KitKat
Based On: OMNIROM
Version Information
Status: Beta
Beta Release Date: 2014-09-01
Created 2014-09-02
Last Updated 2014-09-08
GAPPS
This building of the ROM will only give you the base ROM .....
It will not have aroma, it will not have alot of stuff .....
You will need a gapps of some kind ......
MORE TO COME
Reserved
Thanks. Going with 32bit Mint on an old laptop... and 64bit in virtual machine on desktop
This post is gold
Thanks Josh, looking forward to building a rom myself later on when I am back home
Sent from my K00C using XDA Premium HD app
Hi Josh, I have just built my first rom using your instructions, I will test flash it tomorrow keeping all my fingers crossed
Thanks
Sent from my K00C using XDA Premium HD app
sbdags said:
This post is gold
Click to expand...
Click to collapse
yep, I have just installed my first build on to my old tf201, cheers lads
Sent from my K00C using XDA Premium HD app
If you use fedora, you need to downgrade the java packages:
sudo rpm -ivh http://www.nic.funet.fi/pub/Linux/I....7.0-openjdk-1.7.0.60-2.4.3.0.fc20.x86_64.rpm http://www.nic.funet.fi/pub/Linux/I...penjdk-devel-1.7.0.60-2.4.3.0.fc20.x86_64.rpm http://www.nic.funet.fi/pub/Linux/I...jdk-headless-1.7.0.60-2.4.3.0.fc20.x86_64.rpm --nodeps
Click to expand...
Click to collapse
and fix the old java to be used instead of the current one:
sudo alternatives --config java
sudo alternatives --config javac
Click to expand...
Click to collapse
and select the older java for the both.

[GUIDE][AOSP][WIP] Build android from source on windows 10

CURRENT STATUS: can compile android kernel successfully, right now cant compile complete rom.
Edition: Windows 10
Version: 1607
OS Build: 14393.222
===========================================
REQUIREMENTS
===========================================​
1) Windows 10 64-Bit with Anniversary Update
===========================================
Setting up ubuntu bash on windows 10
===========================================​
1) open the Settings --> Update & Security --> For Developers--> enable Developer Mode
2) search for “Turn Windows Features On or Off” in cortana & hit enter
3) Enable the “Windows Subsystem for Linux (Beta)” option in the list and click “OK.” & restart your system
4) search for “bash” in cortana & hit enter
5) type "y" & hit enter
6) download of ubuntu for windows 10 will start. It will take some time depending on your internet speed. You’ll be asked to create a user account and password for use in the Bash environment. restart your system
7) search for “Bash on Ubuntu on Windows” in cortana & hit enter
8) congratulations you have successfully installed bash on windows 10
9) OPTIONAL
add bash to context menu (developer is Manouchehri)
install this reg entry,... Accept the warnings and import it.
===========================================
Setting up a Linux build environment
===========================================​
1) open “Bash on Ubuntu on Windows”
Code:
sudo apt-get update
sudo apt-get upgrade
sudo apt-get install default-jdk
sudo apt-get install android-tools-adb android-tools-fastboot
Code:
sudo apt-get install git-core gnupg flex bison gperf build-essential \
zip curl zlib1g-dev gcc-multilib g++-multilib libc6-dev-i386 \
lib32ncurses5-dev x11proto-core-dev libx11-dev lib32z-dev ccache \
libgl1-mesa-dev libxml2-utils xsltproc unzip python-networkx
===========================================
How To's
===========================================​
warning 1: do not edit your linux files i.e. "C:\Users<username>\AppData\Local\lxss" in windows,... it will make the files useless in bash... never add files or edit files of linux subsystem from windows,....
Solution: copy the files out of linux sub system i.e. "lxss", edit them, then use bash to move the files back to "lxss"
---------------------------------------------------------------------
warning 2: Do not mnt and download android source,... download the source in linux subsystem (inside lxss) only...
---------------------------------------------------------------------
Problem: where are my ubuntu files
Solution: All your bash files are located in "C:\Users<username>\AppData\Local\lxss\rootfs". your home directory is located in "C:\Users<username>\AppData\Local\lxss\home"
---------------------------------------------------------------------
Problem: sudo: unable to resolve host
Solution: delete hosts file of ubuntu, it will auto generate the next time you open “Bash on Ubuntu on Windows" (C:\Users\<username>\AppData\Local\lxss\rootfs\etc\hosts)
---------------------------------------------------------------------
Problem: Java 8 doesn't install or work
Solution: know bug. use the following code. it will install java 7
Code:
sudo apt-get install default-jdk
---------------------------------------------------------------------
Problem: how to access windows files in bash
Solution: for example you want to navigate to downloads "C:\Users\<username>\Downloads"
Code:
cd /mnt/c/Users/<username>/Downloads
---------------------------------------------------------------------
Problem: repo not found or needs to be installed even after it was successful installed
Solution: use the following command
Code:
nano ~/.bashrc
add this at the end
Code:
PATH=~/bin:$PATH
press Ctrl+o & Ctrl+x
---------------------------------------------------------------------
Problem: can't mount my drive
Solution:: In order for a drive to show up under /mnt/ it must meet the following criteria:
1. The drive must be a fixed drive
2. The drive must be formatted to NTFS
---------------------------------------------------------------------
=======================================
*****still experimenting with bash, still have a few problems to successfully compile the rom,... will update if i find something
Move Home Ubuntu Directory
I can move ubuntu home directory from C to another drive?
@IacobIonut-DW
i am afraid you cant change it,.... there are duplicate files in ubuntu example lxss\text.txt & lxss Text.txt
if you try to copy the folder you will get a error message
It seems interesting I'm going to try it and will give you my feedback .
BTW , I've ubuntu installed along side with windows can I the files on ubuntu partition with the bash installed on windows ?
@LahKeda
No you can't read that drive
Nice to see that guide, great work!
But I am stuck at this point currently: stackoverflow | Bash on Ubuntu on Windows, Compile AOSP.
My strace file says about the same thing.
Did you find any solution to this?
@Spartaner25
did you try to edit files of linux or files of your build in windows???
Wow thanks!
But one question: Is it just another virtualization ? I mean is it faster than an Ubuntu installed inside a VM ?
For performance of bash on windows vs native Ubuntu read this
chiragkrishna said:
@Spartaner25
did you try to edit files of linux or files of your build in windows???
Click to expand...
Click to collapse
I did not touch any files of the linux base (lxss) in either the windows explorer or the bash and I did not modified anything inside the Windows Folder.
But I upgraded the system via apt update/upgrade which should not be destructive (I hope).
My target was a regular aosp build with the tag android-6.0.1_r58, I only changed a few linies in some files in frameworks/base via nano and added a device and kernel folder which was all done inside the bash.
Spartaner25 said:
I did not touch any files of the linux base (lxss) in either the windows explorer or the bash and I did not modified anything inside the Windows Folder.
But I upgraded the system via apt update/upgrade which should not be destructive (I hope).
My target was a regular aosp build with the tag android-6.0.1_r58, I only changed a few linies in some files in frameworks/base via nano and added a device and kernel folder which was all done inside the bash.
Click to expand...
Click to collapse
Try building only the kernel and see if it builds correctly!!
chiragkrishna said:
Try building only the kernel and see if it builds correctly!!
Click to expand...
Click to collapse
Thanks for the hint, the kernel builds fine.
By the way, building CyanogenMod gets stuck here for me.
Windows Insider Preview for those in Fast Ring
Ubuntu 16.04 Arrives With New Windows 10 Build 14936
change log
I'm currently on this version with ubuntu 16.04 and it's getting better.
Currently the build (aosp and cm) ist stuck on the bison binary which is a prebuilt 32-bit ELF, which can not be executed.
It might be possible to replace the prebuilts with their 64-bit variants.
@chiragkrishna upon using
Code:
sudo apt-get install git-core gnupg flex bison gperf build-essential \
zip curl zlib1g-dev gcc-multilib g++-multilib libc6-dev-i386 \
lib32ncurses5-dev x11proto-core-dev libx11-dev lib32z-dev ccache \
libgl1-mesa-dev libxml2-utils xsltproc unzip python-networkx
I get the following errors: Unable to locate package zip, lib32ncurses5-dev, libgl1-mesa-dev.
Edit: Fixed by removing the '\' from all lines.
does anyone know how to solve this error?
ionice: ioprio_set failed: Invalid argument
I have been able to successfully build cm-13.0 on Windows 10. I haven't been successful with cm-12.1, since it builds 32-bit binaries for the host executables for some reason.
The fixes I had to do:
Recompile flex and bison as 64-bit binaries according to the instructions in their source directory (github btongminh/android_prebuilts_misc)
Disable futexes in Art (github btongminh/android_art)
Disable v8 snapshots, since it is only possible to make snapshots for 32-bit targets on a 32-bit host (github btongminh/android_v8)
The build for Xiaomi Redmi 3 (ido) was successful, flashed it and it booted into Android Unfortunately after that the launcher kept on crashing, but is looks like I'm almost there.
Ayush1325 said:
does anyone know how to solve this error?
ionice: ioprio_set failed: Invalid argument
Click to expand...
Click to collapse
Build with "make bacon" instead of brunch or mka
btongminh said:
I have been able to successfully build cm-13.0 on Windows 10. I haven't been successful with cm-12.1, since it builds 32-bit binaries for the host executables for some reason.
Build with "make bacon" instead of brunch or mka
Click to expand...
Click to collapse
How do you make a user build signed with release keys instead of a userdebug build signed with testkeys??
EDIT: Well my normal make build failed
Please note I'm trying to compile Lineage OS 14.1
Code:
[ 1% 675/34224] Generating TOC: /root...core-all_intermediates/classes.jar.toc
FAILED: /bin/bash -c "(/root/out/host/linux-x86/bin/ijar /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc.tmp ) && (if cmp -s /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc.tmp /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc ; then rm /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc.tmp ; else mv /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc.tmp /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc ; fi )"
ftruncate(fd_out, GetSize()): Invalid argument
/bin/bash: line 1: 7115 Aborted (core dumped) ( /root/out/host/linux-x86/bin/ijar /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc.tmp )
ninja: build stopped: subcommand failed.
build/core/ninja.mk:151: recipe for target 'ninja_wrapper' failed
make: *** [ninja_wrapper] Error 1
#### make failed to build some targets (13:50 (mm:ss)) ####
It looks like I'm having the same error as this person. https://forum.xda-developers.com/lineage/help/building-lineageos-cancro-xiaomi-mi3w-t3530766
What Java version are you using (java -v). LineageOS 14.1 requires Java 1.8.
Link_of_Hyrule said:
Code:
[ 1% 675/34224] Generating TOC: /root...core-all_intermediates/classes.jar.toc
FAILED: /bin/bash -c "(/root/out/host/linux-x86/bin/ijar /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc.tmp ) && (if cmp -s /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc.tmp /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc ; then rm /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc.tmp ; else mv /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc.tmp /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc ; fi )"
ftruncate(fd_out, GetSize()): Invalid argument
/bin/bash: line 1: 7115 Aborted (core dumped) ( /root/out/host/linux-x86/bin/ijar /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar /root/out/target/common/obj/JAVA_LIBRARIES/core-all_intermediates/classes.jar.toc.tmp )
ninja: build stopped: subcommand failed.
build/core/ninja.mk:151: recipe for target 'ninja_wrapper' failed
make: *** [ninja_wrapper] Error 1
#### make failed to build some targets (13:50 (mm:ss)) ####
Click to expand...
Click to collapse
I've committed a fix to fix this problem, you can find it here:
https://github.com/imReker/bazel/commit/d2f16b573e0a77653454e64f124e0c4bab3b0fd7

Categories

Resources