Martin Geisler <[EMAIL PROTECTED]> writes: Hi again,
> Since you know which tags you want you could even trim the content > of the files. Simply removing all comments, squizzing multiple blank > lines into one, and removing INSTALL, NEWS, etc. gets the zip file > down to just 41 KiB. You can actually use PHP itself for this: the commandline php has a -w option that will make it strip out all comments and whitespace. So a simple for f in *.php; do php -w $f > $f.tmp && mv $f.tmp $f; done is enough to change this wc *.php: 396 1875 12520 PelConvert.php 524 2439 16053 PelDataWindow.php 358 1598 10514 PelEntryAscii.php 274 1313 8510 PelEntryByte.php 181 919 6051 PelEntryLong.php 308 1251 8486 PelEntryNumber.php 380 1573 10670 PelEntry.php 289 1311 9362 PelEntryRational.php 598 2009 17924 PelEntryShort.php 415 1559 10915 PelEntryUndefined.php 86 393 2523 PelException.php 174 705 4775 PelExif.php 224 897 5988 PelFormat.php 1204 4155 37142 PelIfd.php 120 406 2668 PelJpegComment.php 81 374 2370 PelJpegContent.php 435 1725 13389 PelJpegMarker.php 513 2254 16266 PelJpeg.php 337 1495 9729 Pel.php 2980 14219 112656 PelTag.php 280 1229 8500 PelTiff.php 10157 43699 327011 totalt into this: 1 346 2745 PelConvert.php 1 403 3282 PelDataWindow.php 1 228 1815 PelEntryAscii.php 1 147 1165 PelEntryByte.php 1 75 740 PelEntryLong.php 1 233 1824 PelEntryNumber.php 1 219 2043 PelEntry.php 1 231 2187 PelEntryRational.php 1 1069 9282 PelEntryShort.php 1 343 2751 PelEntryUndefined.php 1 30 285 PelException.php 1 113 1097 PelExif.php 1 180 1246 PelFormat.php 1 1546 15605 PelIfd.php 1 54 450 PelJpegComment.php 1 25 214 PelJpegContent.php 1 962 7491 PelJpegMarker.php 1 466 4286 PelJpeg.php 1 167 1279 Pel.php 1 6492 52558 PelTag.php 1 255 2257 PelTiff.php 21 13584 114602 totalt So there is a total of 115 KB of PHP code in PEL. Zipping this gives you a tiny-PEL of just 33 KiB. And this is a PEL with support for all tags and features -- if you started deleting stuff in PelTag (the long textual descriptions for example) you end up with just 25 KiB... At this point I stopped torturing PEL :-) But considering how easy it is to do this automatically I will consider distributing stripped versions of PEL. Or maybe it would be better to include information in the README about how one can do the stripping oneself. -- Martin Geisler GnuPG Key: 0x7E45DD38 PHP Exif Library | PHP Weather | PHP Shell http://pel.sf.net/ | http://phpweather.net/ | http://mgeisler.net/ Read/write Exif data | Show current weather | A shell in a browser
pgpYjIJYBDQCy.pgp
Description: PGP signature