need help compiling - Android

hey guys i really need some help, i am somewhat new too compiling a kernel from scratch and i keep running into some error's. any advice would be appreciated. btw i am compiling for a MIPS platform.
this is what im getting:
frameworks/base/tools/aidl/aidl_language_l.l:54: warning, rule cannot be matched
build/tools/merge-event-log-tags.py:29: DeprecationWarning: the md5 module is deprecated; use hashlib instead
import md5
touch out/host/linux-x86/obj/EXECUTABLES/aidl_intermediates/aidl_language_y.hpp
echo '#ifndef 'aidl_language_y_h > out/host/linux-x86/obj/EXECUTABLES/aidl_intermediates/aidl_language_y.h
Notice file: system/core/libzipfile/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/libzipfile.a.txt
Notice file: external/tinyxml/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/libtinyxml.a.txt
Notice file: external/zlib/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/libunz.a.txt
echo '#define 'aidl_language_y_h >> out/host/linux-x86/obj/EXECUTABLES/aidl_intermediates/aidl_language_y.h
cat out/host/linux-x86/obj/EXECUTABLES/aidl_intermediates/aidl_language_y.hpp >> out/host/linux-x86/obj/EXECUTABLES/aidl_intermediates/aidl_language_y.h
echo '#endif' >> out/host/linux-x86/obj/EXECUTABLES/aidl_intermediates/aidl_language_y.h
rm -f out/host/linux-x86/obj/EXECUTABLES/aidl_intermediates/aidl_language_y.hpp
Notice file: system/core/adb/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//bin/adb.txt
host Java: apkcheck (out/host/common/obj/JAVA_LIBRARIES/apkcheck_intermediates/classes)
Notice file: external/elfcopy/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/libelfcopy.a.txt
Notice file: external/bzip2/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/libbz.a.txt
host Java: cfassembler (out/host/common/obj/JAVA_LIBRARIES/cfassembler_intermediates/classes)
host Java: dexdeps (out/host/common/obj/JAVA_LIBRARIES/dexdeps_intermediates/classes)
target Generated: emulator <= external/qemu/qemu-options.hx
target Generated: emulator <= external/qemu/qemu-monitor.hx
target Generated: emulator <= external/qemu/gdb-xml/arm-core.xml
target Generated: emulator <= external/qemu/android/avd/hardware-properties.ini
Notice file: external/qemu/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//bin/emulator.txt
Notice file: external/qemu/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/emulator-memcheck.a.txt
Notice file: external/qemu/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/emulator-hw.a.txt
Notice file: external/qemu/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/emulator-mips.a.txt
Notice file: external/qemu/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/emulator-tcg.a.txt
Notice file: external/qemu/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/emulator-elff.a.txt
prebuilt/linux-x86/toolchain/mips-4.4.3/bin/mips-linux-gnu-gcc -fno-exceptions -Wno-multichar -Ulinux -U__unix -U__unix__ -fpic -ffunction-sections -funwind-tables -EL -march=mips32r2 -mtune=mips32r2 -mips32r2 -msoft-float -include system/core/include/arch/linux-mips/AndroidConfig.h -I system/core/include/arch/linux-mips/ -DANDROID -fmessage-length=0 -W -Wall -Wno-unused -Winit-self -Wpointer-arith -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -DNDEBUG -g -Wstrict-aliasing=2 -finline-functions -fno-inline-functions-called-once -fgcse-after-reload -frerun-cse-after-loop -frename-registers -DNDEBUG -UDEBUG -o out/target/product/generic/obj/lib/crtbegin_dynamic.o -c bionic/libc/arch-mips/bionic/crtbegin_dynamic.S
Notice file: bionic/libdl/NOTICE -- out/target/product/generic/obj/NOTICE_FILES/src//system/lib/libdl.so.txt
prebuilt/linux-x86/toolchain/mips-4.4.3/bin/mips-linux-gnu-gcc -fno-exceptions -Wno-multichar -Ulinux -U__unix -U__unix__ -fpic -ffunction-sections -funwind-tables -EL -march=mips32r2 -mtune=mips32r2 -mips32r2 -msoft-float -include system/core/include/arch/linux-mips/AndroidConfig.h -I system/core/include/arch/linux-mips/ -DANDROID -fmessage-length=0 -W -Wall -Wno-unused -Winit-self -Wpointer-arith -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -DNDEBUG -g -Wstrict-aliasing=2 -finline-functions -fno-inline-functions-called-once -fgcse-after-reload -frerun-cse-after-loop -frename-registers -DNDEBUG -UDEBUG -o out/target/product/generic/obj/lib/crtend_android.o -c bionic/libc/arch-mips/bionic/crtend.S
/home/zacwhite15/cruzmips/prebuilt/linux-x86/toolchain/mips-4.4.3/bin/../libexec/gcc/mips-linux-gnu/4.4.3/cc1: error while loading shared libraries: libgmp.so.3: cannot open shared object file: No such file or directory
/home/zacwhite15/cruzmips/prebuilt/linux-x86/toolchain/mips-4.4.3/bin/../libexec/gcc/mips-linux-gnu/4.4.3/cc1: error while loading shared libraries: libgmp.so.3: cannot open shared object file: No such file or directory
make: *** [out/target/product/generic/obj/lib/crtend_android.o] Error 1
make: *** Waiting for unfinished jobs....
make: *** [out/target/product/generic/obj/lib/crtbegin_dynamic.o] Error 1
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.

Related

Adb for Raspberry pi

