Android OS Forum banner
1 - 20 of 173 Posts

·
Android Lover
Joined
·
405 Posts
This is a fix for the network location bug on AOSP ROMs. The network location bug can be seen when you attempt to get a location without using WiFi or GPS (using carrier network only). While using only carrier network to obtain your location, your phone will think you're in another city, state, country, planet, galaxy, etc. You can test this by refreshing a weather widget after turning off GPS and Wifi.

Grab the NetworkLocation.apk from the link below and put it on the root of your sdcard. It's from the 2.11.605.3 Sense ROM.

Using a file explorer like root explorer:

- You must use the file explorer to mount /system/app as r/w.

1) Rename (or delete if you're brave) NetworkLocation.apk to NetworkLocation.bak from:
/system/app

2) Reboot.

3) Place a COPY of /sdcard/NetworkLocation.apk (from 2.11.605.3) in:
/system/app

4) Change the permissions of /system/app/NetworkLocation.apk to:
rw-r--r--
Owner: read, write
Group: read
Others: read

5) Even though I placed the file in /system/app, I still had to "install" it. So, click on the NetworkLocation.apk on your SD Card and let it install.

6) Reboot.

For those of you brave enough to use Terminal Emulator, I haven't tried these steps, but they should work:

Open Terminal Emulator

$ su
# mount -o rw,remount -t ext4 /dev/block/mmcblk0p25 /system
# cd /system/app
# mv NetworkLocation.apk NetworkLocation.bak (or if you want to delete it use "rm" instead of "mv")

REBOOT

Open Terminal Emulator

$ su
# mount -o rw,remount -t ext4 /dev/block/mmcblk0p25 /system
# cp /sdcard/NetworkLocation.apk /system/app
# chmod 644 /system/app/NetworkLocation.apk

exit terminal

Click on /sdcard/NetworkLocation.apk to install.

REBOOT

Here's a link to the apk I used:
http://db.tt/U974Crfk

Let me know if this works for you! *crossing fingers*

Edit: tried to make steps a little more clear.

Thanks freehood4all - pointed out an error in the terminal commands.
 

·
Android Addict
Joined
·
1,497 Posts
Will let you know in T Minus 10 minutes.

Edit: Well 2 interesting things happened. First off it didn't work then second not even after enabling WiFi would it pick up on my location. So I don't know if I did something wrong or what but it did not work correctly for me.
 

·
Android Addict
Joined
·
1,497 Posts
skinien said:
Shared a link to the .apk if it helps.
Already had 2.11.605.3 on my phone (Like to try out all the OTA's just for the hell of it) but should help with other testers and may be that mine was corrupted.
 

·
Android Lover
Joined
·
405 Posts
Discussion Starter · #5 ·
miketoasty said:
Will let you know in T Minus 10 minutes.

Edit: Well 2 interesting things happened. First off it didn't work then second not even after enabling WiFi would it pick up on my location. So I don't know if I did something wrong or what but it did not work correctly for me.
That's what happened to me until I installed the apk by clicking it. After installing it, I rebooted and everything worked.
 

·
Android Apprentice
Joined
·
45 Posts
I installed and rebooted but it didn't work. I'm on OMFGB 9-13 nightly.

Question. Did you install the apk in the system apps or the one from the sd card?
 

·
Android Lover
Joined
·
405 Posts
Discussion Starter · #7 ·
bagoffreedom said:
I installed and rebooted but it didn't work. I'm on OMFGB 9-13 nightly.

Question. Did you install the apk in the system apps or the one from the ad card?
SD Card.

Damn, I hope I'm not forgetting a step. It seemed that just placing the .apk in system/app wasn't sufficient; I couldn't obtain a location. In fact, google.com in my browser didn't even give me the option to update my location. After I installed the .apk sitting on my SD Card, I rebooted and everything worked.
 

·
Android Lover
Joined
·
405 Posts
Discussion Starter · #8 ·
miketoasty said:
Will let you know in T Minus 10 minutes.

Edit: Well 2 interesting things happened. First off it didn't work then second not even after enabling WiFi would it pick up on my location. So I don't know if I did something wrong or what but it did not work correctly for me.
Sorry dude, I'm betting you know how to restore the old .apk. I've edited the OP to instruct testers to rename the original .apk rather than deleting it.

Just in case, you can grab the CM .apk from the CM ROM sitting on your SD card. :p
 

·
Android Addict
Joined
·
1,497 Posts
Guys, this ACTUALLY works! For the first time I was able to pull my network location in the Network Location APP (From the market). Please if you are running try this and see if it works, because so far it has worked for 3 people. Use the link provided for the Network Location.apk

My Steps:

Delete Network Location.apk from /system/app

Reboot

Copy *New* Network Location.apk from /sdcard/download/ to /system/app

Change permissions to RW-/R--/R--

Go back to SD Card and install Network Location.apk *The new one*

Reboot

Not be in Africa!

*Running CM7 RC1.8, Stock Kernel*
 

·
Premium Member
Joined
·
7,690 Posts
miketoasty said:
Guys, this ACTUALLY works! For the first time I was able to pull my network location in the Network Location APP (From the market). Please if you are running try this and see if it works, because so far it has worked for 3 people. Use the link provided for the Network Location.apk

My Steps:

Delete Network Location.apk from /system/app

Reboot

Copy *New* Network Location.apk from /sdcard/download/ to /system/app

Change permissions to RW-/R--/R--

Go back to SD Card and install Network Location.apk *The new one*

Reboot

Not be in Africa!

*Running CM7 RC1.8, Stock Kernel*
Doing now standby!!!
 

·
Android Beginner
Joined
·
27 Posts
This appears to work for me as well. Good find! Will test more and report back. Wonder what other files we should bull from the stock rom to make other features work better.
 

·
Android Addict
Joined
·
1,497 Posts
johnfoam said:
This appears to work for me as well. Good find! Will test more and report back. Wonder what other files we should bull from the stock rom to make other features work better.
After this what else needs fixed? I know that Bluetooth is buggy as hell, but other than that I would say, everything, works. I don't know if you guys have other issues but this was literally the LAST issue I personally was having with AOSP.
 

·
Android Lover
Joined
·
405 Posts
Discussion Starter · #18 ·
Wow! I'm glad this thing may be fixed. Running CM 1.6.1 - this is the ONLY bug I have. Or should I say, HAD.
 
1 - 20 of 173 Posts
Top