Adfree not working - Desire Q&A, Help & Troubleshooting

It's more of a question as to how some ROMs get it working without S-OFF (such as MIUI). How is this achieved?
I've made my own ROM and it's all up and running nicely and AdFree installs/updates to /data by symlinking but ads still appear. Anyone have a solution as I don't really wanna S-OFF unless absolutely neccessary (nearly bricked my phone reverting to stock last time so cba to do it again)
And I've search 'adfree not working' and didn't get an answer for this query so don't flame me - if I'd found the answer this thread wouldn't exist. If there IS a thread detailing how to fix it then if you can direct me I'd appreciate it

OK, I'm a dumbass. Changed my search criteria and found the fix but no idea how to write it into the ROM (want everything in one ROM so don't have to flash multiple ZIPs). Anyone wanna give me a hand or is it as simple as adding it the update script?

I know there is an update.zip in the old cm6 nightly thread for setting up adfree. I think it just copied hosts to data then created the link. There's no reason why you can't add this to the end of the update.zip in your rom...but clearing data will probably break adfree so you may aswell make a second update.zip for adfree so you can flash it when you clear data.
Sent from my HTC Desire using XDA App

Use root tools to manage not to get ads from the integrated ad blocker.
Sent from my LeeDroided Desire HD

I've rooted (last night) on my Desire using unrevoked 3.21 - S-On still - installed AdFree and it didn't seem to do anything - still seem to be getting Ads - is this because I need to S-Off then or install a custom rom instead of the standard 2.29.405.5?

You either need S-OFF or use a ROM which includes the symlink from the /system/etc location to your SD card. I can't work out how to include it in a ROM myself but others have successfully

Can't you push the hosts file using ADB?

ok I thought as much from my googling...
is there a 'newbie's guide to S-Off' anywhere obvious?
Just started downloading the ISO from here: http://alpharev.nl/ just couldn't see any instructions...
cheers

EddyOS said:
You either need S-OFF or use a ROM which includes the symlink from the /system/etc location to your SD card. I can't work out how to include it in a ROM myself but others have successfully
Click to expand...
Click to collapse
just use this symlink in ur Rom script.
for old update-script...
Code:
symlink /data/data/hosts SYSTEM:etc/hosts
for new edify updater-script
Code:
symlink("/data/data/hosts", "/system/etc/hosts");
for manually...
Boot into recovery. mount sdcard, system n data then
cp /sdcard/hosts /data/data/hosts
rm /system/etc/hosts
ln -s /data/data/hosts /system/etc/hosts
but u need to have hosts file in ur sdcard for that...

symlink("/data/data/hosts", "/system/etc/hosts");
I did that the other way round - d'oh!!

This happens if I run a check on the update-script:
66/120: symlink /data/data/hosts SYSTEM:etc/hosts
>> WARNING: data/data/hosts not found in working folder
And then I get this if I do add it:
66/120: symlink /data/data/hosts SYSTEM:etc/hosts
>> ERROR: system/etc/hosts found in working folder
EDIT: Sorted, deleted from /system/etc

EddyOS said:
This happens if I run a check on the update-script:
66/120: symlink /data/data/hosts SYSTEM:etc/hosts
>> WARNING: data/data/hosts not found in working folder
And then I get this if I do add it:
66/120: symlink /data/data/hosts SYSTEM:etc/hosts
>> ERROR: system/etc/hosts found in working folder
EDIT: Sorted, deleted from /system/etc
Click to expand...
Click to collapse
No.No...
just remove hosts file from system/etc and place ur ad block hosts file in data/data folder thats all...n symlink it
Code:
symlink /data/data/hosts SYSTEM:etc/hosts
if u trying to run 9. check update-script for errors than u always getting this error...
Code:
66/120: symlink /data/data/hosts SYSTEM:etc/hosts
>> WARNING: data/data/hosts not found in working folder
forget it...

Related

[GUIDE] 11/22/2010 - Restore Swype after upgrading to CyanogenMod

