The Ur-Quan Masters Discussion Forum

The Ur-Quan Masters Re-Release => Technical Issues => Topic started by: midenok on February 03, 2012, 04:43:59 am

Title: How to install for packaging?
Post by: midenok on February 03, 2012, 04:43:59 am

Packaging system (for example Debian) requires to install into temporary custom location. But the program must be configured to final destination location!
The variables in config.state specify the final location. But I didn't found the measure to specify temporary custom location for 0.7.0. In 0.6.2 it were

DESTDIR=${CURDIR}/debian/uqm ./ uqm install

what was used in Debian package. How to achieve that in 0.7.0?

Title: Re: How to install for packaging?
Post by: meep-eep on February 03, 2012, 07:50:25 am
Probably Debian used a modified UQM. The build system has not changed with respect to this since 0.6.2.
I'm not sure what you're referring to by "temporary location", but if you're talking about the build directory, you can set that through the environment variable "BUILD_WORK".
See also build/unix/README.packages.

Title: Re: How to install for packaging?
Post by: midenok on February 06, 2012, 12:42:20 pm
No, I'm not referring to build directory. I'm referring to what exactly I said: temporary install directory. In autotools world this is achieved by overriding PREFIX or INSTALL_PREFIX  on (only on) installation phase. I suppose it is impossible for current custom build system? Then packaging (without patching) is impossible. No wonder why there is no 0.7.0 in Debian. This is serious subject to open bug report.

Title: Re: How to install for packaging?
Post by: meep-eep on February 06, 2012, 06:37:14 pm
Well, you can specify your own installation directory in the configuration menu.
The only thing you would have to change before installing it to its permanent location is to modify the path in the 'uqm' wrapper.

Feel free to submit a bug report, but keep in mind that despite your statement, this is not what we consider a serious issue, so it won't have a very high priority.

Note that nothing of this has changed since 0.6.0, of which there certainly was a Debian package.
The reason that there is no 0.7.0 package is probably the same reason that all Debian packages run at least one version behind, though I don't know what that reason is.

Title: Re: How to install for packaging?
Post by: midenok on February 13, 2012, 01:54:31 pm
What you suggested is a wrong way to do. I've already done it by modifying script with sed script before even posting here. That doesn't change the topic.

The reason for the releasing delay is that the people are busy. And the thing to always patch the source before adding it to package adds to this complexity. You stated that nothing changed since 0.6.0, so what? The man modified 0.6 version to comply the needs of packaging. Now it has to check if  something is changed and move the patch to new version. Do you expect that it has to do this always? Are you interested anyway in the program distribution and in a lot of people being able to enjoy from the new version?

In real world there are some de facto standards that help people cooperate effectively. Not knowing them and reinventing the wheel (such as your own build system) doesn't help much.

Title: Re: How to install for packaging?
Post by: oldlaptop on September 01, 2012, 04:57:31 am
Sorry to resurrect an old topic, but I've been messing with this for the past few days, and I'm fairly sure I've managed to figure out how it should be done. The old 0.6.2 package in Debian uses a minor patch to to make the build system respect $DESTDIR (the cflags stuff is unrelated):

--- uqm-0.6.2.dfsg.orig/sc2/
+++ uqm-0.6.2.dfsg/sc2/
@@ -29,11 +29,11 @@
+uqm_CFLAGS='@CFLAGS@ -g'

With this change the UQM build system will happily play along with the following:

DESTDIR=${CURDIR}/debian/uqm ./ uqm install

As it also installs quite happily without $DESTDIR set at all, it would be nice to see this in
the official UQM source.