[Galaxy S III General] the_ape:
You need to pull the various frameworks from the device, and put them in the right place. This is all documented elsewhere on the site, but for quickness sake, here's a down and dirty.

Download the 7Z Below (latest versions of aapt etc from http://xdaforums.com/showthread.php?t=1792937), unpack them somewhere. Make sure Jave JRE is installed.

To pull from device, plug the Phone in then

Goto unpack folder

Let's get the frameworks from the device, so plugin the device, and ADB Devices and make sure you get a deviceID back.

pull_framework.bat

pull_twframework.bat

Now get the frameworks installed

set_framework-res.bat

set_twframework.res.bat

Let's get the APK we want to work with, so....

adb pull /system/app/SecSettings.apk .\apk\SecSettings.apk

OK, file in the right place, so let's get it unpacked to work with.

apktool d apk\SecSettings.apk working\SecSettings

That will take a few minutes, as it's got to sort out the framework dependencies etc, so give it a second or two. It should then look a little like the following

I: Baksmaling...

testI: Loading resource table...

I: Loaded.

I: Decoding AndroidManifest.xml with resources...

I: Loading resource table from file: C:\Users\YourUserName\apktool\framework\1.apk

I: Loaded.

I: Decoding file-resources...

I: Decoding values */* XMLs...

I: Done.

I: Copying assets and libs...

Now lets edit the smali for the fix (thanks to exscape for this, so click his thanks button)

notepad .\working\SecSettings\smali\com\android\settings\dormantmode\DormantModeNotiReceiver.smali

<CTRL>-F notificationCreate

Find Next one

change invoke-virtual {p0, p1}, Lcom/android/settings/dormantmode/DormantModeNotiReceiver;->notificationCreate(Landroid/content/Context;)V

to

#invoke-virtual {p0, p1}, Lcom/android/settings/dormantmode/DormantModeNotiReceiver;->notificationCreate(Landroid/content/Context;)V

and a bit further down

change invoke-virtual {p0, p1}, Lcom/android/settings/dormantmode/DormantModeNotiReceiver;->notificationClear(Landroid/content/Context;)V

to

#invoke-virtual {p0, p1}, Lcom/android/settings/dormantmode/DormantModeNotiReceiver;->notificationClear(Landroid/content/Context;)V

OK, edit done, save and back to the command prompt

start .\apk

Open the APK in 7-Zip/WinRar/Whatnot

Select the AndroidManifest.xml and the META-INF folder, and extract them to the working folder

We have all our bits, so let's put it back together in a usable APK

First we need to create an unsigned build (without the real manifest and META-INF)

apktool b working\SecSettings built\SecSettings-Unsigned.apk

This will take a while to run, as it's compiling everything it needs, should look a bit like this

: Checking whether sources has changed...

I: Smaling...

I: Checking whether resources has changed...

I: Building resources...

I: Building apk file...

Right, now we need a signed version, so copy the manifest XML and META-INF folders to \build\apk in the SecSettings folder.

move .\working\AndroidManifest.xml .\working\SecSettings\build\apk

move .\working\META-INF .\working\SecSettings\build\apk

Let's now compile the nice signed version, this will take moments, as it's just integrating the Manifest with the already compiled stuff.

apktool b working\SecSettings built\SecSettings.apk

And there we are, job done.

Copy to device in any way that you want, easiest is probably

adb push .\built\SecSettings.apk /system/app/SecSettings.apk

Remember that will overwrite the original (but you have a backup in the APK folder remember), just launch settings now on the device and you should be good to go.

Having said that, easier just to flash the zip ;)