Last Comment Bug 332091 - Possibility to add "special" part to package names
: Possibility to add "special" part to package names
Status: RESOLVED FIXED
: fixed1.8.0.4, fixed1.8.1
Product: Toolkit
Classification: Components
Component: Build Config (show other bugs)
: unspecified
: All All
: -- normal (vote)
: ---
Assigned To: Robert Kaiser (not working on stability any more)
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2006-03-29 04:14 PST by Robert Kaiser (not working on stability any more)
Modified: 2006-04-21 13:52 PDT (History)
1 user (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
add MOZ_PKG_SPECIAL into package name if present (784 bytes, patch)
2006-03-29 04:22 PST, Robert Kaiser (not working on stability any more)
benjamin: first‑review-
Details | Diff | Review
patch v2: make it possible to set MOZ_PKG_SPECIAL from mozconfig (2.28 KB, patch)
2006-04-04 12:08 PDT, Robert Kaiser (not working on stability any more)
benjamin: first‑review+
benjamin: approval‑branch‑1.8.1+
dveditz: approval1.8.0.4+
Details | Diff | Review

Description Robert Kaiser (not working on stability any more) 2006-03-29 04:14:46 PST
The current convention followed by our package file names (implemented via package-name.mk) says the following: http://developer.mozilla.org/en/docs/Package_Filename_Convention#Platform_.5B-special.5D
-------
Special is used to distinguish non-default characteristics of the build:

   1. GTK2 is the default toolkit on linux platforms. If a GTK binary is built, "-gtk1" is appended to the platform;
   2. for distiction to other builds, other non-default build options should be specified there in short but meaningful identifiers, e.g. builds including a patch for the MNG image format should specify -mng, or windows builds compiled with gcc instead of MSVC may specify -gcc here.
-------

We're doing that for -gtk1 automatically, but one should be able to easily add in a "special" identifier easily - our usual way for such things is to use env vars.
Comment 1 Robert Kaiser (not working on stability any more) 2006-03-29 04:22:24 PST
Created attachment 216630 [details] [diff] [review]
add MOZ_PKG_SPECIAL into package name if present

Following the style of that file, this patch adds the string in the env var MOZ_PKG_SPECIAL as special part to the package name if present.

This way, one can e.g. "export MOZ_PKG_SPECIAL=gcc4" in his shiny new Linux tinderbox and the packages it spits out will have "linux-i686-gcc4" as their "Platform [-special]" part.
Comment 2 Robert Kaiser (not working on stability any more) 2006-03-29 04:29:58 PST
For testing, I did
I tested with this patch in my SeaMonkey trunk build:

cd mozilla/xpinstall/packager; export MOZ_PKG_SPECIAL=gcc4; make
results in
seamonkey-1.5a.en-US.linux-i686-gcc4.tar.bz2

while
cd mozilla/xpinstall/packager; export MOZ_PKG_SPECIAL=; make
still results in
seamonkey-1.5a.en-US.linux-i686.tar.bz2

So the name stays the same as without the patch when the env var is unset (or empty), and it's correctly added when set :)
Comment 3 Benjamin Smedberg [:bsmedberg] 2006-04-03 12:10:15 PDT
Comment on attachment 216630 [details] [diff] [review]
add MOZ_PKG_SPECIAL into package name if present

It's totally not clear to me where this variable would come from: most of the time I'm opposed to having environment vars affect the build: perhaps we should AC_SUBST this var so that it can be set in mozconfig?
Comment 4 Robert Kaiser (not working on stability any more) 2006-04-04 12:08:57 PDT
Created attachment 217183 [details] [diff] [review]
patch v2: make it possible to set MOZ_PKG_SPECIAL from mozconfig

OK, here's a version that makes it possible to set this from mozconfig (at least it works in my patched trunk tree with "MOZ_PKG_SPECIAL=kairo" added to my mozconfig)
Comment 5 Robert Kaiser (not working on stability any more) 2006-04-04 19:14:46 PDT
Comment on attachment 217183 [details] [diff] [review]
patch v2: make it possible to set MOZ_PKG_SPECIAL from mozconfig

requesting branch approvals. The fix is trivial and straightforward, and it would be nice to be easily able to e.g. distingiush mac universal binaries from traditional PPC packages in the generated package names (esp. in tinderbox-generated builds)
Comment 6 Robert Kaiser (not working on stability any more) 2006-04-05 06:07:44 PDT
Checked in on trunk.
Comment 7 Robert Kaiser (not working on stability any more) 2006-04-07 09:12:35 PDT
landed on 1.8 branch as well :)
Comment 8 Daniel Veditz [:dveditz] 2006-04-21 13:41:29 PDT
Comment on attachment 217183 [details] [diff] [review]
patch v2: make it possible to set MOZ_PKG_SPECIAL from mozconfig

approved for 1.8.0 branch, a=dveditz for drivers
Comment 9 Robert Kaiser (not working on stability any more) 2006-04-21 13:52:04 PDT
Checked into 1.8.0 branch.

Note You need to log in before you can comment on or make changes to this bug.