[RPM] Doomsday 1.9.8 launcher shortcut

edited 2012 Jun 15 in Technical Support
Hi!

I build RPM packages for RedHat Enterprise Linux and compatibles (CentOS, Scientific Linux, Oracle Linux, etc.) but I noticed two issues:

1. The "launch-doomsday" script is not installed by "make install". I have to manually install it inside the SPEC file for my RPMs.

2. The "launch-doomsday" script doesn't get the PYTHON variable replaced:
[gpulido@starscream ~]$ /usr/bin/launch-doomsday 
bash: /usr/bin/launch-doomsday: PYTHON: bad interpreter: No such file or directory
[gpulido@starscream ~]$ cat /usr/bin/launch-doomsday 
#!PYTHON
import os, sys
os.chdir('SB_DIR')
sys.path += '.'

import snowberry
[gpulido@starscream ~]$ uname -a
Linux starscream.cybertron.local 2.6.32-220.17.1.el6.i686 #1 SMP Thu Apr 26 13:37:46 EDT 2012 i686 i686 i386 GNU/Linux
[gpulido@starscream ~]$

I suppose these two things work on your linux development platform (Debian/Ubuntu?) but in my opinion, these issues should be reviewed since clearly it doesn't work in RedHat (at least).

Edit: The SB_DIR variable is also not replaced (see above the cat of the file)

Thanks!!

Comments

  • Please note that the "launch-doomsday" in the repository is a template whose contents will be used to generate the actual launch script.

    Here's the relevant part in build.pro.
        # Generate a script for starting the laucher.
        LAUNCH_FILE = launch-doomsday
        !system(sed \"s:PYTHON:$$SCRIPT_PYTHON:; s:SB_DIR:$$SB_DIR:\" \
            <\"../../distrib/linux/$$LAUNCH_FILE\" \
            >\"$$OUT_PWD/$$LAUNCH_FILE\" && \
            chmod 755 \"$$OUT_PWD/$$LAUNCH_FILE\"): error(Can\'t build $$LAUNCH_FILE)
        launch.files = $$OUT_PWD/$$LAUNCH_FILE
        launch.path = $$DENG_BIN_DIR
    
    This takes care of the substitution of "PYTHON" and "SB_DIR" and the installation. Also note that this is only executed if your qmake CONFIG contains deng_snowberry.
  • Thanks for your reply, I use the default doomsday.pro file which comes with Doomsday. The qmake line I use is this:
    qmake-qt4 -r ../doomsday.pro -o Makefile PREFIX=%{_prefix} INSTALL_ROOT=%{buildroot}
    
    I run it in a "build" directory created inside the doomsday directory. Where should I add the deng_snowberry parameter?

    Thanks!
  • You could try this:
    qmake-qt4 -r ../doomsday.pro -o Makefile CONFIG+=deng_snowberry PREFIX=%{_prefix} INSTALL_ROOT=%{buildroot}
    
    OR you could use a ../config_user.pri with the contents:
    CONFIG += deng_snowberry
    
  • Thanks a lot for your help, skyjake

    I solved it by changing the configure line into this:
    qmake-qt4 -makefile -unix -r ../doomsday.pro -o Makefile PREFIX=%{_prefix} INSTALL_ROOT=%{buildroot}
    
    It seems when the build is made for unix, it builds and installs snowberry with no problem (because deng_snowberry variable is defined for unix config file).

    Regards
  • Hmm, I thought qmake ran in unix mode by default on RedHat variants? It certainly does on Ubuntu/Debian.
  • Where can we find your packages?
  • Hi!

    Mi repos are in http://gapf.insomnia247.nl/ or http://gapf.ninth.su (they are mirrors). Normally I only upload the RPM files because of space limits, but I can publish the SRC RPM and the SPEC files on request.

    The RPM files are in http://gapf.insomnia247.nl/el/6/RPMS/ or http://gapf.ninth.su/el/6/RPMS/

    Regards.
  • skolnick wrote:
    Mi repos are in http://gapf.insomnia247.nl/ or http://gapf.ninth.su (they are mirrors). Normally I only upload the RPM files because of space limits, but I can publish the SRC RPM and the SPEC files on request.

    The RPM files are in http://gapf.insomnia247.nl/el/6/RPMS/ or http://gapf.ninth.su/el/6/RPMS/
    Can I add these to the http://dengine.net/linux page? I assume you will be updating the RPMs as new releases are made?
  • Sure, please add them. I'll do my best to keep the repo updated with the latest stable releases.

    Regards,

    German.
Sign In or Register to comment.