Building a .rpm file on Fedora?

Discussions related to using the OSE version of VirtualBox.
Post Reply
quickbooks
Posts: 47
Joined: 27. Apr 2013, 04:43

Building a .rpm file on Fedora?

Post by quickbooks »

How to build from trunk and make a .rpm file which I can use for installation?
Last edited by quickbooks on 11. May 2013, 03:39, edited 1 time in total.
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: How to build from trunk and make .rpm file?

Post by Perryg »

Building the rpm is close to the same as building a generic run build. You need the same packages and the rpm build packages. See the tutorial for your build environment viewforum.php?f=31

The rpm build varies but Fedora explains it well http://fedoraproject.org/wiki/How_to_cr ... PM_package

Once you have the packages and set up the build environment you start the process this way.

Code: Select all

cd /trunk/src/VBox/Installer/linux
rpm/rules binary
quickbooks
Posts: 47
Joined: 27. Apr 2013, 04:43

Re: How to build from trunk and make .rpm file?

Post by quickbooks »

Perryg wrote:Install missing openwatcom

Code: Select all

***** Checking Open Watcom *****
** Open Watcom was not found!
Note: I find that sometimes VirtualBox can't find openwatcom and I need to export the location at build.
This can be done in a build script or you can add it to configure in the trunk

Example of configure:

Code: Select all

LC_ALL=C
export LC_ALL
export WATCOM=/usr/lib/watcom
change the absolute to match your location.
Suggestion: add the above to your Fedora tutorial also.

*Edited with my location because I have rebuild it from scratch :wink:
quickbooks
Posts: 47
Joined: 27. Apr 2013, 04:43

Re: How to build from trunk and make .rpm file?

Post by quickbooks »

Code: Select all

[user@localhost vbox]$ cd src/VBox/Installer/linux
[user@localhost linux]$ rpm/rules binary
cat: /etc/distname: No such file or directory
rpm/rules:101: /home/user/vbox/src/VBox/Installer/linux/rpm/builddir/version-generated.mk: No such file or directory
cd /home/user/vbox && ./configure --odir=/home/user/vbox/src/VBox/Installer/linux/rpm         --ose       --disable-extpack
Checking for environment: Determined build machine: linux.amd64, target machine: linux.amd64, OK.
Checking for kBuild: found, OK.
Checking for gcc: found version 4.7.2, OK.
Checking for Open Watcom: found version 1.9, OK.
Checking for iasl: found version 20100528, OK.
Checking for xslt: found, OK.
Checking for mkisofs: found genisoimage 1.1.11 (Linux), OK.
Checking for pthread: found, OK.
Checking for libxml2: found version 2.9.1, OK.
Checking for libIDL: found version 0.8.14, OK.
Checking for ssl: found version OpenSSL 1.0.1e 11 Feb 2013, OK.
Checking for libcurl: found version 7.27.0, OK.
Checking for zlib: found version 1.2.7, OK.
Checking for libpng: found version 1.5.13, OK.
Checking for SDL: found version 1.2.15, OK.
Checking for X libraries: found, OK.
Checking for Xcursor: found, OK.
Checking for Xinerama: found, OK.
Checking for Xrandr: found, OK.
Checking for Xmu: found, OK.
Checking for Mesa / GLU: found version 1.4, OK.
Checking for Qt4: found version 4.8.4, OK.
Checking for Qt4 devtools: found version 4.8.4, OK.
Checking for Python support: found version 2.7.3, OK.
Checking for Java support: OK.
Checking for PulseAudio: found version 2.1.0 API version 12, OK.
Checking for static stc++ library: found, OK.
Checking for Linux kernel sources: found version 3.8.9, OK.
Checking for ALSA: found version 1.0.26, OK.
Checking for libdevmapper: found version 1.02.77 (2012-10-15), OK.
Checking for libcap library: found, OK.
Checking for compiler.h: compiler.h not found, OK.
Checking for 32-bit support: OK.
Checking for makeself: 
  ** makeself (variable makeself) not found!
Check /home/user/vbox/src/VBox/Installer/linux/rpm/configure.log for details
make: *** [rpm/configure-stamp] Error 1
[user@localhost linux]$ 
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: How to build from trunk and make .rpm file?

Post by Perryg »

Taken from the fedora tutorial.

[snip]
Since Fedora does not provide makeself I use the makeself from Debian. You need makeself and makeself-header. If you get makeself from other sources it may be called makeself.sh and you will either need to rename it or symlink the name to makeself
install makeself in /usr/bin and makeself-header in /usr/share/makeself (you need to create the makeself folder)
[/snip]
quickbooks
Posts: 47
Joined: 27. Apr 2013, 04:43

Re: How to build from trunk and make .rpm file?

Post by quickbooks »

Perryg wrote:Taken from the fedora tutorial.

[snip]
Since Fedora does not provide makeself I use the makeself from Debian. You need makeself and makeself-header. If you get makeself from other sources it may be called makeself.sh and you will either need to rename it or symlink the name to makeself
install makeself in /usr/bin and makeself-header in /usr/share/makeself (you need to create the makeself folder)
[/snip]
Yeah I did that already.

But I still had to run

Code: Select all

./configure --with-makeself="/usr/bin/makeself.sh"
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: How to build from trunk and make .rpm file?

Post by Perryg »

Actually this is the first time anyone has replied that they had problems with makeself.
Did you set the symlink properly? I never have an issue.
quickbooks
Posts: 47
Joined: 27. Apr 2013, 04:43

Re: How to build from trunk and make .rpm file?

Post by quickbooks »

Perryg wrote:Actually this is the first time anyone has replied that they had problems with makeself.
Did you set the symlink properly? I never have an issue.
How do you set the symlink properly?
quickbooks
Posts: 47
Joined: 27. Apr 2013, 04:43

Re: How to build from trunk and make .rpm file?

Post by quickbooks »

Also when I open the VirtualBox settings in the version which I compiled @/home/user/vbox/out/linux.amd64/release/bin it says:

Code: Select all

Failed to access the USB subsystem.
Could not load the Host USB Proxy service: VERR_NOT_FOUND.

Result Code: 
NS_ERROR_FAILURE (0x00004005)
Component: 
Host
Interface: 
IHost {30678943-32df-4830-b413-931b25ac86a0}
Callee: 
IMachine {1af27b33-9e69-44a5-b6d2-d375dd329a73}
I am already part of the vbox users group. So not sure why the above error occurs.
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: How to build from trunk and make .rpm file?

Post by Perryg »

--disable-extpack in your above reply will cause this.
quickbooks
Posts: 47
Joined: 27. Apr 2013, 04:43

Re: How to build from trunk and make .rpm file?

Post by quickbooks »

Perryg wrote:--disable-extpack in your above reply will cause this.
So how to remove the command "--disable-extpack" before compiling?
Perryg
Site Moderator
Posts: 34369
Joined: 6. Sep 2008, 22:55
Primary OS: Linux other
VBox Version: OSE self-compiled
Guest OSses: *NIX

Re: How to build from trunk and make .rpm file?

Post by Perryg »

You are talking about two different things here. The generic .run and the proprietary .rpm
These are different and need to be addressed separately.
If you used the --disable-extpack in the generic that will cause this issue. In the rpm build it is intentional and is because of the PUEL Extension pack.

If you want to deal with the .run let's not even talk about the .rpm and vice versa as it will over complicate the topic.
Post Reply