Update: trevd has managed to make a proper adb 1.0.29 frm source. For those who wish to simply use the binary, you can download it here http://forum.xda-developers.com/attachment.php?attachmentid=1392336&d=1349930509
From trevd:
trevd said:
If anyone wants to hack on this I've setup an armv6 device tree on github to use the with AOSP source you can clone it to <aosp_sources>/device/generic/armv6 then do
Code:
lunch mini_armv6-userdebug && make -j4
......
Click to expand...
Click to collapse
more here http://forum.xda-developers.com/showpost.php?p=32632468&postcount=41
--- OLD ----
I'm trying to build ADB 1.0.28 or higher for the Raspberry Pi. I found a guide here: http://lackingrhoticity.blogspot.com/2010/02/how-to-build-adb-android-debugger.html but it's out of date since we can no longer access kernel.org directly. So, I'm trying to find a new way.
I spoke to Entropy512 and he suggested using the Cyanogenmod repository. So, here's what I have so far.
Code:
sudo apt-get install build-essential libncurses5-dev openjdk-7-jre openjdk-7-jdk bison
mkdir adb
cd adb
git clone git://github.com/CyanogenMod/android_system_core.git system/core
git clone git://github.com/CyanogenMod/android_build.git build
git clone git://github.com/CyanogenMod/android_external_zlib.git external/zlib
git clone git://github.com/CyanogenMod/android_bionic.git bionic
echo "include build/core/main.mk" >Makefile
I edited the adb/build/core/main.mk to reflect the version of JDK and JRE I have on my system. I'm not sure if they are even required at this point... Anyway, I modified the grep statements to find OpenJDK IcedTea instead of Oracle's version. Here's some snippits from the build/core/main.mk file.. make these match the values for your system's "java -version" and "javac -version"
build/core/main.mk
Code:
.
.
.
# Check for the correct version of java
java_version := $(shell java -version 2>&1 | head -n 1 | grep '[ "]1\.7[\. "$$]')
#Removed the next 3 lines
.
# Check for the correct version of javac
javac_version := $(shell javac -version 2>&1 | head -n 1 | grep '[ "]1\.7[\. "$$]')
So this puts me here:
Code:
[email protected] ~/adb $ make out/host/linux-x86/bin/adb
^[[A^[[B============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=4.0.4
TARGET_PRODUCT=full
TARGET_BUILD_VARIANT=eng
TARGET_BUILD_TYPE=release
TARGET_BUILD_APPS=
TARGET_ARCH=arm
TARGET_ARCH_VARIANT=armv7-a
HOST_ARCH=x86
HOST_OS=linux
HOST_BUILD_TYPE=release
BUILD_ID=IMM76L
============================================
build/core/tasks/kernel.mk:68: **********************************************************
build/core/tasks/kernel.mk:69: * Kernel source found, but no configuration was defined *
build/core/tasks/kernel.mk:70: * Please add the TARGET_KERNEL_CONFIG variable to your *
build/core/tasks/kernel.mk:71: * BoardConfig.mk file *
build/core/tasks/kernel.mk:72: **********************************************************
host C: adb <= system/core/adb/adb.c
cc1: error: unrecognized command line option ‘-m32’
make: *** [out/host/linux-x86/obj/EXECUTABLES/adb_intermediates/adb.o] Error 1
[email protected] ~/adb $
I'm still working on the rest. help would be appreciated. I can't get it to build on my desktop either. I really need help with this.
I found a build of Android4.0 for the Raspberry pi. I know that Android ICS and higher come with adb installed on the device for use with USB Host Mode on the device. So I yanked a copy and installed to an sdcard. Then I pulled the binary from /system/bin/adb. however when run it acts like it's not there even though it is.
Code:
[email protected] ~ $ sudo chmod 777 /usr/bin/adb
[email protected] ~ $ /usr/bin/adb
bash: /usr/bin/adb: No such file or directory
[email protected] ~ $ file /usr/bin/adb
/usr/bin/adb: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), stripped
[email protected] ~ $ readelf -d /usr/bin/adb
Dynamic section at offset 0x1708c contains 24 entries:
Tag Type Name/Value
0x00000003 (PLTGOT) 0x1f198
0x00000002 (PLTRELSZ) 768 (bytes)
0x00000017 (JMPREL) 0x9048
0x00000014 (PLTREL) REL
0x00000011 (REL) 0x9348
0x00000012 (RELSZ) 16 (bytes)
0x00000013 (RELENT) 8 (bytes)
0x00000015 (DEBUG) 0x0
0x00000006 (SYMTAB) 0x8488
0x0000000b (SYMENT) 16 (bytes)
0x00000005 (STRTAB) 0x8bd8
0x0000000a (STRSZ) 1135 (bytes)
0x00000004 (HASH) 0x8128
0x00000001 (NEEDED) Shared library: [libc.so]
0x00000001 (NEEDED) Shared library: [libstdc++.so]
0x00000001 (NEEDED) Shared library: [libm.so]
0x00000020 (PREINIT_ARRAY) 0x1f000
0x00000021 (PREINIT_ARRAYSZ) 0x8
0x00000019 (INIT_ARRAY) 0x1f008
0x0000001b (INIT_ARRAYSZ) 8 (bytes)
0x0000001a (FINI_ARRAY) 0x1f010
0x0000001c (FINI_ARRAYSZ) 8 (bytes)
0x0000001e (FLAGS)
0x00000000 (NULL) 0x0
I can see there are shared libraries required (libc.so, libstdc++.so and libm.so) , so I added those to /usr/lib/ chmod'd 777 and still nothing changed. What is required for a non-statically compiled binary to run? Did I install those libs properly? Why is that file saying it's not found?
I usually deal with hardware and java. these system binaries are like greek to me.
I find dynamic dependencies this way (sgh-i717 rild for instance):
Code:
[email protected]:~/build/vendor/samsung/quincyatt/proprietary/bin$ ~/arm-2009q3/bin/arm-none-linux-gnueabi-objdump -x rild | grep NEEDED
NEEDED liblog.so
NEEDED libcutils.so
NEEDED libril.so
NEEDED libdl.so
NEEDED libc.so
NEEDED libstdc++.so
NEEDED libm.so
EDIT: I just re-read about you finding NEEDED. At that point you have to do the same thing to each of those libraries, and find out what they depend on.
EDIT2: Do you have prebuilt/ ?
You can try compiling it statically, sync the AOSP master to get the latest code, then you'll have to edit system/core/*something*(probably adb)/Android.mk and tell it to link the target binary statically.
I'll link the exact file when on a pc.
Sent from my GT-P1000
cdesai said:
You can try compiling it statically, sync the AOSP master to get the latest code, then you'll have to edit system/core/*something*(probably adb)/Android.mk and tell it to link the target binary statically.
I'll link the exact file when on a pc.
Sent from my GT-P1000
Click to expand...
Click to collapse
Right:
Code:
LOCAL_FORCE_STATIC_EXECUTABLE := true
where host adb is defined in system/core/adb/Android.mk
That would be great! How do you compile statically for arm? I put in about 12 hours trying to do this today.
AdamOutler said:
That would be great! How do you compile statically for arm? I put in about 12 hours trying to do this today.
Click to expand...
Click to collapse
It was my assumption from the original link you posted that this was being built on the r-pi.
Without the prebuilts being part of the environment, linux-x86 directory would be the host gcc. In this case on r-pi debian, arm gcc.
Edit: From the original build you had a problem with -m32 not being a valid argument.
You could comment out lines 48 and 49 of: build/core/combo/HOST_linux-x86.mk
and see what happens.
irc?
AdamOutler said:
I put in about 12 hours trying to do this today.
Click to expand...
Click to collapse
Seems like your fighting a losing battle there, for that length of time you might as well have sync'd the full lot and done a full build to begin with, It really is the path of least resistance when It comes to android. Otherwise you end up chasing shadows as you get deeper into the build system.
What are you trying to achieve with this? do you want to connect to other devices from the RaspPi or is the Rasp meant to be on the receiving end?
because obviously you'll need to build the daemonized version if the Rasp is your target, that lives in /sbin/adbd normally on the device.
I had a quick look at that guide. Googles sources now live at android.googlesource.com which can be used instead of the old kernel.org address
i.e
Code:
[B]git clone git://android.git.kernel.org/platform/system/core.git system/core[/B]
becomes
Code:
[B]git clone https://android.googlesource.com/platform/system/core.git system/core[/B]
trevd said:
Seems like your fighting a losing battle there, for that length of time you might as well have sync'd the full lot and done a full build to begin with, It really is the path of least resistance when It comes to android. Otherwise you end up chasing shadows as you get deeper into the build system.
What are you trying to achieve with this? do you want to connect to other devices from the RaspPi or is the Rasp meant to be on the receiving end?
because obviously you'll need to build the daemonized version if the Rasp is your target, that lives in /sbin/adbd normally on the device.
I had a quick look at that guide. Googles sources now live at android.googlesource.com which can be used instead of the old kernel.org address
i.e
Code:
[B]git clone git://android.git.kernel.org/platform/system/core.git system/core[/B]
becomes
Code:
[B]git clone https://android.googlesource.com/platform/system/core.git system/core[/B]
Click to expand...
Click to collapse
Are you sure that will compile on ARM host? I don't want to spend 24 hours downloading and compiling on a 700 MHz processor. The resulting adb binary must run on an arm linux host.
AdamOutler said:
... Then I pulled the binary from /system/bin/adb. however when run it acts like it's not there even though it is.
Code:
[email protected] ~ $ /usr/bin/adb
bash: /usr/bin/adb: No such file or directory
Click to expand...
Click to collapse
Looks to me as you forgot to add your /usr/bin to your PATH variable (which also need to be exported to shell.)
Until you do that you need to use the source operator ".":
Code:
$ [B].[/B]/usr/bin/adb
E:V:A said:
Looks to me as you forgot to add your /usr/bin to your PATH variable (which also need to be exported to shell.)
Until you do that you need to use the source operator ".":
Code:
$ [B].[/B]/usr/bin/adb
Click to expand...
Click to collapse
good thinking.. but it didn't work.. cannot execute binary file.
Code:
[email protected] ~ $ export PATH=/usr/bin:$PATH
[email protected] ~ $ adb
bash: /usr/bin/adb: No such file or directory
[email protected] ~ $ /usr/bin/adb
bash: /usr/bin/adb: No such file or directory
[email protected] ~ $ . /usr/bin/adb
bash: .: /usr/bin/adb: cannot execute binary file
[email protected] ~ $
I have an older copy of ADB 1.0.26, but I need 1.0.28. What is the difference here aside from the shared objects which I've already put into /usr/lib.
Code:
[email protected] ~ $ file /usr/bin/adb #new version
/usr/bin/adb: setuid setgid ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), stripped
[email protected] ~ $ file /bin/adb #old version
/bin/adb: setuid setgid ELF 32-bit LSB executable, ARM, version 1 (SYSV), statically linked, for GNU/Linux 2.6.26, BuildID[sha1]=0x8ffd8c80a0705dc113149612e3067931208bfd70, not stripped
bhundven said:
It was my assumption from the original link you posted that this was being built on the r-pi.
Without the prebuilts being part of the environment, linux-x86 directory would be the host gcc. In this case on r-pi debian, arm gcc.
Edit: From the original build you had a problem with -m32 not being a valid argument.
You could comment out lines 48 and 49 of: build/core/combo/HOST_linux-x86.mk
and see what happens.
irc?
Click to expand...
Click to collapse
I did this. I got most of the way through compiling.
Code:
[email protected] ~/adb $ make out/host/linux-x86/bin/adb
============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=4.0.4
TARGET_PRODUCT=full
TARGET_BUILD_VARIANT=eng
TARGET_BUILD_TYPE=release
TARGET_BUILD_APPS=
TARGET_ARCH=arm
TARGET_ARCH_VARIANT=armv7-a
HOST_ARCH=x86
HOST_OS=linux
HOST_BUILD_TYPE=release
BUILD_ID=IMM76L
============================================
build/core/tasks/kernel.mk:68: **********************************************************
build/core/tasks/kernel.mk:69: * Kernel source found, but no configuration was defined *
build/core/tasks/kernel.mk:70: * Please add the TARGET_KERNEL_CONFIG variable to your *
build/core/tasks/kernel.mk:71: * BoardConfig.mk file *
build/core/tasks/kernel.mk:72: **********************************************************
host C: adb <= system/core/adb/adb.c
system/core/adb/adb.c: In function ‘connect_device’:
system/core/adb/adb.c:998:28: warning: comparison between signed and unsigned integer expressions [-Wsign-compare]
host C: adb <= system/core/adb/console.c
host C: adb <= system/core/adb/transport.c
host C: adb <= system/core/adb/transport_local.c
system/core/adb/transport_local.c: In function ‘local_init’:
system/core/adb/transport_local.c:321:8: warning: extra tokens at end of #endif directive [enabled by default]
host C: adb <= system/core/adb/transport_usb.c
host C: adb <= system/core/adb/commandline.c
host C: adb <= system/core/adb/adb_client.c
host C: adb <= system/core/adb/sockets.c
host C: adb <= system/core/adb/services.c
host C: adb <= system/core/adb/file_sync_client.c
host C: adb <= system/core/adb/get_my_path_linux.c
host C: adb <= system/core/adb/usb_linux.c
host C: adb <= system/core/adb/utils.c
host C: adb <= system/core/adb/usb_vendors.c
host C: adb <= system/core/adb/fdevent.c
host C: libzipfile <= system/core/libzipfile/centraldir.c
host C: libzipfile <= system/core/libzipfile/zipfile.c
host StaticLib: libzipfile (out/host/linux-x86/obj/STATIC_LIBRARIES/libzipfile_intermediates/libzipfile.a)
host C: libunz <= external/zlib/adler32.c
host C: libunz <= external/zlib/crc32.c
host C: libunz <= external/zlib/zutil.c
host C: libunz <= external/zlib/inflate.c
host C: libunz <= external/zlib/inftrees.c
host C: libunz <= external/zlib/inffast.c
host StaticLib: libunz (out/host/linux-x86/obj/STATIC_LIBRARIES/libunz_intermediates/libunz.a)
host C: liblog <= system/core/liblog/logd_write.c
system/core/liblog/logd_write.c: In function ‘__write_to_log_kernel’:
system/core/liblog/logd_write.c:90:9: warning: implicit declaration of function ‘fakeLogWritev’ [-Wimplicit-function-declaration]
system/core/liblog/logd_write.c: In function ‘__write_to_log_init’:
system/core/liblog/logd_write.c:103:9: warning: implicit declaration of function ‘fakeLogOpen’ [-Wimplicit-function-declaration]
system/core/liblog/logd_write.c:112:13: warning: implicit declaration of function ‘fakeLogClose’ [-Wimplicit-function-declaration]
host C: liblog <= system/core/liblog/logprint.c
host C: liblog <= system/core/liblog/event_tag_map.c
host C: liblog <= system/core/liblog/fake_log_device.c
host StaticLib: liblog (out/host/linux-x86/obj/STATIC_LIBRARIES/liblog_intermediates/liblog.a)
host C: libcutils <= system/core/libcutils/atomic.c
In file included from system/core/include/cutils/atomic-inline.h:47:0,
from system/core/libcutils/atomic.c:19:
system/core/include/cutils/atomic-arm.h:21:34: fatal error: machine/cpu-features.h: No such file or directory
compilation terminated.
make: *** [out/host/linux-x86/obj/STATIC_LIBRARIES/libcutils_intermediates/atomic.o] Error 1
[email protected] ~/adb $
Not sure what I need to do to fix system/core/libcutils/atomic.c Maybe I need to get the machine/ repo.
I was able to link some libraries around and ended up here..
Code:
[email protected] ~/adb $ make out/host/linux-x86/bin/adb
============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=4.0.4
TARGET_PRODUCT=full
TARGET_BUILD_VARIANT=eng
TARGET_BUILD_TYPE=release
TARGET_BUILD_APPS=
TARGET_ARCH=arm
TARGET_ARCH_VARIANT=armv7-a
HOST_ARCH=x86
HOST_OS=linux
HOST_BUILD_TYPE=release
BUILD_ID=IMM76L
============================================
build/core/tasks/kernel.mk:68: **********************************************************
build/core/tasks/kernel.mk:69: * Kernel source found, but no configuration was defined *
build/core/tasks/kernel.mk:70: * Please add the TARGET_KERNEL_CONFIG variable to your *
build/core/tasks/kernel.mk:71: * BoardConfig.mk file *
build/core/tasks/kernel.mk:72: **********************************************************
host C: libcutils <= system/core/libcutils/atomic.c
host C: libcutils <= system/core/libcutils/array.c
host C: libcutils <= system/core/libcutils/hashmap.c
host C: libcutils <= system/core/libcutils/native_handle.c
host C: libcutils <= system/core/libcutils/buffer.c
host C: libcutils <= system/core/libcutils/socket_inaddr_any_server.c
host C: libcutils <= system/core/libcutils/socket_local_client.c
host C: libcutils <= system/core/libcutils/socket_local_server.c
host C: libcutils <= system/core/libcutils/socket_loopback_client.c
host C: libcutils <= system/core/libcutils/socket_loopback_server.c
host C: libcutils <= system/core/libcutils/socket_network_client.c
host C: libcutils <= system/core/libcutils/sockets.c
host C: libcutils <= system/core/libcutils/config_utils.c
host C: libcutils <= system/core/libcutils/cpu_info.c
host C: libcutils <= system/core/libcutils/load_file.c
host C: libcutils <= system/core/libcutils/list.c
host C: libcutils <= system/core/libcutils/open_memstream.c
host C: libcutils <= system/core/libcutils/strdup16to8.c
host C: libcutils <= system/core/libcutils/strdup8to16.c
host C: libcutils <= system/core/libcutils/record_stream.c
host C: libcutils <= system/core/libcutils/process_name.c
host C: libcutils <= system/core/libcutils/properties.c
host C: libcutils <= system/core/libcutils/threads.c
host C: libcutils <= system/core/libcutils/sched_policy.c
host C: libcutils <= system/core/libcutils/iosched_policy.c
host C: libcutils <= system/core/libcutils/str_parms.c
host C: libcutils <= system/core/libcutils/abort_socket.c
host C: libcutils <= system/core/libcutils/mspace.c
host C: libcutils <= system/core/libcutils/selector.c
host C: libcutils <= system/core/libcutils/tztime.c
system/core/libcutils/tztime.c: In function ‘differ_by_repeat’:
system/core/libcutils/tztime.c:303:2: warning: comparison is always false due to limited range of data type [-Wtype-limits]
system/core/libcutils/tztime.c: In function ‘localsub’:
system/core/libcutils/tztime.c:1267:24: warning: assignment discards ‘const’ qualifier from pointer target type [enabled by default]
host C: libcutils <= system/core/libcutils/zygote.c
host C: libcutils <= system/core/libcutils/ashmem-host.c
host C: libcutils <= system/core/libcutils/tzstrftime.c
system/core/libcutils/tzstrftime.c: In function ‘_fmt’:
system/core/libcutils/tzstrftime.c:360:7: warning: implicit declaration of function ‘sprintf’ [-Wimplicit-function-declaration]
system/core/libcutils/tzstrftime.c:360:14: warning: incompatible implicit declaration of built-in function ‘sprintf’ [enabled by default]
system/core/libcutils/tzstrftime.c: In function ‘_conv’:
system/core/libcutils/tzstrftime.c:628:9: warning: incompatible implicit declaration of built-in function ‘sprintf’ [enabled by default]
host C: libcutils <= system/core/libcutils/dlmalloc_stubs.c
host StaticLib: libcutils (out/host/linux-x86/obj/STATIC_LIBRARIES/libcutils_intermediates/libcutils.a)
host Executable: adb (out/host/linux-x86/obj/EXECUTABLES/adb_intermediates/adb)
true
host C: acp <= build/tools/acp/acp.c
host C++: libhost <= build/libs/host/pseudolocalize.cpp
host C: libhost <= build/libs/host/CopyFile.c
host StaticLib: libhost (out/host/linux-x86/obj/STATIC_LIBRARIES/libhost_intermediates/libhost.a)
host Executable: acp (out/host/linux-x86/obj/EXECUTABLES/acp_intermediates/acp)
true
Install: out/host/linux-x86/bin/acp
Notice file: system/core/adb/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//bin/adb.txt
Notice file: system/core/libzipfile/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/libzipfile.a.txt
Notice file: system/core/liblog/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/liblog.a.txt
Notice file: system/core/libcutils/NOTICE -- out/host/linux-x86/obj/NOTICE_FILES/src//lib/libcutils.a.txt
target arm C: libc <= bionic/libc/bionic/pthread.c
target thumb C: libc <= bionic/libc/arch-arm/bionic/exidx_dynamic.c
target thumb C: libc <= bionic/libc/unistd/sysconf.c
target thumb C: libc <= bionic/libc/bionic/__errno.c
target thumb C: libc <= bionic/libc/bionic/dlmalloc.c
target thumb C: libc <= bionic/libc/bionic/malloc_debug_common.c
target thumb C: libc <= bionic/libc/bionic/libc_init_dynamic.c
target thumb C: libdl <= bionic/libdl/libdl.c
cc -mthumb-interwork -Ibionic/libc/private -DCRT_LEGACY_WORKAROUND -o out/target/product/generic/obj/lib/crtbegin_so.o -c bionic/libc/arch-arm/bionic/crtbegin_so.S
cc -mthumb-interwork -Ibionic/libc/private -DCRT_LEGACY_WORKAROUND -o out/target/product/generic/obj/lib/crtend_so.o -c bionic/libc/arch-arm/bionic/crtend_so.S
target SharedLib: libdl (out/target/product/generic/obj/SHARED_LIBRARIES/libdl_intermediates/LINKED/libdl.so)
/usr/bin/ld: unrecognized option '--icf=safe'
/usr/bin/ld: use the --help option for usage information
collect2: ld returned 1 exit status
make: *** [out/target/product/generic/obj/SHARED_LIBRARIES/libdl_intermediates/LINKED/libdl.so] Error 1
so I did a
Code:
[email protected] ~/adb $ grep -r 'icf=safe' ./*
./build/core/combo/TARGET_linux-arm.mk: -Wl,--icf=safe \
and I removed that icf parameter.
ok, so i've been hacking around on this quite a bit... I don't know how to work through this final linking part. here's a pastebin...
http://pastebin.com/pb8F7raB
how do i fix undefined references? I've been hacking it up by linking files where they should be linkd. I don't know how to fix this. Like I said before... I don't work at this level usually. I work on Java, shell, and hardware. C and middle-ware is not my thing.
AdamOutler said:
ok, so i've been hacking around on this quite a bit... I don't know how to work through this final linking part. here's a pastebin...
http://pastebin.com/pb8F7raB
how do i fix undefined references? I've been hacking it up by linking files where they should be linkd. I don't know how to fix this. Like I said before... I don't work at this level usually. I work on Java, shell, and hardware. C and middle-ware is not my thing.
Click to expand...
Click to collapse
Try adding:
Code:
--with-float=soft
to LOCAL_CFLAGS
EDIT: You might also need to add
Code:
-lgcc
to the LOCAL_LDFLAGS
bhundven said:
Try adding:
Code:
--with-float=soft
to LOCAL_CFLAGS
EDIT: You might also need to add
Code:
-lgcc
to the LOCAL_LDFLAGS
Click to expand...
Click to collapse
Thanks. I'm not sure where to add it though
Code:
[email protected] ~/adb $ grep -R LOCAL_CFLAGS ./*
./bionic/libc/Android.mk:LOCAL_CFLAGS := $(libc_common_cflags)
./bionic/libc/Android.mk:LOCAL_CFLAGS+= \
./bionic/libc/Android.mk:LOCAL_CFLAGS += -DCRT_LEGACY_WORKAROUND
./bionic/libc/Android.mk:LOCAL_CFLAGS := $(libc_common_cflags) \
./bionic/libc/Android.mk:LOCAL_CFLAGS := $(libc_common_cflags) \
./bionic/libc/Android.mk:LOCAL_CFLAGS := $(libc_common_cflags)
./bionic/libc/Android.mk:LOCAL_CFLAGS := \
./bionic/libc/Android.mk:LOCAL_CFLAGS := \
./bionic/libc/Jamfile: local LOCAL_CFLAGS LOCAL_DEFINES LOCAL_INCLUDES LOCAL_SRC NO_LOCAL_SRC ;
./bionic/libc/Jamfile: CFLAGS += $(LOCAL_CFLAGS) ;
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DVM_SPLIT_2G
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DPRELINK
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DLINKER_TEXT_BASE=$(LINKER_TEXT_BASE)
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DLINKER_AREA_SIZE=$(LINKER_AREA_SIZE)
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DLINKER_DEBUG=0
./bionic/linker/Android.mk: LOCAL_CFLAGS += -DHAVE_ARM_TLS_REGISTER
./bionic/linker/Android.mk: LOCAL_CFLAGS += -DHAVE_TEGRA_ERRATA_657451
./bionic/linker/Android.mk: LOCAL_CFLAGS += -DHAVE_TEGRA_ERRATA_657451
./bionic/linker/Android.mk:LOCAL_CFLAGS += -I$(LOCAL_PATH)/../libc/private
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DANDROID_ARM_LINKER
./bionic/linker/Android.mk: LOCAL_CFLAGS += -DANDROID_X86_LINKER
./bionic/linker/Android.mk: LOCAL_CFLAGS += -I$(LOCAL_PATH)/../libc/arch-x86/bionic
./bionic/linker/Android.mk: LOCAL_CFLAGS += -DANDROID_SH_LINKER
./bionic/linker/README.TXT: LOCAL_CFLAGS += -DLINKER_DEBUG=0
./bionic/linker/README.TXT: LOCAL_CFLAGS += -DLINKER_DEBUG=1
./bionic/libstdc++/Android.mk:LOCAL_CFLAGS := $(libstdc++_cflags)
./bionic/libstdc++/Android.mk:LOCAL_CFLAGS := $(libstdc++_cflags)
./build/tools/acp/Android.mk:LOCAL_CFLAGS += -DWIN32_EXE
./build/tools/acp/Android.mk:LOCAL_CFLAGS += -DMACOSX_RSRC
./build/tools/rgb2565/Android.mk:LOCAL_CFLAGS += -O2 -Wall -Wno-unused-parameter
./build/buildspec.mk.default:# will be added to LOCAL_CFLAGS when building the module.
./build/core/clear_vars.mk:LOCAL_CFLAGS:=
./build/core/build-system.html:LOCAL_CFLAGS += -DNDEBUG=1
./build/core/build-system.html:<h4>LOCAL_CFLAGS</h4>
./build/core/build-system.html:<p><code>LOCAL_CFLAGS += -DLIBUTILS_NATIVE=1</code></p>
./build/core/build-system.html:<code>LOCAL_CPPFLAGS</code> is guaranteed to be after <code>LOCAL_CFLAGS</code>
./build/core/build-system.html:<code>LOCAL_CFLAGS</code>.
./build/core/build-system.html:<code>LOCAL_C_INCLUDES</code>, <code>LOCAL_CFLAGS</code>, and
./build/core/native_test.mk:LOCAL_CFLAGS += -DGTEST_OS_LINUX -DGTEST_HAS_STD_STRING
./build/core/host_native_test.mk:LOCAL_CFLAGS += -DGTEST_OS_LINUX -DGTEST_HAS_STD_STRING -O0 -g
./build/core/binary.mk: LOCAL_CFLAGS += $(TARGET_FDO_CFLAGS)
./build/core/binary.mk:LOCAL_CFLAGS += -DGOOGLE_PROTOBUF_NO_RTTI
./build/core/binary.mk:$(LOCAL_INTERMEDIATE_TARGETS): PRIVATE_CFLAGS := $(LOCAL_CFLAGS)
./build/libs/host/Android.mk:LOCAL_CFLAGS += -DWIN32_EXE
./build/libs/host/Android.mk:LOCAL_CFLAGS += -DMACOSX_RSRC
./external/zlib/Android.mk:LOCAL_CFLAGS += -O3 -DUSE_MMAP $(zlib_arm_flags)
./external/zlib/Android.mk:LOCAL_CFLAGS += -O3 -DUSE_MMAP $(zlib_arm_flags)
./external/zlib/Android.mk:LOCAL_CFLAGS += -O3 -DUSE_MMAP
./system/core/libsysutils/Android.mk:LOCAL_CFLAGS :=
./system/core/charger/Android.mk:LOCAL_CFLAGS += -DBATTERY_DEVICE_NAME=\"$(BOARD_BATTERY_DEVICE_NAME)\"
./system/core/libcutils/Android.mk:LOCAL_CFLAGS += $(hostSmpFlag)
./system/core/libcutils/Android.mk:LOCAL_CFLAGS += -DHAVE_MEMSET16 -DHAVE_MEMSET32
./system/core/libcutils/Android.mk: LOCAL_CFLAGS += -DRECOVERY_PRE_COMMAND='$(TARGET_RECOVERY_PRE_COMMAND)'
./system/core/libcutils/Android.mk: LOCAL_CFLAGS += -DRECOVERY_PRE_COMMAND_CLEAR_REASON
./system/core/libcutils/Android.mk:LOCAL_CFLAGS += $(targetSmpFlag)
./system/core/libcutils/Android.mk:LOCAL_CFLAGS += $(targetSmpFlag)
./system/core/libcutils/Android.mk:LOCAL_CFLAGS += -DTEST_STR_PARMS
./system/core/libusbhost/Android.mk:LOCAL_CFLAGS := -g -DUSE_LIBLOG
./system/core/sh/Android.mk:LOCAL_CFLAGS += -DSHELL -DWITH_LINENOISE
./system/core/sh/Android.mk:make_ash_files: PRIVATE_CFLAGS := $(LOCAL_CFLAGS)
./system/core/libdiskconfig/Android.mk:LOCAL_CFLAGS := -O2 -g -W -Wall -Werror -D_LARGEFILE64_SOURCE
./system/core/debuggerd/Android.mk:LOCAL_CFLAGS := -Wall
./system/core/debuggerd/Android.mk:LOCAL_CFLAGS += -DWITH_VFP
./system/core/debuggerd/Android.mk:LOCAL_CFLAGS += -DWITH_VFP_D32
./system/core/debuggerd/Android.mk:LOCAL_CFLAGS += -DWITH_VFP
./system/core/debuggerd/Android.mk:LOCAL_CFLAGS += -DWITH_VFP_D32
./system/core/adb/Android.mk:LOCAL_CFLAGS += -g -DADB_HOST=1 -Wall -Wno-unused-parameter
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/adb/Android.mk:LOCAL_CFLAGS += -D_XOPEN_SOURCE -D_GNU_SOURCE
./system/core/adb/Android.mk:LOCAL_CFLAGS := -g -DADB_HOST=0 -Wall -Wno-unused-parameter
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/adb/Android.mk:LOCAL_CFLAGS += -D_XOPEN_SOURCE -D_GNU_SOURCE
./system/core/adb/Android.mk:LOCAL_CFLAGS += -DANDROID_GADGET=1
./system/core/adb/Android.mk: LOCAL_CFLAGS += -DBOARD_ALWAYS_INSECURE
./system/core/adb/Android.mk:LOCAL_CFLAGS := \
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/nexus/Android.mk:LOCAL_CFLAGS :=
./system/core/nexus/Android.mk:LOCAL_CFLAGS :=
./system/core/libpixelflinger/Android.mk:LOCAL_CFLAGS := $(PIXELFLINGER_CFLAGS)
./system/core/libpixelflinger/Android.mk:LOCAL_CFLAGS += -DWITH_LIB_HARDWARE
./system/core/libpixelflinger/Android.mk:LOCAL_CFLAGS := $(PIXELFLINGER_CFLAGS)
./system/core/liblog/Android.mk:LOCAL_CFLAGS := -DFAKE_LOG_DEVICE=1
./system/core/init/Android.mk:LOCAL_CFLAGS += -DBOOTCHART=1
./system/core/init/Android.mk:LOCAL_CFLAGS += -DNO_INITLOGO
./system/core/init/Android.mk: $(eval LOCAL_CFLAGS += -D$(system_core_init_define)=\"$($(system_core_init_define))\") \
[email protected] ~/adb $
This is all very confusing.
I pushed my source to dev host for anyone interested. http://d-h.st/wmN
I will make sure to hit that thanks button once I get to a desktop. This RPI takes too long to scroll and I'm using the web from it.
AdamOutler said:
Thanks. I'm not sure where to add it though
Code:
[email protected] ~/adb $ grep -R LOCAL_CFLAGS ./*
./bionic/libc/Android.mk:LOCAL_CFLAGS := $(libc_common_cflags)
./bionic/libc/Android.mk:LOCAL_CFLAGS+= \
./bionic/libc/Android.mk:LOCAL_CFLAGS += -DCRT_LEGACY_WORKAROUND
./bionic/libc/Android.mk:LOCAL_CFLAGS := $(libc_common_cflags) \
./bionic/libc/Android.mk:LOCAL_CFLAGS := $(libc_common_cflags) \
./bionic/libc/Android.mk:LOCAL_CFLAGS := $(libc_common_cflags)
./bionic/libc/Android.mk:LOCAL_CFLAGS := \
./bionic/libc/Android.mk:LOCAL_CFLAGS := \
./bionic/libc/Jamfile: local LOCAL_CFLAGS LOCAL_DEFINES LOCAL_INCLUDES LOCAL_SRC NO_LOCAL_SRC ;
./bionic/libc/Jamfile: CFLAGS += $(LOCAL_CFLAGS) ;
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DVM_SPLIT_2G
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DPRELINK
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DLINKER_TEXT_BASE=$(LINKER_TEXT_BASE)
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DLINKER_AREA_SIZE=$(LINKER_AREA_SIZE)
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DLINKER_DEBUG=0
./bionic/linker/Android.mk: LOCAL_CFLAGS += -DHAVE_ARM_TLS_REGISTER
./bionic/linker/Android.mk: LOCAL_CFLAGS += -DHAVE_TEGRA_ERRATA_657451
./bionic/linker/Android.mk: LOCAL_CFLAGS += -DHAVE_TEGRA_ERRATA_657451
./bionic/linker/Android.mk:LOCAL_CFLAGS += -I$(LOCAL_PATH)/../libc/private
./bionic/linker/Android.mk:LOCAL_CFLAGS += -DANDROID_ARM_LINKER
./bionic/linker/Android.mk: LOCAL_CFLAGS += -DANDROID_X86_LINKER
./bionic/linker/Android.mk: LOCAL_CFLAGS += -I$(LOCAL_PATH)/../libc/arch-x86/bionic
./bionic/linker/Android.mk: LOCAL_CFLAGS += -DANDROID_SH_LINKER
./bionic/linker/README.TXT: LOCAL_CFLAGS += -DLINKER_DEBUG=0
./bionic/linker/README.TXT: LOCAL_CFLAGS += -DLINKER_DEBUG=1
./bionic/libstdc++/Android.mk:LOCAL_CFLAGS := $(libstdc++_cflags)
./bionic/libstdc++/Android.mk:LOCAL_CFLAGS := $(libstdc++_cflags)
./build/tools/acp/Android.mk:LOCAL_CFLAGS += -DWIN32_EXE
./build/tools/acp/Android.mk:LOCAL_CFLAGS += -DMACOSX_RSRC
./build/tools/rgb2565/Android.mk:LOCAL_CFLAGS += -O2 -Wall -Wno-unused-parameter
./build/buildspec.mk.default:# will be added to LOCAL_CFLAGS when building the module.
./build/core/clear_vars.mk:LOCAL_CFLAGS:=
./build/core/build-system.html:LOCAL_CFLAGS += -DNDEBUG=1
./build/core/build-system.html:<h4>LOCAL_CFLAGS</h4>
./build/core/build-system.html:<p><code>LOCAL_CFLAGS += -DLIBUTILS_NATIVE=1</code></p>
./build/core/build-system.html:<code>LOCAL_CPPFLAGS</code> is guaranteed to be after <code>LOCAL_CFLAGS</code>
./build/core/build-system.html:<code>LOCAL_CFLAGS</code>.
./build/core/build-system.html:<code>LOCAL_C_INCLUDES</code>, <code>LOCAL_CFLAGS</code>, and
./build/core/native_test.mk:LOCAL_CFLAGS += -DGTEST_OS_LINUX -DGTEST_HAS_STD_STRING
./build/core/host_native_test.mk:LOCAL_CFLAGS += -DGTEST_OS_LINUX -DGTEST_HAS_STD_STRING -O0 -g
./build/core/binary.mk: LOCAL_CFLAGS += $(TARGET_FDO_CFLAGS)
./build/core/binary.mk:LOCAL_CFLAGS += -DGOOGLE_PROTOBUF_NO_RTTI
./build/core/binary.mk:$(LOCAL_INTERMEDIATE_TARGETS): PRIVATE_CFLAGS := $(LOCAL_CFLAGS)
./build/libs/host/Android.mk:LOCAL_CFLAGS += -DWIN32_EXE
./build/libs/host/Android.mk:LOCAL_CFLAGS += -DMACOSX_RSRC
./external/zlib/Android.mk:LOCAL_CFLAGS += -O3 -DUSE_MMAP $(zlib_arm_flags)
./external/zlib/Android.mk:LOCAL_CFLAGS += -O3 -DUSE_MMAP $(zlib_arm_flags)
./external/zlib/Android.mk:LOCAL_CFLAGS += -O3 -DUSE_MMAP
./system/core/libsysutils/Android.mk:LOCAL_CFLAGS :=
./system/core/charger/Android.mk:LOCAL_CFLAGS += -DBATTERY_DEVICE_NAME=\"$(BOARD_BATTERY_DEVICE_NAME)\"
./system/core/libcutils/Android.mk:LOCAL_CFLAGS += $(hostSmpFlag)
./system/core/libcutils/Android.mk:LOCAL_CFLAGS += -DHAVE_MEMSET16 -DHAVE_MEMSET32
./system/core/libcutils/Android.mk: LOCAL_CFLAGS += -DRECOVERY_PRE_COMMAND='$(TARGET_RECOVERY_PRE_COMMAND)'
./system/core/libcutils/Android.mk: LOCAL_CFLAGS += -DRECOVERY_PRE_COMMAND_CLEAR_REASON
./system/core/libcutils/Android.mk:LOCAL_CFLAGS += $(targetSmpFlag)
./system/core/libcutils/Android.mk:LOCAL_CFLAGS += $(targetSmpFlag)
./system/core/libcutils/Android.mk:LOCAL_CFLAGS += -DTEST_STR_PARMS
./system/core/libusbhost/Android.mk:LOCAL_CFLAGS := -g -DUSE_LIBLOG
./system/core/sh/Android.mk:LOCAL_CFLAGS += -DSHELL -DWITH_LINENOISE
./system/core/sh/Android.mk:make_ash_files: PRIVATE_CFLAGS := $(LOCAL_CFLAGS)
./system/core/libdiskconfig/Android.mk:LOCAL_CFLAGS := -O2 -g -W -Wall -Werror -D_LARGEFILE64_SOURCE
./system/core/debuggerd/Android.mk:LOCAL_CFLAGS := -Wall
./system/core/debuggerd/Android.mk:LOCAL_CFLAGS += -DWITH_VFP
./system/core/debuggerd/Android.mk:LOCAL_CFLAGS += -DWITH_VFP_D32
./system/core/debuggerd/Android.mk:LOCAL_CFLAGS += -DWITH_VFP
./system/core/debuggerd/Android.mk:LOCAL_CFLAGS += -DWITH_VFP_D32
./system/core/adb/Android.mk:LOCAL_CFLAGS += -g -DADB_HOST=1 -Wall -Wno-unused-parameter
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/adb/Android.mk:LOCAL_CFLAGS += -D_XOPEN_SOURCE -D_GNU_SOURCE
./system/core/adb/Android.mk:LOCAL_CFLAGS := -g -DADB_HOST=0 -Wall -Wno-unused-parameter
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/adb/Android.mk:LOCAL_CFLAGS += -D_XOPEN_SOURCE -D_GNU_SOURCE
./system/core/adb/Android.mk:LOCAL_CFLAGS += -DANDROID_GADGET=1
./system/core/adb/Android.mk: LOCAL_CFLAGS += -DBOARD_ALWAYS_INSECURE
./system/core/adb/Android.mk:LOCAL_CFLAGS := \
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/adb/Android.mk:LOCAL_CFLAGS += -O2
./system/core/nexus/Android.mk:LOCAL_CFLAGS :=
./system/core/nexus/Android.mk:LOCAL_CFLAGS :=
./system/core/libpixelflinger/Android.mk:LOCAL_CFLAGS := $(PIXELFLINGER_CFLAGS)
./system/core/libpixelflinger/Android.mk:LOCAL_CFLAGS += -DWITH_LIB_HARDWARE
./system/core/libpixelflinger/Android.mk:LOCAL_CFLAGS := $(PIXELFLINGER_CFLAGS)
./system/core/liblog/Android.mk:LOCAL_CFLAGS := -DFAKE_LOG_DEVICE=1
./system/core/init/Android.mk:LOCAL_CFLAGS += -DBOOTCHART=1
./system/core/init/Android.mk:LOCAL_CFLAGS += -DNO_INITLOGO
./system/core/init/Android.mk: $(eval LOCAL_CFLAGS += -D$(system_core_init_define)=\"$($(system_core_init_define))\") \
[email protected] ~/adb $
This is all very confusing.
I pushed my source to dev host for anyone interested. http://d-h.st/wmN
I will make sure to hit that thanks button once I get to a desktop. This RPI takes too long to scroll and I'm using the web from it.
Click to expand...
Click to collapse
Try build/core/combo/TARGET_linux-arm.mk
bhundven said:
Try build/core/combo/TARGET_linux-arm.mk
Click to expand...
Click to collapse
I added
Code:
LOCAL_CFLAGS += --with-float=soft
LOCAL_LDFLAGS += -lgcc
to both the TARGET you suggested and HOST_linux_x86. I got the same error.
I'm compiling this on the Raspberry Pi itself because i need the statically linked host binary. I'm using the x86 host because there is no arm host available. this should be irrelevant because i'm using the native build tools. Anyway.. I convinced it to use x86 and now the linking seems to be the final challenge.
I did the changes above, then a full make clean then rebuilt the source. the following pastebin shows the entire build log.
http://pastebin.com/XtH1MWVE
Rebellos did some work and posted his source here. I modified it to link to my own source and compile directly on the device without a cross-compiler. He got farther than I did. His actually searches for a device, but there is no real server output and its not sending commands to the device.
http://dl.dropbox.com/u/32145655/adb_armv6_src.zip

[Q] /bin/sh: -c: line 0: syntax error near unexpected token `('

Hey guys i'm so close to getting a complete build on a build but it fails to build the kernel :/. The error:
Code:
/bin/sh: -c: line 0: syntax error near unexpected token `('
/bin/sh: -c: line 0: `set -e; echo ' CC scripts/mod/empty.o'; /home/zohaib/android/kernel/htc/msm8660/scripts/gcc-wrapper.py /home/zohaib/android/prebuilts/misc/linux-x86/ccache/ccache /home/zohaib/android/prebuilt/linux-x86/toolchain/linaro-arm-cortex-a8/bin/arm-eabi-gcc -Wp,-MD,scripts/mod/.empty.o.d -nostdinc -isystem ccache: FATAL: /home/zohaib/android/prebuilt/linux-x86/toolchain/linaro-arm-cortex-a8/bin/arm-eabi-gcc: execv returned (No such file or directory) -I/home/zohaib/android/kernel/htc/msm8660/arch/arm/include -Iarch/arm/include/generated -Iinclude -I/home/zohaib/android/kernel/htc/msm8660/include -include include/generated/autoconf.h -I/home/zohaib/android/kernel/htc/msm8660/scripts/mod -Iscripts/mod -D__KERNEL__ -mlittle-endian -I/home/zohaib/android/kernel/htc/msm8660/arch/arm/mach-msm/include -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -fno-delete-null-pointer-checks -Wno-unused-variable -O3 -mabi=aapcs-linux -mno-thumb-interwork -funwind-tables -D__LINUX_ARM_ARCH__=7 -march=armv5t -Wa,-march=armv7-a -msoft-float -Uarm -fomit-frame-pointer -fgcse-lm -fgcse-sm -fsched-spec-load -fforce-addr -ffast-math -fsingle-precision-constant -mtune=cortex-a8 -march=armv7-a -mfpu=neon -ftree-vectorize -funswitch-loops -fgcse-lm -fgcse-sm -fsched-spec-load -fforce-addr -ffast-math -fsingle-precision-constant -mtune=cortex-a8 -marm -march=armv7-a -mfpu=neon -ftree-vectorize -mvectorize-with-neon-quad -D"KBUILD_STR(s)=#s" -D"KBUILD_BASENAME=KBUILD_STR(empty)" -D"KBUILD_MODNAME=KBUILD_STR(empty)" -c -o scripts/mod/empty.o /home/zohaib/android/kernel/htc/msm8660/scripts/mod/empty.c; scripts/basic/fixdep scripts/mod/.empty.o.d scripts/mod/empty.o '/home/zohaib/android/kernel/htc/msm8660/scripts/gcc-wrapper.py /home/zohaib/android/prebuilts/misc/linux-x86/ccache/ccache /home/zohaib/android/prebuilt/linux-x86/toolchain/linaro-arm-cortex-a8/bin/arm-eabi-gcc -Wp,-MD,scripts/mod/.empty.o.d -nostdinc -isystem ccache: FATAL: /home/zohaib/android/prebuilt/linux-x86/toolchain/linaro-arm-cortex-a8/bin/arm-eabi-gcc: execv returned (No such file or directory) -I/home/zohaib/android/kernel/htc/msm8660/arch/arm/include -Iarch/arm/include/generated -Iinclude -I/home/zohaib/android/kernel/htc/msm8660/include -include include/generated/autoconf.h -I/home/zohaib/android/kernel/htc/msm8660/scripts/mod -Iscripts/mod -D__KERNEL__ -mlittle-endian -I/home/zohaib/android/kernel/htc/msm8660/arch/arm/mach-msm/include -Wall -Wundef -Wstrict-prototypes -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-declaration -Wno-format-security -fno-delete-null-pointer-checks -Wno-unused-variable -O3 -mabi=aapcs-linux -mno-thumb-interwork -funwind-tables -D__LINUX_ARM_ARCH__=7 -march=armv5t -Wa,-march=armv7-a -msoft-float -Uarm -fomit-frame-pointer -fgcse-lm -fgcse-sm -fsched-spec-load -fforce-addr -ffast-math -fsingle-precision-constant -mtune=cortex-a8 -march=armv7-a -mfpu=neon -ftree-vectorize -funswitch-loops -fgcse-lm -fgcse-sm -fsched-spec-load -fforce-addr -ffast-math -fsingle-precision-constant -mtune=cortex-a8 -marm -march=armv7-a -mfpu=neon -ftree-vectorize -mvectorize-with-neon-quad -D"KBUILD_STR(s)=\#s" -D"KBUILD_BASENAME=KBUILD_STR(empty)" -D"KBUILD_MODNAME=KBUILD_STR(empty)" -c -o scripts/mod/empty.o /home/zohaib/android/kernel/htc/msm8660/scripts/mod/empty.c' > scripts/mod/.empty.o.tmp; rm -f scripts/mod/.empty.o.d; mv -f scripts/mod/.empty.o.tmp scripts/mod/.empty.o.cmd'
make[4]: *** [scripts/mod/empty.o] Error 1
make[3]: *** [scripts/mod] Error 2
make[2]: *** [scripts] Error 2
make[2]: *** Waiting for unfinished jobs....
target thumb C++: libv8 <= external/v8/src/contexts.cc
target thumb C++: libv8 <= external/v8/src/conversions.cc
target thumb C++: libv8 <= external/v8/src/counters.cc
target thumb C++: libv8 <= external/v8/src/cpu-profiler.cc
target thumb C++: libv8 <= external/v8/src/data-flow.cc
target thumb C++: libv8 <= external/v8/src/date.cc
target thumb C++: libv8 <= external/v8/src/dateparser.cc
target thumb C++: libv8 <= external/v8/src/debug.cc
target thumb C++: libv8 <= external/v8/src/debug-agent.cc
target thumb C++: libv8 <= external/v8/src/deoptimizer.cc
make[1]: *** [sub-make] Error 2
make[1]: Leaving directory `/home/zohaib/android/kernel/htc/msm8660'
make: *** [TARGET_KERNEL_BINARIES] Error 2
make: *** Waiting for unfinished jobs....
[email protected]:~/android#
Any help is greatly appreciated

Error Building Lineage OS on macOS;unknown type name 'StringPiece'

When I was trying to build my first custom rom based on 7.1.1 (lineage os) the following error occurred.
SPECS ARE :
Macbook pro 2015 retina
Ram:8GB
Storage:512
Processor Name: Intel Core i5
Processor Speed: 2.9 GHz
OS: MacOs Sierra 10.12.2
Xcode:8.2.1(8C1002)
Full Command text is given below:
Code:
vibhoothis-MacBook-Pro:los vibhoothiiaanand$ brunch oneplus2
including vendor/cm/vendorsetup.sh
build/core/product_config.mk:268: *** No matches for product "lineage_oneplus2". Stop.
** Warning: 'oneplus2' is using CM-based makefiles. This will be deprecated in the next major release.
Looking for dependencies in device/oneplus/oneplus2
Looking for dependencies in device/oppo/common
Looking for dependencies in device/qcom/common
Dependencies file not found, bailing out.
============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=7.1.1
LINEAGE_VERSION=14.1-20170129-UNOFFICIAL-oneplus2
TARGET_PRODUCT=cm_oneplus2
TARGET_BUILD_VARIANT=userdebug
TARGET_BUILD_TYPE=release
TARGET_BUILD_APPS=
TARGET_ARCH=arm64
TARGET_ARCH_VARIANT=armv8-a
TARGET_CPU_VARIANT=generic
TARGET_2ND_ARCH=arm
TARGET_2ND_ARCH_VARIANT=armv7-a-neon
TARGET_2ND_CPU_VARIANT=cortex-a53.a57
HOST_ARCH=x86_64
HOST_2ND_ARCH=x86
HOST_OS=darwin
HOST_OS_EXTRA=Darwin-16.3.0-x86_64-i386-64bit
HOST_CROSS_OS=
HOST_CROSS_ARCH=
HOST_CROSS_2ND_ARCH=
HOST_BUILD_TYPE=release
BUILD_ID=NMF26V
OUT_DIR=/Users/vibhoothiiaanand/Desktop/los/out
============================================
============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=7.1.1
LINEAGE_VERSION=14.1-20170129-UNOFFICIAL-oneplus2
TARGET_PRODUCT=cm_oneplus2
TARGET_BUILD_VARIANT=userdebug
TARGET_BUILD_TYPE=release
TARGET_BUILD_APPS=
TARGET_ARCH=arm64
TARGET_ARCH_VARIANT=armv8-a
TARGET_CPU_VARIANT=generic
TARGET_2ND_ARCH=arm
TARGET_2ND_ARCH_VARIANT=armv7-a-neon
TARGET_2ND_CPU_VARIANT=cortex-a53.a57
HOST_ARCH=x86_64
HOST_2ND_ARCH=x86
HOST_OS=darwin
HOST_OS_EXTRA=Darwin-16.3.0-x86_64-i386-64bit
HOST_CROSS_OS=
HOST_CROSS_ARCH=
HOST_CROSS_2ND_ARCH=
HOST_BUILD_TYPE=release
BUILD_ID=NMF26V
OUT_DIR=/Users/vibhoothiiaanand/Desktop/los/out
============================================
Running kati to generate build-cm_oneplus2.ninja...
/Users/vibhoothiiaanand/Desktop/los/out/build-cm_oneplus2.ninja is missing, regenerating...
============================================
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=7.1.1
LINEAGE_VERSION=14.1-20170129-UNOFFICIAL-oneplus2
TARGET_PRODUCT=cm_oneplus2
TARGET_BUILD_VARIANT=userdebug
TARGET_BUILD_TYPE=release
TARGET_BUILD_APPS=
TARGET_ARCH=arm64
TARGET_ARCH_VARIANT=armv8-a
TARGET_CPU_VARIANT=generic
TARGET_2ND_ARCH=arm
TARGET_2ND_ARCH_VARIANT=armv7-a-neon
TARGET_2ND_CPU_VARIANT=cortex-a53.a57
HOST_ARCH=x86_64
HOST_2ND_ARCH=x86
HOST_OS=darwin
HOST_OS_EXTRA=Darwin-16.3.0-x86_64-i386-64bit
HOST_CROSS_OS=
HOST_CROSS_ARCH=
HOST_CROSS_2ND_ARCH=
HOST_BUILD_TYPE=release
BUILD_ID=NMF26V
OUT_DIR=/Users/vibhoothiiaanand/Desktop/los/out
============================================
art/build/Android.common.mk:51: unsupported HOST_ARCH=x86_64
build/core/binary.mk:1253: external/deqp/Android.mk: libdeqp: Unused source files: \
build/core/binary.mk:1253: external/deqp/Android.mk: libdeqp: Unused source files: \
build/core/binary.mk:1253: external/pdfium/third_party/pdfiumbigint.mk: libpdfiumbigint: Unused source files: bigint/BigInteger.cc bigint/BigIntegerUtils.cc bigint/BigUnsigned.cc bigint/BigUnsignedInABase.cc
build/core/binary.mk:1253: external/pdfium/third_party/pdfiumbigint.mk: libpdfiumbigint: Unused source files: bigint/BigInteger.cc bigint/BigIntegerUtils.cc bigint/BigUnsigned.cc bigint/BigUnsignedInABase.cc
./external/speex/Android.mk:56: TODOArm64: enable neon in libspeex
frameworks/av/camera/cameraserver/Android.mk:18: Target has integrated cameraserver into mediaserver. This is weakening security measures introduced in 7.0
build/core/package_internal.mk:143: Empty argument supplied to find-subdir-assets
find: /Users/vibhoothiiaanand/Desktop/los/out/target/common/obj/SHARED_LIBRARIES/libwifi-hal-mock_intermediates: No such file or directory
build/core/package_internal.mk:143: Empty argument supplied to find-subdir-assets
build/core/Makefile:53: Duplicate header copy: /Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/obj/include/qcom/display/copybit.h
build/core/Makefile:53: Defined in: hardware/qcom/display-caf/msm8994/libcopybit/Android.mk hardware/qcom/display-caf/msm8994/libcopybit/Android.mk
build/core/Makefile:53: Duplicate header copy: /Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/obj/include/qcom/display/copybit_priv.h
build/core/Makefile:53: Defined in: hardware/qcom/display-caf/msm8994/libcopybit/Android.mk hardware/qcom/display-caf/msm8994/libcopybit/Android.mk
build/core/Makefile:53: Duplicate header copy: /Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/obj/include/qcom/display/c2d2.h
build/core/Makefile:53: Defined in: hardware/qcom/display-caf/msm8994/libcopybit/Android.mk hardware/qcom/display-caf/msm8994/libcopybit/Android.mk
No private recovery resources for TARGET_DEVICE oneplus2
build/core/dex_preopt.mk:74: warning: overriding commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/dex_bootjars/system/framework/telephony-ext_nodex.jar'
build/core/dex_preopt.mk:74: warning: ignoring old commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/dex_bootjars/system/framework/telephony-ext_nodex.jar'
build/core/dex_preopt_libart_boot.mk:49: warning: overriding commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/system/framework/arm64/boot-telephony-ext.art'
build/core/dex_preopt_libart_boot.mk:49: warning: ignoring old commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/system/framework/arm64/boot-telephony-ext.art'
build/core/dex_preopt_libart_boot.mk:49: warning: overriding commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/system/framework/arm64/boot-telephony-ext.oat'
build/core/dex_preopt_libart_boot.mk:49: warning: ignoring old commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/system/framework/arm64/boot-telephony-ext.oat'
build/core/dex_preopt_libart_boot.mk:49: warning: overriding commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/system/framework/arm/boot-telephony-ext.art'
build/core/dex_preopt_libart_boot.mk:49: warning: ignoring old commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/system/framework/arm/boot-telephony-ext.art'
build/core/dex_preopt_libart_boot.mk:49: warning: overriding commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/system/framework/arm/boot-telephony-ext.oat'
build/core/dex_preopt_libart_boot.mk:49: warning: ignoring old commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/system/framework/arm/boot-telephony-ext.oat'
build/core/java.mk:334: warning: overriding commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/common/obj/APPS/Dialer_intermediates/src/src/org/codeaurora/presenceserv/IPresenceService.java'
build/core/java.mk:334: warning: ignoring old commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/common/obj/APPS/Dialer_intermediates/src/src/org/codeaurora/presenceserv/IPresenceService.java'
build/core/java.mk:334: warning: overriding commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/common/obj/APPS/Dialer_intermediates/src/src/org/codeaurora/presenceserv/IPresenceServiceCB.java'
build/core/java.mk:334: warning: ignoring old commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/common/obj/APPS/Dialer_intermediates/src/src/org/codeaurora/presenceserv/IPresenceServiceCB.java'
build/core/base_rules.mk:316: warning: overriding commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/root/res/images/charger/battery_fail.png'
build/core/base_rules.mk:316: warning: ignoring old commands for target `/Users/vibhoothiiaanand/Desktop/los/out/target/product/oneplus2/root/res/images/charger/battery_fail.png'
Starting build with ninja
ninja: Entering directory `.'
[ 0% 80/46297] host C++: libaapt2 <= ...se/tools/aapt2/filter/ConfigFilter.cpp
FAILED: /bin/bash -c "(prebuilts/clang/host/darwin-x86/clang-2690385/bin/clang++ -I device/oneplus/oneplus2/include -I /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/gen/STATIC_LIBRARIES/libaapt2_intermediates -I external/protobuf/src -I /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/gen/STATIC_LIBRARIES/libaapt2_intermediates/proto -I frameworks/base/tools/aapt2 -I /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates -I /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/gen/STATIC_LIBRARIES/libaapt2_intermediates -I libnativehelper/include/nativehelper \$(cat /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/import_includes) -isystem system/core/include -isystem system/media/audio/include -isystem hardware/libhardware/include -isystem hardware/libhardware_legacy/include -isystem libnativehelper/include -isystem frameworks/native/include -isystem frameworks/native/opengl/include -isystem frameworks/av/include -isystem frameworks/base/include -isystem tools/include -isystem /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/include -c -fno-exceptions -Wno-multichar -m64 -D__STDC_FORMAT_MACROS -D__STDC_CONSTANT_MACROS -isysroot /applications/Xcode/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk -mmacosx-version-min=10.12 -DMACOSX_DEPLOYMENT_TARGET=10.12 -fPIC -funwind-tables -DANDROID -fmessage-length=0 -W -Wall -Wno-unused -Winit-self -Wpointer-arith -O2 -g -fno-strict-aliasing -DNDEBUG -UDEBUG -D__compiler_offsetof=__builtin_offsetof -Werror=int-conversion -Wno-reserved-id-macro -Wno-format-pedantic -Wno-unused-command-line-argument -fcolor-diagnostics -integrated-as -fstack-protector-strong -integrated-as -target x86_64-apple-darwin -isystem /applications/Xcode/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1 -Wsign-promo -Wno-inconsistent-missing-override -target x86_64-apple-darwin -Wall -Werror -Wno-unused-parameter -UNDEBUG -fPIC -D_DARWIN_UNLIMITED_STREAMS -Wno-deprecated-declarations -D_USING_LIBCXX -DGOOGLE_PROTOBUF_NO_RTTI -std=gnu++14 -std=c++11 -Wno-missing-field-initializers -fno-exceptions -fno-rtti -nostdinc++ -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast -Werror=address-of-temporary -Werror=null-dereference -Werror=return-type -MD -MF /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/filter/ConfigFilter.d -o /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/filter/ConfigFilter.o frameworks/base/tools/aapt2/filter/ConfigFilter.cpp ) && (cp /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/filter/ConfigFilter.d /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/filter/ConfigFilter.P; sed -e 's/#.*//' -e 's/^[^:]*: *//' -e 's/ *\\\\\$//' -e '/^\$/ d' -e 's/\$/ :/' < /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/filter/ConfigFilter.d >> /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/filter/ConfigFilter.P; rm -f /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/filter/ConfigFilter.d )"
In file included from frameworks/base/tools/aapt2/filter/ConfigFilter.cpp:17:
In file included from frameworks/base/tools/aapt2/ConfigDescription.h:20:
In file included from frameworks/base/tools/aapt2/util/StringPiece.h:20:
In file included from external/libcxx/include/ostream:138:
In file included from external/libcxx/include/ios:216:
In file included from external/libcxx/include/__locale:21:
frameworks/base/tools/aapt2/locale.h:42:37: error: unknown type name 'StringPiece'
bool initFromFilterString(const StringPiece& config);
^
1 error generated.
[ 0% 80/46297] host C++: libaapt2 <= ...tools/aapt2/compile/XmlIdCollector.cpp
FAILED: /bin/bash -c "(prebuilts/clang/host/darwin-x86/clang-2690385/bin/clang++ -I device/oneplus/oneplus2/include -I /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/gen/STATIC_LIBRARIES/libaapt2_intermediates -I external/protobuf/src -I /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/gen/STATIC_LIBRARIES/libaapt2_intermediates/proto -I frameworks/base/tools/aapt2 -I /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates -I /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/gen/STATIC_LIBRARIES/libaapt2_intermediates -I libnativehelper/include/nativehelper \$(cat /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/import_includes) -isystem system/core/include -isystem system/media/audio/include -isystem hardware/libhardware/include -isystem hardware/libhardware_legacy/include -isystem libnativehelper/include -isystem frameworks/native/include -isystem frameworks/native/opengl/include -isystem frameworks/av/include -isystem frameworks/base/include -isystem tools/include -isystem /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/include -c -fno-exceptions -Wno-multichar -m64 -D__STDC_FORMAT_MACROS -D__STDC_CONSTANT_MACROS -isysroot /applications/Xcode/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.12.sdk -mmacosx-version-min=10.12 -DMACOSX_DEPLOYMENT_TARGET=10.12 -fPIC -funwind-tables -DANDROID -fmessage-length=0 -W -Wall -Wno-unused -Winit-self -Wpointer-arith -O2 -g -fno-strict-aliasing -DNDEBUG -UDEBUG -D__compiler_offsetof=__builtin_offsetof -Werror=int-conversion -Wno-reserved-id-macro -Wno-format-pedantic -Wno-unused-command-line-argument -fcolor-diagnostics -integrated-as -fstack-protector-strong -integrated-as -target x86_64-apple-darwin -isystem /applications/Xcode/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1 -Wsign-promo -Wno-inconsistent-missing-override -target x86_64-apple-darwin -Wall -Werror -Wno-unused-parameter -UNDEBUG -fPIC -D_DARWIN_UNLIMITED_STREAMS -Wno-deprecated-declarations -D_USING_LIBCXX -DGOOGLE_PROTOBUF_NO_RTTI -std=gnu++14 -std=c++11 -Wno-missing-field-initializers -fno-exceptions -fno-rtti -nostdinc++ -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast -Werror=address-of-temporary -Werror=null-dereference -Werror=return-type -MD -MF /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/compile/XmlIdCollector.d -o /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/compile/XmlIdCollector.o frameworks/base/tools/aapt2/compile/XmlIdCollector.cpp ) && (cp /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/compile/XmlIdCollector.d /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/compile/XmlIdCollector.P; sed -e 's/#.*//' -e 's/^[^:]*: *//' -e 's/ *\\\\\$//' -e '/^\$/ d' -e 's/\$/ :/' < /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/compile/XmlIdCollector.d >> /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/compile/XmlIdCollector.P; rm -f /Users/vibhoothiiaanand/Desktop/los/out/host/darwin-x86/obj/STATIC_LIBRARIES/libaapt2_intermediates/compile/XmlIdCollector.d )"
In file included from frameworks/base/tools/aapt2/compile/XmlIdCollector.cpp:17:
In file included from frameworks/base/tools/aapt2/ResourceUtils.h:20:
In file included from frameworks/base/tools/aapt2/NameMangler.h:20:
In file included from frameworks/base/tools/aapt2/Resource.h:20:
In file included from frameworks/base/tools/aapt2/ConfigDescription.h:20:
In file included from frameworks/base/tools/aapt2/util/StringPiece.h:20:
In file included from external/libcxx/include/ostream:138:
In file included from external/libcxx/include/ios:216:
In file included from external/libcxx/include/__locale:21:
frameworks/base/tools/aapt2/locale.h:42:37: error: unknown type name 'StringPiece'
bool initFromFilterString(const StringPiece& config);
^
1 error generated.
[ 0% 80/46297] host Java: jarjar (/Us...IBRARIES/jarjar_intermediates/classes)
ninja: build stopped: subcommand failed.
make: *** [ninja_wrapper] Error 1
#### make failed to build some targets (49 seconds) ####

android oreo 8.0.0_r34 build error

Hi,
I am trying to build android oreo aosp for the target car_emu_x86_64-userdebug and i am getting build error.
Steps followed:
1. repo init -u <android source url> -b android-8.0.0_r34 --depth=1
2. repo sync
3. source build/envsetup.sh
4. lunch car_emu_x86_64-userdebug
5. make -j8
error:
[ 0% 9/15494] target C++: libsurfaceflinger <= frameworks/native/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp
FAILED: out/target/product/car-x86_64/obj/SHARED_LIBRARIES/libsurfaceflinger_intermediates/DisplayHardware/FramebufferSurface.o
/bin/bash -c "PWD=/proc/self/cwd prebuilts/clang/host/linux-x86/clang-4053586/bin/clang++ -I frameworks/native/vulkan/include -I external/vulkan-validation-layers/libs/vkjson -I system/libhwbinder/fast_msgq/include -I frameworks/native/services/surfaceflinger -I out/target/product/car-x86_64/obj/SHARED_LIBRARIES/libsurfaceflinger_intermediates -I out/target/product/car-x86_64/gen/SHARED_LIBRARIES/libsurfaceflinger_intermediates -I libnativehelper/include/nativehelper \$(cat out/target/product/car-x86_64/obj/SHARED_LIBRARIES/libsurfaceflinger_intermediates/import_includes) -I system/core/include -I system/media/audio/include -I hardware/libhardware/include -I hardware/libhardware_legacy/include -I hardware/ril/include -I libnativehelper/include -I frameworks/native/include -I frameworks/native/opengl/include -I frameworks/av/include -isystem out/target/product/car-x86_64/obj/include -isystem bionic/libc/arch-x86_64/include -isystem bionic/libc/include -isystem bionic/libc/kernel/uapi -isystem bionic/libc/kernel/uapi/asm-x86 -isystem bionic/libc/kernel/android/scsi -isystem bionic/libc/kernel/android/uapi -c -fno-exceptions -Wno-multichar -O2 -Wa,--noexecstack -Werror=format-security -D_FORTIFY_SOURCE=2 -Wstrict-aliasing=2 -ffunction-sections -fno-short-enums -fstrict-aliasing -funwind-tables -fstack-protector-strong -no-canonical-prefixes -Werror=pointer-to-int-cast -Werror=int-to-pointer-cast -Werror=implicit-function-declaration -O2 -g -fno-strict-aliasing -DANDROID -fmessage-length=0 -W -Wall -Wno-unused -Winit-self -Wpointer-arith -DNDEBUG -UDEBUG -fdebug-prefix-map=/proc/self/cwd= -D__compiler_offsetof=__builtin_offsetof -Werror=int-conversion -Wno-reserved-id-macro -Wno-format-pedantic -Wno-unused-command-line-argument -fcolor-diagnostics -Wno-expansion-to-defined -fdebug-prefix-map=\$PWD/= -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Werror=date-time -nostdlibinc -m64 -march=x86-64 -DUSE_SSSE3 -mssse3 -msse4 -msse4.1 -msse4.2 -mpopcnt -target x86_64-linux-android -Bprebuilts/gcc/linux-x86/x86/x86_64-linux-android-4.9/x86_64-linux-android/bin -Wsign-promo -Wno-inconsistent-missing-override -Wno-null-dereference -D_LIBCPP_ENABLE_THREAD_SAFETY_ANNOTATIONS -Wno-thread-safety-negative -std=gnu++14 -fno-rtti -DLOG_TAG="SurfaceFlinger" -DGL_GLEXT_PROTOTYPES -DEGL_EGLEXT_PROTOTYPES -fvisibility=hidden -Werror=format -Wall -Werror -Wunused -Wunreachable-code -std=c++1z -fPIC -D_USING_LIBCXX -DANDROID_STRICT -Werror=int-to-pointer-cast -Werror=pointer-to-int-cast -Werror=address-of-temporary -Werror=return-type -MD -MF out/target/product/car-x86_64/obj/SHARED_LIBRARIES/libsurfaceflinger_intermediates/DisplayHardware/FramebufferSurface.d -o out/target/product/car-x86_64/obj/SHARED_LIBRARIES/libsurfaceflinger_intermediates/DisplayHardware/FramebufferSurface.o frameworks/native/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp"
frameworks/native/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp:180:18: error: no member named 'setClientTarget' in 'android::HWComposer'
mHwc.setClientTarget(mDisplayType, outSlot, outFence, outBuffer, outDataspace);
~~~~ ^
frameworks/native/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp:180:48: error: use of undeclared identifier 'outSlot'
mHwc.setClientTarget(mDisplayType, outSlot, outFence, outBuffer, outDataspace);
^
frameworks/native/services/surfaceflinger/DisplayHardware/FramebufferSurface.cpp:180:78: error: use of undeclared identifier 'outDataspace'
mHwc.setClientTarget(mDisplayType, outSlot, outFence, outBuffer, outDataspace);
^
3 errors generated.
[ 0% 15/15494] Ensuring Jack server is installed and started
Jack server already installed in "/home/abdul/.jack-server"
Launching Jack server java -XX:MaxJavaStackTraceDepth=-1 -Djava.io.tmpdir=/tmp -Dfile.encoding=UTF-8 -XX:+TieredCompilation -cp /home/abdul/.jack-server/launcher.jar com.android.jack.launcher.ServerLauncher
[ 0% 16/15494] target C++: libsurfaceflinger <= frameworks/native/services/surfaceflinger/SurfaceFlinger_hwc1.cpp
ninja: build stopped: subcommand failed.
12:08:48 ninja failed with: exit status 1
build/core/main.mk:21: recipe for target 'run_soong_ui' failed
make: *** [run_soong_ui] Error 1
#### make failed to build some targets (05:44 (mm:ss)) ####
Facing similar issue. Got any fix?

[HELP]An error while building a Rom

Hello,
Right now i'm trying to build an AOSP Rom for my device J510FN, i was able to solve all the error 'till now but this one make me lose all my ideas :crying: :
Code:
/home/titel/out/soong/make_vars-aosp_j5xnlte.mk:380: warning: TARGET_GLOBAL_CFLAGS does not match between Make and Soong:
/home/titel/out/soong/make_vars-aosp_j5xnlte.mk:380: warning: Make : -mfpu=neon -mfloat-abi=softfp
/home/titel/out/soong/make_vars-aosp_j5xnlte.mk:380: warning: Soong: -fno-exceptions -Wno-multichar -ffunction-sections -fdata-sections -funwind-tables -fstack-protector-strong -Wa,--noexecstack -Werror=format-security -D_FORTIFY_SOURCE=2 -fno-short-enums -no-canonical-prefixes -fno-canonical-system-headers -fno-builtin-sin -fno-strict-volatile-bitfields -DNDEBUG -g -Wstrict-aliasing=2 -fgcse-after-reload -frerun-cse-after-loop -frename-registers -DANDROID -fmessage-length=0 -W -Wall -Wno-unused -Winit-self -Wpointer-arith -DNDEBUG -UDEBUG -fdebug-prefix-map=/proc/self/cwd= -fdiagnostics-color -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Werror=date-time -mthumb-interwork -msoft-float -mfloat-abi=softfp -mfpu=neon -mcpu=cortex-a53 -mfpu=neon-fp-armv8 -D__ARM_FEATURE_LPAE=1
/home/titel/out/soong/make_vars-aosp_j5xnlte.mk:386: warning: TARGET_GLOBAL_CPPFLAGS does not match between Make and Soong:
/home/titel/out/soong/make_vars-aosp_j5xnlte.mk:386: warning: Make : -mfpu=neon -mfloat-abi=softfp
/home/titel/out/soong/make_vars-aosp_j5xnlte.mk:386: warning: Soong: -Wsign-promo -fvisibility-inlines-hidden
/home/titel/out/soong/make_vars-aosp_j5xnlte.mk:696: error: Soong variable check failed.
23:17:52 ckati failed with: exit status 1
#### failed to build some targets (1 seconds) ####
What I understand is that "TARGET_GLOBAL_CFLAGS" must match with "Soong" but when I make those things identical it says that they aren't the same, keep in mind that this error log was taken when "TARGET_GLOBAL_CFLAGS" was totally deleted from the file where he could normally be ( aosp_j5xnlte.mk ).
Any help is welcome! :good: :good:
Any help?

Categories

Resources