If you were like me, you rushed right into installing CyanogenMod. Whoops, found out there is no swype installed. What to do?
Hopefully you made a nandroid backup like me. I didn't want to do a full nandroid restore just to extract the files. So I did this...
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
UPDATED 11/22/2010 - Okay, some people have requested a "newbie friendly" solution. I have created an APK which will help automate this procedure, without the need for ADB. If you have already applied CyanogenMod, then use this APK to select an older Clockwork Backup that has your licensed Swype. It will then extract and install the files for you. I have only tested on the G2.
http://www.mediafire.com/?j7dnv321ej0mrch
I'll possibly do some updates to:
a) cache swype for future installs (to make restores super quick)
b) add other extractions of 'your' saved files (i.e. google apps)
c) add more options for handling cache/files/etc.
I hope this helps. Enjoy!
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
# --------------------------------------------------------------------------------------------
# How to recover your swype files from your nandroid backup
# Quick and dirty extract
# Prepare a staging area on your computer
mkdir nandtmp
cd nandtmp
# Copy your old nandroid (pre CM) backup to your staging area..........
# i.e. /androidbackups/clockworkmod/backup/2010-11-01.02.02.02
cp $WHEREVER_OLD_IMAGE_IS/system.img .
# extract files...
unyaffs system.img
adb remount
# Push the swype files back to your Android device
adb push ./system/lib/libSwypeCore.so /system/lib/
adb push ./system/app/Swype.apk /system/app/
# Some users have had issues with not seeing Swype in the options (possibly non read/write system?), so they just installed the APK. If you install it, make sure the lib file has been pushed first.
# i.e. adb install /sdcard/Swype.apk
# Update permissions for good measure (may not be needed)
chmod 644 /system/app/Swype.apk
chmod 644 /system/lib/libSwypeCore.so
# I rebooted, but have heard reports that it is not necessary
adb reboot
# Now in Menu>Settings:Language & keyboard unselect the Android keyboard and make sure Swype keyboard is checked.
A similar process can be done directly on your phone.
# --------------------------------------------------------------------------------------------
Hope that helps others restore Swype (or other files they desire) without having to do a full Nand restore.
-oldsk00lz
getting force close on swype as soon as I uncheck the android keyboard, not a huge deal but I do kinda miss swype
ranyvern said:
getting force close on swype as soon as I uncheck the android keyboard, not a huge deal but I do kinda miss swype
Click to expand...
Click to collapse
Did you push libSwypeCore.so to /system/lib yet?
For some reason it still doesn't show up in the keyboard list, any idea why?
Sent from my T-Mobile G2 using XDA App
Ok, what you're supposed to do is, you actually have to install the swype.apk. its not enough to copy it to the /system/app directory adb install Swype.apk or use root file explorer click on the apk file and choose install.
Sent from my T-Mobile G2 using XDA App
or you can open up cyanogenmod(unzip) and download a stock g2 rom and then just put the files in the proper places, then zip cm again and flash(i did this all from my phone ast night because i was too lazy to go to the computer)
have you tried to go to swype.com and signing up for there beta testing. Not sure if still open but does not hurt to try. I reinstall from the beta testing website and is working great on CM6.1 on my G2
k50aker said:
For some reason it still doesn't show up in the keyboard list, any idea why?
Click to expand...
Click to collapse
Be more specific. What have you done so far? Did you go into Settings > Keyboard and enable Swype yet?
I tried a few times before but could never get this dumb unyaffs to work for me.
i get
Microsoft Windows XP [Version 5.1.2600]
C:\g2orgsys>unyaffs systemg2.img
28852 [main] unyaffs 3212 _cygtls::handle_exceptions: Exception: STATUS_ACCESS
_VIOLATION
30677 [main] unyaffs 3212 open_stackdumpfile: Dumping stack trace to unyaffs.e
xe.stackdump
348883 [main] unyaffs 3212 _cygtls::handle_exceptions: Exception: STATUS_ACCESS
_VIOLATION
375003 [main] unyaffs 3212 _cygtls::handle_exceptions: Error while dumping stat
e (probably corrupted stack)
Idk im pretty lazy sometimes, if you can provide some help on this, i would GREATLY appreciate it.
oh and I tried, quickly, to get the emulator working but failed! Im sure its probably something ez I missed. :/
Stryder5 said:
Be more specific. What have you done so far? Did you go into Settings > Keyboard and enable Swype yet?
Click to expand...
Click to collapse
Yea, it wasn't there, again, in my case pushing it in to the /app folder did NOT work, I had to intall the apk maually like any other app. Of course only after pushing the lib file.
adb push libSwypeCore.so /system/lib
adb install Swype.apk
Unyaffs is supposed to work on windows? I didn't know that. I use linux, you sould try it and get used to it, it would save you a lot of trouble.
Sent from my T-Mobile G2 using XDA App
k50aker said:
Yea, it wasn't there, again, in my case pushing it in to the /app folder did NOT work, I had to intall the apk maually like any other app. Of course only after pushing the lib file.
adb push libSwypeCore.so /system/lib
adb install Swype.apk
Unyaffs is supposed to work on windows? I didn't know that. I use linux, you sould try it and get used to it, it would save you a lot of trouble.
Sent from my T-Mobile G2 using XDA App
Click to expand...
Click to collapse
Hmmm... I saw the swype in the settings after doing adb pushes and a reboot.
In reality, I had unchecked both Android keyboard, and Swype keyboard. Then went to a text field, and got a request for Android input. I then went back into settings and checked Swype, and then it just worked. I didn't need to install the APK. For those not seeing swype as an option, did you confirm that system was remounted and that files were copied? Did you reboot?
As for unyaffs, I was lazy. I just downloaded a binary for OSX from here: http://forum.xda-developers.com/showthread.php?p=7931772 . I haven't tried a Windows version of unyaffs.
-oldsk00lz
k50aker said:
Unyaffs is supposed to work on windows? I didn't know that. I use linux, you sould try it and get used to it, it would save you a lot of trouble.
Sent from my T-Mobile G2 using XDA App
Click to expand...
Click to collapse
thats kinda sucks. lil more trouble then I was hoping for but I got a few LiveCDs somewhere.
How hard would it be to get this running through adb shell, on the phone? lol
wilnotdie said:
thats kinda sucks. lil more trouble then I was hoping for but I got a few LiveCDs somewhere.
How hard would it be to get this running through adb shell, on the phone? lol
Click to expand...
Click to collapse
wilnotdie - You should be able to do this directly on your phone, as well. Of course, you would need to mount your system read/write and cp files versus adb push.
i.e.
mount -o rw,remount -t ext3 /dev/block/mmcblk0p25 /system
cp /sdcard/nandtmp/system/lib/libSwypeCore.so /system/lib/libSwypeCore.so
cp /sdcard/nandtmp/system/app/Swype.apk /system/app/Swype.apk
Hope that helps.
-oldsk00lz
oldsk00lz said:
wilnotdie - You should be able to do this directly on your phone, as well. Of course, you would need to mount your system read/write and cp files versus adb push.
i.e.
mount -o rw,remount -t ext3 /dev/block/mmcblk0p25 /system
cp /sdcard/nandtmp/system/lib/libSwypeCore.so /system/lib/libSwypeCore.so
cp /sdcard/nandtmp/system/app/Swype.apk /system/app/Swype.apk
Hope that helps.
-oldsk00lz
Click to expand...
Click to collapse
Oh mybad, not that way. Was thinking of using the phone as my linux box instead of a pc. In theory it should work, just need to compile for use on the phone?
But Im guessing its not gonna be this ez lol
I didn't do any ADB pushes I just used root explorer to move the libswype file to lib directory then used the installer on the root explorer to install and it loaded right up for me. Only problem I'm getting is the double tap to edit isn't working now for some reason.
I pulled the files from the ota_root_noboot.zip from
http://forum.xda-developers.com/showthread.php?t=836042
Okay here is what I did and it worked. Using SU File manager (found in the market if you search "root explorer") and on the stock ROM, copy the lib and apk files from /system/app and /system/lib. I copied them to the root of my sd card. Wipe everything and install CM and the addon. Grab SU File manager again and find the lib file on your SD card. copy it. There are two little buttons on the top of SU File manager with an S and a D. I pressed both of them to mount system and data as read/write. Go to system/lib and paste the lib file. Verify that it is there and since there are so many files sort by size its like 998kb. Then just use SU File Manager or astro or whatever to find Swype.apk on your sd card. Install it from there. With Astro click it and "open app manger." Then go to keyboard settings and enable it as an input method. Go to swype settings and it should not FC if you did this stuff correctly. Set your settings and enjoy! Oh yea dont forget to uninstall and refund SU File manager
Hey Jkoenig00 did you have any issues with the double tap to edit?
Worked flawlessly and now I have swype running on CM. This should be stickied or something!
So for those of us who don't know what ADB is or how to use it...
are we screwed?
Is there a noob friendly method?
convolution said:
So for those of us who don't know what ADB is or how to use it...
are we screwed?
Is there a noob friendly method?
Click to expand...
Click to collapse
You can use root explorer. Download one of the stock roms. Access it through root explorer and copy the 2 files from the stock rom folders to its respective folder on your device. Then install the apk from within root explorer. Set everything up in your keyboard settings and your golden. Can be done in minutes.
Sent from my T-Mobile G2 using XDA App

