# CM7 Compile Issues....Here we go again.



## icanhazdroid

Alright, so first off, I can compile source. I'm no noob to that. Especially when it's written in ink on the CM wiki. I took the instructions for the Inc and modified it for the vivow.. Here's a paste bin of my issues..

http://pastebin.com/RqJzTeVG

Anyone?


----------



## ProTekk

When did you last sync? Try resyncing and running \'make clobber\'

Sent from my Incredible 2 using RootzWiki Forums


----------



## icanhazdroid

\\\\\\\"ProTekk\\\\\\\" said:


> When did you last sync? Try resyncing and running \\\\\\\\\\\\\\\'make clobber\\\\\\\\\\\\\\\'
> 
> Sent from my Incredible 2 using RootzWiki Forums


A couple minutes before compiling. I\'ll do that later when I get home, thanks for stepping in and helping me out again bro!


----------



## icanhazdroid

Uh, this is how I'm supposed to do it sir?



Code:


<br />
[email protected] ~/android/system $ repo sync \'make clobber\'<br />
error: project 'make not found<br />


----------



## fixxxer2012

ProTekk said:


> When did you last sync? Try resyncing and running \'make clobber\'
> 
> Sent from my Incredible 2 using RootzWiki Forums


i didn't know you owned a dinc2?


----------



## icanhazdroid

fixxxer2012 said:


> i didn't know you owned a dinc2?


He switched also









And ProTekk I tested a Supersonic build for someone just to see what would happen and it appears to be compiling fine... something wrong with the Vivow source?


----------



## fixxxer2012

icanhazdroid said:


> He switched also


funny as alot of tbolt users are coming over to the dinc2.


----------



## icanhazdroid

fixxxer2012 said:


> funny as alot of tbolt users are coming over to the dinc2.


Seriously, that phone was fun for a while but proved to be more of a headache


----------



## fixxxer2012

icanhazdroid said:


> Seriously, that phone was fun for a while but proved to be more of a headache


agreed, i do miss lte but i never had a great 4g signal anyways. did you already get your dinc2?


----------



## icanhazdroid

fixxxer2012 said:


> agreed, i do miss lte but i never had a great 4g signal anyways. did you already get your dinc2?


Same, it always cut out. Nah not yet, I just updated everything to make it look like I did lol. It should be here latest Wednesday (I hope).


----------



## JBirdVegas

The key is *** BOARD_USES_RECOVERY_CHARGEMODE is deprecated

Have you read http://bit.ly/opcSJZ as koush suggests?


----------



## JBirdVegas

Well nm the link is bad have you tried unsetting the flag in the corresponding makefile?

Then building


----------



## icanhazdroid

Yeah did try the link, broken. What is this flag you speak of? Noob at work


----------



## Evileyefox

So did the make clobber work?


----------



## icanhazdroid

If I did it correctly, then no.. read a few posts above, I showed what I did


----------



## ProTekk

Open device/htc/vivow/BoardConfig.mk and do the following

Change



Code:


BOARD_USES_RECOVERY_CHARGEMODE := true

to



Code:


BOARD_USES_RECOVERY_CHARGEMODE := false

Save and build.


----------



## icanhazdroid

ProTekk said:


> Open device/htc/vivow/BoardConfig.mk and do the following
> 
> Change
> 
> 
> 
> Code:
> 
> 
> BOARD_USES_RECOVERY_CHARGEMODE := true
> 
> to
> 
> 
> 
> Code:
> 
> 
> BOARD_USES_RECOVERY_CHARGEMODE := false
> 
> Save and build.


Man I feel worse than a total noob sometimes, now I get what the error was saying.. Thanks man


----------



## ProTekk

icanhazdroid said:


> Man I feel worse than a total noob sometimes, now I get what the error was saying.. Thanks man


Tbh, not sure if it breaks anything or not but it allowed me to build. Btw, took me an hour or so to find the answer out lol

Sent from my Incredible 2 using RootzWiki Forums


----------



## JBirdVegas

To me it sounded like koush was saying we found a more specific way of handling this devices recovery look here 
for our flagThe warning sounds like the flag will cause problems with either RomManager or ClockWorks Recovery...just my guess from reading the logcat


----------



## icanhazdroid

ProTekk said:


