import 'compile/configure' name=pk2cmd version_pk2cmd=1.21-rc1 version_devicefile=1.63.148 version=${version_pk2cmd}_${version_devicefile} download "http://ww1.microchip.com/downloads/en/DeviceDoc/PICkit2_PK2CMD_WIN32_SourceV1-21_RC1.zip" \ '6f93ede97be484ab7859626a9156a5d6' download "http://www.microchip.com/forums/download.axd?file=0;749972" \ '3983ce4f45992318c4f0037c8d1acf9f' \ "PK2DeviceFile_v$version_devicefile.zip" \ 'curl -# -L -A firefox -o {dst} {src}' extrafile "$name-$version_pk2cmd-paths.patch" _ extract "PICkit2_PK2CMD_WIN32_SourceV1-21_RC1.zip" '' \ 'unzip -qd {dst} {src}' extract "PK2DeviceFile_v$version_devicefile.zip" '' \ 'unzip -qd {dst} {src}' sed -i -e "s/%DATA%/$(safe_sed "/$dir_prefix/$dir_data/$name")/" "$name-$version_pk2cmd-paths.patch" cd pk2cmd/pk2cmd patch -p0 -i "../../$name-$version_pk2cmd-paths.patch" make linux install -Dm755 -t "$dir_install/$dir_prefix/$dir_bin" "$name" install -Dm644 -t "$dir_install/$dir_prefix/$dir_data/$name" ../../PK2DeviceFile.dat ../release/PK2V023200.hex # vim:set tabstop=4 shiftwidth=4 syntax=sh expandtab: