diff --git a/Makefile b/Makefile index 8145a96..3cdaa00 100644 --- a/Makefile +++ b/Makefile @@ -24,6 +24,9 @@ install.radare.projects: ./$< $@ sha1sum -c $@.sha1 +%.img.enc: %.encrypt %.img + ./$< $(basename $<).img $@ + # keep intermediate files .PRECIOUS: %.img.orig @@ -43,3 +46,5 @@ mec-tools/mec_encrypt: mec-tools/Makefile # - most of these dependancies could be automatically calculated x220.8DHT34WW.extract: 8duj27us.iso.orig x230.G2HT35WW.extract: g2uj23us.iso.orig mec-tools/mec_encrypt +x230.G2HT35WW.encrypt: mec-tools/mec_encrypt + diff --git a/x230.G2HT35WW.encrypt b/x230.G2HT35WW.encrypt new file mode 100755 index 0000000..8b8f650 --- /dev/null +++ b/x230.G2HT35WW.encrypt @@ -0,0 +1,24 @@ +#!/bin/bash +# +# Quick and dirty extracter to get the EC image out of the iso file +# +# TODO: +# - a tool that is portable to Windows +# - should output dependancy information + +INP="$1" +if [ -z "$INP" ]; then + echo Need input filename + exit 1 +fi +shift + +OUT="$1" +if [ -z "$OUT" ]; then + echo Need output filename + exit 1 +fi +shift + +cd mec-tools && ./mec_repack "../$INP" "../$OUT" +