> To me it sounded like koush was saying we found a more specific way of handling this devices recovery look here
> for our flagThe warning sounds like the flag will cause problems with either RomManager or ClockWorks Recovery...just my guess from reading the logcat


I thought it just wouldn't charge in recovery?


----------



## ProTekk

What are the other errors?

Sent from my Incredible 2 using RootzWiki Forums


----------



## icanhazdroid

ProTekk said:


> What are the other errors?
> 
> Sent from my Incredible 2 using RootzWiki Forums


May not even be considered errors to some lol, but here:
http://pastebin.com/8bh7zihb

Feel free to be blunt bro


----------



## ProTekk

You derp'd, that's all.

cd to your build dir and run this



Code:


git clone [URL=git://github.com/koush/proprietary_vendor_htc.git]git://github.com/koush/proprietary_vendor_htc.git[/URL] vendor/htc

then

cd to device/htc/vivow and run



Code:


~/path/to/build/dir/vendor/cyanogen/get-rommanager

then cd back to your build dir and then make clobber and rebuild.


----------



## icanhazdroid

ProTekk said:


> You derp'd, that's all.
> 
> cd to your build dir and run this
> 
> git clone git://github.com/koush/proprietary_vendor_htc.git vendor/htc
> 
> then
> 
> cd to device/htc/vivow and run
> 
> ~/path/to/build/dir/vendor/cyanogen/get-rommanager
> 
> then cd back to your build dir and then make clobber and rebuild.


I'll try that when I get home from work... Like 4ish or so. Thanks bud. How exactly do I run the make clobber command? Just type it after repo sync?


----------



## ProTekk

You can run it any time but it's just a simple command in terminal 'make clobber' press enter and done.


----------



## icanhazdroid

ProTekk said:


> You can run it any time but it's just a simple command in terminal 'make clobber' press enter and done.


Gotcha, just making sure it wasn't part of repo sync


----------



## JBirdVegas

icanhazdroid said:


> I'm using Linux Mint
> ...
> I thought it just wouldn't charge in recovery?


I use mint also any ubuntu 10.10+ varient will work

I don't know anything about this device or its recovery, but I've compiled cm7 about a million times and have ran into lots of problems along the way


----------



## icanhazdroid

JBirdVegas said:


> I use mint also any ubuntu 10.10+ varient will work
> 
> I don't know anything about this device or its recovery, but I've compiled cm7 about a million times and have ran into lots of problems along the way


Seems like each HTC device keeps getting more complicated to compile for...


----------



## icanhazdroid

Alright I'm building now.. let's see what happens


----------



## icanhazdroid

Hey guys I got it to finally compile! Thanks for all the help (again)








Here's the ROM compiled... someone wanna test and see if it works correctly? Oh also, I'm having repo sync issues for the vivow due to the changes I made in the BoardConfig.mk file. Should I revert? And I'm not planing on releases ROMs or anything anytime soon..still trying to learn more code, but I'm always busy with other stuff..

Anyway here you go, if someone wants to make sure it works. I don't get my Inc2 till friday at the latest.
MD5: a7d0859d4ac1829788d7c7bf4c97e1ac

http://db.tt/deKbDfQR


----------



## ProTekk

rm -rf build .repo/projects/build

Then resync.

Sent from my Incredible 2 using RootzWiki Forums


----------



## icanhazdroid

ProTekk said:


> rm -rf build .repo/projects/build
> 
> Then resync.
> 
> Sent from my Incredible 2 using RootzWiki Forums


Didn't seem to work.. I'm gonna revert it to :true and attempt another build..

Edit:.. Yeah reverting it worked, then make clobber just for safety measures. I'm building another one for the hell of it


----------



## aeroevan

ProTekk said:


> Open device/htc/vivow/BoardConfig.mk and do the following
> 
> Change
> 
> 
> 
> Code:
> 
> 
> BOARD_USES_RECOVERY_CHARGEMODE := true
> 
> to
> 
> 
> 
> Code:
> 
> 
> BOARD_USES_RECOVERY_CHARGEMODE := false
> 
> Save and build.


I had a gerrit review for a vivow specific fix (basically moving the required chargemode stuff into device/htc/vivow), but it looks like http://review.cyanogenmod.com/#change,9351 should fix the chargemode in recovery (moving chargemode stuff into 7x30-common).


----------



## fixxxer2012

whats the advantage of making your own cm7 build? aren't there nightlies currently for the dinc2 anyways?


----------



## JBirdVegas

fixxxer2012 said:


> whats the advantage of making your own cm7 build? aren't there nightlies currently for the dinc2 anyways?


Lots of advantages:
Learning (most importantly)
I compile my apps against CM source code
git cherrypick to tryout new features before the public sees them
You customize your build to your liking
Want your own graphics ...drop them in the frameworks
Want it to change languages its in the source code
Want to change the reboot menu string? Its in the source code
You can change the colors of everything
Tired of installing you 20 fav apps everytime you wipe? Add them to the prebuilt and they will get included in your builds

I think the best reason I may have mentioned learning


----------



## icanhazdroid

JBirdVegas said:


> Lots of advantages:
> Learning (most importantly)
> I compile my apps against CM source code
> git cherrypick to tryout new features before the public sees them
> You customize your build to your liking
> Want your own graphics ...drop them in the frameworks
> Want it to change languages its in the source code
> Want to change the reboot menu string? Its in the source code
> You can change the colors of everything
> Tired of installing you 20 fav apps everytime you wipe? Add them to the prebuilt and they will get included in your builds
> 
> I think the best reason I may have mentioned learning


Learning is exactly my purpose


----------



## icanhazdroid

aeroevan said:


> I had a gerrit review for a vivow specific fix (basically moving the required chargemode stuff into device/htc/vivow), but it looks like http://review.cyanogenmod.com/#change,9351 should fix the chargemode in recovery (moving chargemode stuff into 7x30-common).


So..should it already be merged then?


----------



## ProTekk

No. Status is still under review. It'll change to merged once it's actually merged.


----------



## JBirdVegas

Just got merged:

https://github.com/CyanogenMod/android_device_htc_vivow/commit/624cb36f56a479a3ee26c0f0616365a9160c2ff0


----------



## JBirdVegas

Nevermind I just realized that was a different flag sorry


----------



## icanhazdroid

ProTekk said:


> Nevermind I just realized that was a different flag sorry


Man you had me going there lol


----------



## dhemke17

Well...I've been working to compile this for the last 48 hours. I have got it to begin compiling and have made it quite the ways in. I have reached a stand-still that I hope one of you guys can help me out with.



Code:


<br />
<br />
Copy: out/target/product/vivow/obj/lib/libaudioalsa.so<br />
target SharedLib: libaudio (out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/LINKED/libaudio.so)<br />
prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/../lib/gcc/arm-eabi/4.4.3/../../../../arm-eabi/bin/ld: out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/AudioHardware.o: in function [URL=android::AudioHardware::setMicMute_nosync(bool):hardware/msm7k/libaudio-msm7x30/AudioHardware.cpp:868]android::AudioHardware::setMicMute_nosync(bool):hardware/msm7k/libaudio-msm7x30/AudioHardware.cpp:868[/URL]: error: undefined reference to 'msm_device_mute'<br />
prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/../lib/gcc/arm-eabi/4.4.3/../../../../arm-eabi/bin/ld: out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/AudioHardware.o: in function [URL=android::AudioHardware::AudioHardware():hardware/msm7k/libaudio-msm7x30/AudioHardware.cpp:521]android::AudioHardware::AudioHardware():hardware/msm7k/libaudio-msm7x30/AudioHardware.cpp:521[/URL]: error: undefined reference to 'msm_reset_all_device'<br />
prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/../lib/gcc/arm-eabi/4.4.3/../../../../arm-eabi/bin/ld: out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/AudioHardware.o: in function [URL=android::AudioHardware::AudioHardware():hardware/msm7k/libaudio-msm7x30/AudioHardware.cpp:521]android::AudioHardware::AudioHardware():hardware/msm7k/libaudio-msm7x30/AudioHardware.cpp:521[/URL]: error: undefined reference to 'msm_reset_all_device'<br />
prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/../lib/gcc/arm-eabi/4.4.3/../../../../arm-eabi/bin/ld: out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/AudioHardware.o: in function [URL=android::updateDeviceInfo(unsigned]android::updateDeviceInfo(unsigned[/URL] int, unsigned int, unsigned int, unsigned int):hardware/msm7k/libaudio-msm7x30/AudioHardware.cpp:423: error: undefined reference to 'msm_device_mute'<br />
collect2: ld returned 1 exit status<br />
make: *** [out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/LINKED/libaudio.so] Error 1<br />

It makes it to this point and seizes every time. Any advice, possibly a work-around if it exists would be spectacular. Thanks in advance


----------



## aeroevan

dhemke17 said:


> Well...I've been working to compile this for the last 48 hours. I have got it to begin compiling and have made it quite the ways in. I have reached a stand-still that I hope one of you guys can help me out with.
> 
> Copy: out/target/product/vivow/obj/lib/libaudioalsa.so
> target SharedLib: libaudio (out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/LINKED/libaudio.so)
> prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/../lib/gcc/arm-eabi/4.4.3/../../../../arm-eabi/bin/ld: out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/AudioHardware.o: in function android::AudioHardware::setMicMute_nosync(bool):hardware/msm7k/libaudio-msm7x30/AudioHardware.cpp:868: error: undefined reference to 'msm_device_mute'
> prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/../lib/gcc/arm-eabi/4.4.3/../../../../arm-eabi/bin/ld: out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/AudioHardware.o: in function android::AudioHardware::AudioHardware():hardware/msm7k/libaudio-msm7x30/AudioHardware.cpp:521: error: undefined reference to 'msm_reset_all_device'
> prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/../lib/gcc/arm-eabi/4.4.3/../../../../arm-eabi/bin/ld: out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/AudioHardware.o: in function android::AudioHardware::AudioHardware():hardware/msm7k/libaudio-msm7x30/AudioHardware.cpp:521: error: undefined reference to 'msm_reset_all_device'
> prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/../lib/gcc/arm-eabi/4.4.3/../../../../arm-eabi/bin/ld: out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/AudioHardware.o: in function android::updateDeviceInfo(unsigned int, unsigned int, unsigned int, unsigned int):hardware/msm7k/libaudio-msm7x30/AudioHardware.cpp:423: error: undefined reference to 'msm_device_mute'
> collect2: ld returned 1 exit status
> make: *** [out/target/product/vivow/obj/SHARED_LIBRARIES/libaudio_intermediates/LINKED/libaudio.so] Error 1
> 
> It makes it to this point and seizes every time. Any advice, possibly a work-around if it exists would be spectacular. Thanks in advance


It sounds like it isn't linking to the proprietary lubaudioalsa. Make sure it got pulled when using the extract script.


----------



## dhemke17

aeroevan said:


> It sounds like it isn't linking to the proprietary lubaudioalsa. Make sure it got pulled when using the extract script.


I went and made sure that everything was pulled and all pulled. I am pretty much at a loss at this point.


----------



## JBirdVegas

Try make clobber then pull the proprietary files from github.com/koush

Sync up the try a fresh build

Is your build straight cm or have you made changed to parts of the system?


----------



## dhemke17

It's straight cm, I want to make sure I can at least get that to build before tweaking it. I've resynced and tried...no go. As far as make cobbler, I get an error that cobbler is not defined or something like that.


----------



## JBirdVegas

Try setting $TOP

If your envsetup.sh is @ ~/my/awesome/path/build/envsetup.sh

Then run

export TOP=~/my/awesome/path
source $TOP/build/envsetup.sh && brunch


----------



## dhemke17

JBirdVegas said:


> Try setting TOP
> 
> If your envsetup.sh is @ ~/my/awesome/path/build/envsetup.sh
> 
> Then run
> 
> export TOP=~/my/awesome/path
> source TOP/build/envsetup.sh && brunch


I'll give this a go and see what happens.


----------



## dhemke17

I've decided to start fresh. I rolled back.my version of ubuntu to 10.04, andhave completely reset my environment. I'm pulling the source bow and will update as to whether I cab actually build or not. I'm using a mac and parallels. If this doesn't work, I'm going to partition ny harddrive and use ubuntu on that and try again.

EDIT: I have gotten my computer to successfully compile both CM7 and OMGB. Rolling back to 10.04 seemed to do the trick. Thanks for all your help.


----------