flashplayer 10.3 not working on rooted evo

my flashplayer 10.3 isnt working never did,on rooted 2.2 evo please help,, thank you!!
Uninstall the update then uninstall flash player (the one that was part of the rom). Then navigate to system/lib and delete libflashplayer.so (I think thats the name of it but I forget) if it is still there. Then download and install flash from the market. That should fix it.
lovethyEVO said:
Uninstall the update then uninstall flash player (the one that was part of the rom). Then navigate to system/lib and delete libflashplayer.so (I think thats the name of it but I forget) if it is still there. Then download and install flash from the market. That should fix it.
Click to expand...
Click to collapse
when i try to deleted the lidflashplayer.so it say cannot be deleted the file system is ready-only, need help....
rotzie said:
when i try to deleted the lidflashplayer.so it say cannot be deleted the file system is ready-only, need help....
Click to expand...
Click to collapse
You can use either root explorer or terminal emulator. You would need titanium backup to uninstall the flash that came with the rom.
If you don't have root explorer here are the terminal commands. Press enter after each command.
Code:
su
mount -o rw,remount /dev/block/mtdblock3 /system
cd system/lib
ls
After entering ls you will see a list of all the files in this directory. Look through it and find the one file that says libflashplayer.so
If you have libflashplayer.so then do these next commands
Code:
rm libflashplayer.so
mount -o ro,remount /dev/block/mtdblock3 /system
If you don't have libflashplayer.so just issue the mount command to set the system back to read-only (mount -o ro,remount /dev/block/mtdblock3 /system).
i have rootexplorer and i got i deleted,did not use titanium,but my 10.3 player sits in my apps just saying uninstalling.no date,no force stop nothing....
I had the same problem.. I deleted the app and went to explorer and deleted the folder and reinstalled.. works fine now

