VectorLinux
November 29, 2014, 01:28:04 am *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Visit our home page for VL info. To search the old message board go to http://vectorlinux.com/forum1. The first VL forum is temporarily offline until we can find a host for it. Thanks for your patience.
 
Now powered by KnowledgeDex.
   Home   Help Search Login Register  
Please support VectorLinux!
Pages: [1]
  Print  
Author Topic: UNetbootin  (Read 2878 times)
no2thesame
Packager
Vectorite
****
Posts: 136


« on: March 28, 2009, 02:42:13 pm »

Could an experienced packager have a look at this. I failed in my attempt at packaging UNetbootin myself, it is work for someone with more packaging savvy. The source file  is not "standard".

There appears to be a real need for something to simplify the installation of VL on computers without CD drives and to create bootable VL Live USB sticks. Hopefully this UNetbootin does that:
Homepage:
http://sourceforge.net/projects/unetbootin/
http://unetbootin.sourceforge.net/

Thanks,
no2
« Last Edit: March 28, 2009, 10:26:21 pm by no2thesame » Logged
niiler
Member
*
Posts: 26


WWW
« Reply #1 on: April 10, 2009, 09:03:17 am »

I've actually started work on this.  I have some code which Windows users would like to use, but which only runs on Linux.  We've tried porting it to Windows, but the Windows API we need (it's Mozilla - nsIProcess() ) is broken and has been for years as we've found out.  So the agreed-upon solution is to provide the code in LiveCD or USB-disk form. 

While my live CD/thumbdrive image would be a bit different from the VL standard (it would also include the mozilla-based apps along with graphicsmagick and its dependencies), presuming that all goes well, I will be essentially compiling unetbootin on VL as a VL-6.0 package, and I would be happy to document my steps so that someone else can create a clean build for distribution.

That said, I'm a newbie so far as creating live distros, so... although the package would be compile for VL-6.0, the live CD would be based on VL-5.9, since this is the latest live CD available.

I'll post more later as I have either succeeded or failed to compile this.
Logged
niiler
Member
*
Posts: 26


WWW
« Reply #2 on: April 10, 2009, 09:46:43 am »

Right... so here's the kludge (sans checkinstall or vlpackager)

1) Download the sources. 
2) Create a directory such as Unetbootin-319. 
       >mkdir Unetbootin-319
This is necessary because the source packager created a tar-bomb which unpacks into the current directory.
3) Move the source tarball into the directory you've created.
       >mv unetbootin-source-319.tar.gz Unetbootin-319/
4) Change into the directory
       >cd Unetbootin-319
5) Unpack the source:
       >tar -xzvf unetbootin-source-319.tar.gz
6) Ensure that you have qt4 installed (use slapt-get if necessary)
7) Run the INSTALL script provided.  This really just compiles the code:
       >./INSTALL
You'll see a bunch of stuff like this:
Quote
Updating 'unetbootin_be.ts'...                                                                                     
    Found 137 source text(s) (0 new and 137 already existing)                                                       
Updating 'unetbootin_de.ts'...                                                                                     
    Found 137 source text(s) (0 new and 137 already existing)                                                       
Updating 'unetbootin_es.ts'...                                                                                     
    Found 137 source text(s) (0 new and 137 already existing)                                                       
Updating 'unetbootin_fr.ts'...                                                                                     
    Found 137 source text(s) (0 new and 137 already existing)                                                       
Updating 'unetbootin_he.ts'...
and then the usual make-noise:
Quote
/usr/lib/qt4/bin/uic unetbootin.ui -o ui_unetbootin.h                                                               
g++ -c -pipe -O2 -Wall -W -D_REENTRANT -DNOSTATIC -DNOSTATIC -DQT_NO_DEBUG -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/lib/qt4/mkspecs/linux-g++ -I. -I/usr/lib/qt4/include/QtCore -I/usr/lib/qt4/include/QtCore -I/usr/lib/qt4/include/QtNetwork -I/usr/lib/qt4/include/QtNetwork -I/usr/lib/qt4/include/QtGui -I/usr/lib/qt4/include/QtGui -I/usr/lib/qt4/include -I. -I. -I. -o main.o main.cpp
...
It shouldn't take more than a couple of minutes to compile since everything seems to go into a single executable file: unetbootin

At this point you can run it as root.  However, you are interested in creating a package.

Cool  Create a directory, call it anything you'd like.  I choose "package".
     >mkdir package

9)  Now build up the directory structure you would like the executable to live in:
     >mkdir package/usr
     >mkdir package/usr/bin

