KanoComputing / kano-burners

SD Card burner for OSX
GNU General Public License v2.0
12 stars 11 forks source link

Windows fixes #35

Closed radujipa closed 9 years ago

radujipa commented 9 years ago

This PR includes the following changes:

Windows 7, 8, 8.1 burning process fix https://github.com/KanoComputing/kano-burners/issues/32 This is done by splitting the pipe between 7zip and dd. This intrinsically implies that the minimum required MB is raised to 3.1GB for all windows versions. Another benefit of this fix is that src/windows/disk.py is now much simpler and requires less steps to prepare the disk for burning. Much of the unused code was therefore removed.

Building process refactored The 3 steps required to build the app have now been incorporated into a single script in build/build.py. The script works on all platforms and the entire process now requires a simple python build.py. Should make life much easier. The built app can be found in the project folder /build/app/Kano Burner. Like before, only the .app \ .exe are to be distributed - rest is PyInstaller debugs. Note that building on Linux is still a problem because of PyInstaller. I have got it to work somehow once, but lost the Ubuntu Live USB to corruption before saving it.. There may still be hope..

Debug feature improved The debugger used throughout the app is now either printing to a file when running from PyInstaller bundle mode, or to stdout when running from source. This allows for debugging the bundle (not previously really possible), but also may prove useful if we ever decide to make a bug reporting feature like in Kano OS. This may be useful until the project reaches a level of maturity.

Temp directory replacement Not as significant, but it lead to much cleaner code in the end. Now, when running from source, the app will make a temp directory in the project folder (is ignored in .gitignore), and when running from bundle, the directory is created in the folder which holds all resources (see _MEI* in PyInstaller docs). I was hoping this may fix https://github.com/KanoComputing/kano-burners/issues/23, but it only does so for OSX. On Windows the archive still remains.

Successful Testing All features have been tested natively in OSX 10.10.2, Ubuntu Live 14.04 LTS, Windows 7, and Windows 8.1. Further testing was done in VirtualBox on Ubuntu 14.04 LTS, Windows 7, Windows 8, and Windows 8.1 on USB drives. (VB and Mac SD card reader don't want to play together)

radujipa commented 9 years ago

Unfortunately, I am now getting an error on Windows Error reading file: 87 The parameter is incorrect after I've seen it work many times. The burning command works just fine from command line, but the error pops up in the app. Perhaps I am doing something strange at the moment - will look into it some more.

radujipa commented 9 years ago

Tracked the problem to something silly (of course).. The problem is that download.py#L123 modified the filename, so the os path became burn.py#L44 and it was also the same path used to burn, not the path to the extracted .img burn.py#L49. The burning process failed as a result at about 25% because I was burning the archive.. I will fix this once the servers are restored.

radujipa commented 9 years ago

Moving this PR to https://github.com/KanoComputing/kano-burners/pull/36