after the 1 click root - not able to mount some directories in root explorer?

I used the post to install the one click root for the samsung epic 4g (sprint), and it appears to have worked. However - after entering root explorer, only some of the directories allow me to edit files. I click the remount as r/w button but nothing happens. Any thoughts?
sedric1 said:
I used the post to install the one click root for the samsung epic 4g (sprint), and it appears to have worked. However - after entering root explorer, only some of the directories allow me to edit files. I click the remount as r/w button but nothing happens. Any thoughts?
Click to expand...
Click to collapse
Are you sure you granted root permissions to root explorer when it first ran? Run the superuser app from the app drawer and see if root explorer is on the list of apps that are allowed root permission.
I just tried v2.17.2 and it works fine. I tried changing the permissions on /system/xbin/busybox, it said filesystem mounted ro, then I press the mount rw button and redid the permission change, this time it worked no problem.
Thanks for your response-
yes, when i ran root explorer it asked if i wanted to grant superuser and i said yes. some folders allow it to remount, but - say the /system/bin folder - it doesnt allow it at all.
for further background, i used the automated instructions here for my root:
http://forum.xda-developers.com/showthread.php?t=1342728
i did option A like 5 times and also did option C (as i have EK02).
When opening root explorer it tells me that i have super user permissions. one thing to note- if i go to /system/xbin, i do not see a busybox directory. is there something else i should be installing?
in fact, i cant mount anything under the system directory or sub directories, but above that, i was able to change to r/w mode. i could also mount the /vendor directory right beside the /system directory...
If you were able to remount "/" as r/w then the problem isn't with root. That is basicly an "I'm a little bit pregnant situation" Either you are or you aren't.
Now if you weren't able to get root in the first place, then I'd look at the root.
As to busybox, there is no directory. There should be a file /system/xbin/busybox Also there should be a bunch of symlinks from various apps it supports to busybox.
I see - yea i did validate that busybox is not allowing for a mount or any type of change on that file/directory including busybox but the file is present. any suggestions on what else may be locking down this system directory?
I don't know if root file explorer is implemented it's own concept of ro/rw to protect you from making mistakes or it is using the system facilities. If it is using the system facilities, then once you remount /system as rw, then everything under /system is automatically rw. It is all the same partition.
I would try it from "adb shell" (do not type $ or # symbols)
Code:
$ su
# mount -o remount,rw /system /system
# cd /system/xbin
# chmod 755 busybox
If it lets you do that with no errors, then you have remounted /system/xbin as rw and the problem is with root file explorer. For that, you'd have to check with them or someone more well-versed in why that might be failing.
i appreciate your help
I went off googling the adb stuff/installed it and java's jdk stuff. then figured out how to run that adb shell stuff and validated that it worked (permissions were changed in places that this app didnt allow). knowing that the problem is actually with root explorer helps a ton.. as I just assumed it was working

How to delete script from init.d

Hello all, I have the latest "]RUNNYCRUX RSK TEAM ★ with AMAZE CAM" rom on my phone. I'm trying to enable logcat because I need to to debug an application I'm developing. I have commented all parts in external scripts that deal with logcat but there is one left in init.d. the 02Logger which does an rm on the logcat file. How can I disable or delete this script? I get a "read only file system" when I'm trying to delete it.
Is it possible or do I have to delete it before flashing the rom?
U can simply remove it from .zip before flashing ROM, or use file explorer with SU rights like Root Explorer to mount system r/w and remove the script within ROM.
This is not forum for asking questions btw, it's development section..
Code:
su
mount -o remount rw system
cd system/etc/init.d
rm (not sure if have to include -rf) 02logger
Done
Sent from my HTC Desire using xda app-developers app

[method] change play store download location

Hi guys, today i am here to tell you a method only tested on a galaxy y, but i hope it will work for all. this is a method to change the download location for play store.
WARNING!!!
1. WARRANTY IS NOW VOID.
2. NOT MY PROBLEM IF SOME APP FAIL.
3. PLEASE, PLEASE, PLEASE DO A NANDROID BACKUP BEFORE THIS.
This is a simple code but it needs root for sure. now the necessities are as follows:
1. A complete nandroid backup
2. Root Permissions
3. Any terminal emulator. e.g https://play.google.com/store/apps/details?id=hecticman.jsterm
4. You need to know the default download location and the mount point of sd card( if that is where you want the new download location )
Now let's start.
Just know this that mnt/sdcard will have to be replaced by your sdcard mount point and data/app will have to be replaced by the default download location. i underlined them for easy understanding.
NOT MY PROBLEM IF THIS FAILS AND YOUR PLAY STORE CRASHES. JUST DO A NANDROID RESTORE.
THERE WILL ALREADY BE A $ AT START SO U DON'T HAVE TO PUT IT.
$ su
# mkdir /mnt/sdcard/playstore
# cp -r /data/app/* /mnt/sdcard/playstore
# rm -rf /data/app
# ln -s /mnt/sdcard/playstore /data/app
Click to expand...
Click to collapse
what the code does:
1. Grant super user permissions
2. Make a directory in sdcard named playstore.
3. Copy all items (recursively) from data/app to sdcard/playstore
4.Symlink the new location to fake the original.
Hitting Thanks can help.
and once again PLEASE BACKUP BEFORE THIS AND RESTORE IF NOT SUCCESSFUL.
This is based on the code used by link2sd.
Could you please double check your code fragments?
For me it looks, like you create a directory "playstore", but then copy to a directory "playstore-temp", which will most like not exist at that moment.
The ln you're using can't realy work as long as the /data/app directory is still in place... so you would first need to delete /rename it.
Just my 2¢
thanks dude
DThought said:
Could you please double check your code fragments?
For me it looks, like you create a directory "playstore", but then copy to a directory "playstore-temp", which will most like not exist at that moment.
The ln you're using can't realy work as long as the /data/app directory is still in place... so you would first need to delete /rename it.
Just my 2¢
Click to expand...
Click to collapse
looks like i was drunk making so much mistakes . corrected it.
It's not so simple if you use Link2SD. If you link some apps to sdext partition, some files in /data/app are symlinks which cannont be copied to /mnt/sdcard/playstore as it's FAT32. You have to try to symlink /app/data to folder on sdext partition. Create a folder /data/sdext2/playstore, copy /data/app/* there, delete /data/app and symlink /data/sdext2/playstore as /data/app. Sdext partition uses linux filesystem and all symlinks should work properly. I haven't tested it yet, but will do in a minute.
EDIT:
It doesn't work with Link2SD. Phone hangs on boot. It's probably cause Link2SD app must be directly in internal memory (so in real /data/app, not symlinked). I'll try to symlink /data/data or /data/dalvik-cache to save some internal memory but I doubt it'll work.

Categories

Resources