patchrom icon indicating copy to clipboard operation
patchrom copied to clipboard

KeyError: "There is no item named 'SYSTEM/build.prop' in the archive"

Open pyroemaniac opened this issue 12 years ago • 17 comments

I've worked out all of the smali errors and now I am stuck at the end with this error:

Sign target files rewriting SYSTEM/build.prop: Traceback (most recent call last): File "/home/josh/patchrom/tools/releasetools/sign_target_files_apks", line 354, in main(sys.argv[1:]) File "/home/josh/patchrom/tools/releasetools/sign_target_files_apks", line 341, in main SignApks(input_zip, output_zip, apk_key_map, key_passwords) File "/home/josh/patchrom/tools/releasetools/sign_target_files_apks", line 162, in SignApks new_data = RewriteProps(data) File "/home/josh/patchrom/tools/releasetools/sign_target_files_apks", line 194, in RewriteProps assert len(pieces) == 5 AssertionError Build full ota package: /home/josh/patchrom/rezound/out/fullota.zip unzipping target target-files... using device-specific extensions in . Traceback (most recent call last): File "/home/josh/patchrom/tools/releasetools/ota_from_target_files", line 846, in main(sys.argv[1:]) File "/home/josh/patchrom/tools/releasetools/ota_from_target_files", line 814, in main WriteFullOTAPackage(input_zip, output_zip) File "/home/josh/patchrom/tools/releasetools/ota_from_target_files", line 370, in WriteFullOTAPackage metadata = {"post-build": GetBuildProp("ro.build.fingerprint", input_zip), File "/home/josh/patchrom/tools/releasetools/ota_from_target_files", line 472, in GetBuildProp bp = z.read("SYSTEM/build.prop") File "/usr/lib/python2.6/zipfile.py", line 834, in read return self.open(name, "r", pwd).read() File "/usr/lib/python2.6/zipfile.py", line 857, in open zinfo = self.getinfo(name) File "/usr/lib/python2.6/zipfile.py", line 824, in getinfo 'There is no item named %r in the archive' % name) KeyError: "There is no item named 'SYSTEM/build.prop' in the archive" make: *** [fullota] Error 1

Thank you for your help in advance.

pyroemaniac avatar May 29 '12 10:05 pyroemaniac

If there is a build.prop file in other/ directory and you can find this command "cp other/build.prop $(ZIP_DIR)/system/build.prop" in your makefile, you should modify the build.prop file in other directory. Seek "ro.build.description" in build.prop, if there are not 5 items, please modify them to 5 items, there is a simple in honor project's, it is "ro.build.description=U8860-user 4.0.3 ITL41D C00B919 ota-rel-keys,release-keys". if there isn't a build.prop file in other/ directory, you should to modify the build.prop file in your stockrom.zip in the same way.

yu88my avatar May 29 '12 11:05 yu88my

i have modified to 5 items to the "ro.build.description" in build.prop and i am still receiving the same errors.

pyroemaniac avatar May 29 '12 13:05 pyroemaniac

did you modify in a wrong file? please open the build.prop in the out/target_files/SYSTEM/. if or not there are 5 items?

yu88my avatar May 29 '12 14:05 yu88my

Sent modified build.prop to your email, forgive me if i misunderstood you.

pyroemaniac avatar May 29 '12 14:05 pyroemaniac

The build.prop has sent to your emali, try it again.

yu88my avatar May 30 '12 01:05 yu88my

your build.prop worked correctly, I see what you meant now. Thank you!

The last error i run into is:

Build full ota package: /home/josh/patchrom/rezound/out/fullota.zip unzipping target target-files... using device-specific extensions in . unable to load device-specific module; assuming none Traceback (most recent call last): File "/home/josh/patchrom/tools/releasetools/ota_from_target_files", line 846, in main(sys.argv[1:]) File "/home/josh/patchrom/tools/releasetools/ota_from_target_files", line 814, in main WriteFullOTAPackage(input_zip, output_zip) File "/home/josh/patchrom/tools/releasetools/ota_from_target_files", line 398, in WriteFullOTAPackage script.FormatPartition("/system") File "/home/josh/patchrom/tools/releasetools/edify_generator.py", line 170, in FormatPartition p = fstab[partition] KeyError: '/system' make: *** [fullota] Error 1

pyroemaniac avatar May 30 '12 07:05 pyroemaniac

Please send me your recovery.fstab in your metadata dir.

yu88my avatar May 30 '12 07:05 yu88my

the problem is it just says

cat: can't open

I'm trying to extract the recovery.fstab from the recovery.img

pyroemaniac avatar May 30 '12 07:05 pyroemaniac

how do I retrieve the recovery.fstab?

pyroemaniac avatar May 30 '12 08:05 pyroemaniac

First you should find a recovery that support adb. Then: adb reboot recovery adb pull /etc/recovery.fstab

yu88my avatar May 30 '12 08:05 yu88my

I got the the fullota to build, now when I flash through recovery im stuck at htc splashscreen.

pyroemaniac avatar May 30 '12 20:05 pyroemaniac

Welcome to patchrom :)

Took me over 60 builds to get my DHD working. Run a logcat. Figure out the error. DIFF regular android smali VS your smali in the affected files. Then work from there.

iBotPeaches avatar May 30 '12 21:05 iBotPeaches

Haha yeah I was planning on pull the log when I got home, just finished my first Java class this last semester so I'm still pretty new to all of this.

pyroemaniac avatar May 30 '12 21:05 pyroemaniac

adb logcat gets stuck at - waiting for device - Is this because Im only getting to the splashscreen and not the actual boot animation?

pyroemaniac avatar May 30 '12 22:05 pyroemaniac

Unpack boot.img and add "persist.service.adb.enable=1" to the default.prop, pack this modified boot.img again ,flash the boot.img to your phone,may be worked for you.

yu88my avatar Jun 01 '12 02:06 yu88my

KeyError: "There is no item named 'SYSTEM/build.prop' in the archive" How to modify them to 5 items?

brian-zou avatar Aug 10 '13 02:08 brian-zou

hello sir i am also facing the same issue so please guide me hoiw to fix this i didnt get what to modify in build.prop

TheLazyDev avatar Sep 11 '15 15:09 TheLazyDev