10) Now copy unetbootin to the directory package/usr/bin
     >cp unetbootin package/usr/bin/

11) Create an install directory (yes, we're doing this old-school)
     >mkdir package/install

12) Using your favorite text editor, create a slack-desc file that looks something like this.  Spacing and
number of lines matter.  See http://www.linuxpackages.net for a howto.

Quote
unetbootin: UNetbootin 319 Create bootable USB thumbdrive
unetbootin:
unetbootin: UNetbootin allows you to create bootable Live USB drives for a
unetbootin: variety of Linux distributions from Windows or Linux, without
unetbootin: requiring you to burn a CD. You can either let it download one
unetbootin: of the many distributions supported out-of-the-box for you, or
unetbootin: supply your own Linux .iso file if you have already downloaded
unetbootin: one or your preferred distribution is not on the list.
unetbootin: Homepage: http://unetbootin.sourceforge.net/
unetbootin: Author: Geza Kovacs
unetbootin: Package Created By: Tim Niiler

13) Copy this file into package/usr/install/ .  Since I created it in my Unetbootin-319 directory, I typed:
     >cp slack-desc package/usr/install/

14) Change into your package directory
     >cd package

15) Become root
     >su

16) Type:
     > makepkg unetbootin-319-i586-xxx.tgz
where xxx is an identifier.  If for VectorLinux 6.0 it should be something like vl6.  If for personal use, it is generally taken to be your initials, and which iteration of the package you have tried to build.  In my case, this is 1tan.  You will see:

Quote
Searching for symbolic links:

No symbolic links were found, so we won't make an installation script.
You can make your own later in ./install/doinst.sh and rebuild the
package if you like.

This next step is optional - you can set the files and directories in
your package to some sane permissions. If any of the files or dirs in
your package have special permissions, then DO NOT reset them here!

Would you like to reset all directory and file permissions and set
their ownerships to root:root? [y/N]

17) Select y for yes.

18) You'll see a bunch of makepkg noise, and then if all is well in the world, you'll have a package that looks like this:
     unetbootin-319-i586-vl6.tgz

which can be installed via "installpkg unetbootin-319-i586-vl6.tgz".

19)  In my case I typed:

      >installpkg unetbootin-319-i586-1tan.tgz
and then saw:
Quote
.-----.-----------------------------------------------------------------------.
| 1/1 | Installing unetbootin-319-i586-1tan.tgz                               |
'-----'-----------------------------------------------------------------------'

.-----------------------------------------------------------------------------.
| UNetbootin 319 Create bootable USB thumbdrive                           |
|                                                                                            |
| UNetbootin allows you to create bootable Live USB drives for a         |
| variety of Linux distributions from Windows or Linux, without            |
| requiring you to burn a CD. You can either let it download one          |
| of the many distributions supported out-of-the-box for you, or         |
| supply your own Linux .iso file if you have already downloaded         |
| one or your preferred distribution is not on the list.                         |
| Homepage: http://unetbootin.sourceforge.net/                              |
| Author: Geza Kovacs                                                                |
| Package Created By: Tim Niiler                                                   |
'-----------------------------------------------------------------------------'
Now understand that this method of building the package will not deal with dependencies.  Perhaps someone who is a bit better versed in including dependencies could highlight how to deal with this.  Also, in my limited research, it seems that one could modify the UNetbootin source to point to the VL 5.9 Live iso for download so that the image would not have to live locally for it to be installed.  Also, a *runtime* dependency seems to be 7zip, although the program loaded without it.  I have also not yet tried to create a bootable thumbdrive yet.  I have only created a package without either checkinstall or vpackager.

Good luck, and happy Vectoring!

Tim Niiler
Logged
no2thesame
Packager
Vectorite
****
Posts: 136


« Reply #3 on: April 11, 2009, 04:38:54 pm »

Thanks for the hard work, Tim. Clear explanatory posts like this help the beginners like me. Even thought there are dozens on the web, it's good to have VL specific ones.

6) Ensure that you have qt4 installed (use slapt-get if necessary)


This is the real sticking point as qt4 messes with the vanilla VL 6.0 install. So I don't think this will end up being packaged for 6.0 std.


That said, I'm a newbie so far as creating live distros, so... although the package would be compile for VL-6.0, the live CD would be based on VL-5.9, since this is the latest live CD available.

So it only works for live CDs... it wouldn't have done what I wanted anyway. I wanted to get a bootable VL 6 STD iso on a USB stick.

I'm not sure how ruien did it here:
http://forum.vectorlinux.com/index.php?topic=7542.msg53515#msg53515

Thanks again
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!