summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFabien Tassin <fta@sofaraway.org>2007-12-13 18:18:54 +0100
committerFabien Tassin <fta@sofaraway.org>2007-12-13 18:18:54 +0100
commit892f8c8a7472d5aeb3302ebe0ae6169edea9ecc6 (patch)
treedbe73076eff4e9604f59db0a965ba9684afb5e90
parent67ad59d8384cd47b034b6bb420ffa152e73912a3 (diff)
* First release after a full rewrite + packaging
-rw-r--r--COPYING339
-rw-r--r--Changelog.txt3
-rw-r--r--Makefile295
-rw-r--r--README119
-rw-r--r--debian/changelog5
-rw-r--r--debian/compat1
-rw-r--r--debian/control16
-rw-r--r--debian/copyright19
-rw-r--r--debian/mozclient.install1
-rwxr-xr-xdebian/rules37
-rw-r--r--src/Makefile54
-rw-r--r--src/firefox-3.0.mk.in31
-rw-r--r--src/lightning-sunbird.mk.in32
-rw-r--r--src/mozclient.mk.in204
-rw-r--r--src/nspr.mk.in30
-rw-r--r--src/nss.mk.in30
-rw-r--r--src/remove.binonly.sh (renamed from remove.binonly.sh)0
-rw-r--r--src/seamonkey-2.0.mk.in30
-rw-r--r--src/thunderbird-3.0.mk.in30
-rw-r--r--src/xulrunner-1.9.mk.in30
20 files changed, 963 insertions, 343 deletions
diff --git a/COPYING b/COPYING
new file mode 100644
index 0000000..d511905
--- /dev/null
+++ b/COPYING
@@ -0,0 +1,339 @@
+ GNU GENERAL PUBLIC LICENSE
+ Version 2, June 1991
+
+ Copyright (C) 1989, 1991 Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+ Preamble
+
+ The licenses for most software are designed to take away your
+freedom to share and change it. By contrast, the GNU General Public
+License is intended to guarantee your freedom to share and change free
+software--to make sure the software is free for all its users. This
+General Public License applies to most of the Free Software
+Foundation's software and to any other program whose authors commit to
+using it. (Some other Free Software Foundation software is covered by
+the GNU Lesser General Public License instead.) You can apply it to
+your programs, too.
+
+ When we speak of free software, we are referring to freedom, not
+price. Our General Public Licenses are designed to make sure that you
+have the freedom to distribute copies of free software (and charge for
+this service if you wish), that you receive source code or can get it
+if you want it, that you can change the software or use pieces of it
+in new free programs; and that you know you can do these things.
+
+ To protect your rights, we need to make restrictions that forbid
+anyone to deny you these rights or to ask you to surrender the rights.
+These restrictions translate to certain responsibilities for you if you
+distribute copies of the software, or if you modify it.
+
+ For example, if you distribute copies of such a program, whether
+gratis or for a fee, you must give the recipients all the rights that
+you have. You must make sure that they, too, receive or can get the
+source code. And you must show them these terms so they know their
+rights.
+
+ We protect your rights with two steps: (1) copyright the software, and
+(2) offer you this license which gives you legal permission to copy,
+distribute and/or modify the software.
+
+ Also, for each author's protection and ours, we want to make certain
+that everyone understands that there is no warranty for this free
+software. If the software is modified by someone else and passed on, we
+want its recipients to know that what they have is not the original, so
+that any problems introduced by others will not reflect on the original
+authors' reputations.
+
+ Finally, any free program is threatened constantly by software
+patents. We wish to avoid the danger that redistributors of a free
+program will individually obtain patent licenses, in effect making the
+program proprietary. To prevent this, we have made it clear that any
+patent must be licensed for everyone's free use or not licensed at all.
+
+ The precise terms and conditions for copying, distribution and
+modification follow.
+
+ GNU GENERAL PUBLIC LICENSE
+ TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+ 0. This License applies to any program or other work which contains
+a notice placed by the copyright holder saying it may be distributed
+under the terms of this General Public License. The "Program", below,
+refers to any such program or work, and a "work based on the Program"
+means either the Program or any derivative work under copyright law:
+that is to say, a work containing the Program or a portion of it,
+either verbatim or with modifications and/or translated into another
+language. (Hereinafter, translation is included without limitation in
+the term "modification".) Each licensee is addressed as "you".
+
+Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope. The act of
+running the Program is not restricted, and the output from the Program
+is covered only if its contents constitute a work based on the
+Program (independent of having been made by running the Program).
+Whether that is true depends on what the Program does.
+
+ 1. You may copy and distribute verbatim copies of the Program's
+source code as you receive it, in any medium, provided that you
+conspicuously and appropriately publish on each copy an appropriate
+copyright notice and disclaimer of warranty; keep intact all the
+notices that refer to this License and to the absence of any warranty;
+and give any other recipients of the Program a copy of this License
+along with the Program.
+
+You may charge a fee for the physical act of transferring a copy, and
+you may at your option offer warranty protection in exchange for a fee.
+
+ 2. You may modify your copy or copies of the Program or any portion
+of it, thus forming a work based on the Program, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+ a) You must cause the modified files to carry prominent notices
+ stating that you changed the files and the date of any change.
+
+ b) You must cause any work that you distribute or publish, that in
+ whole or in part contains or is derived from the Program or any
+ part thereof, to be licensed as a whole at no charge to all third
+ parties under the terms of this License.
+
+ c) If the modified program normally reads commands interactively
+ when run, you must cause it, when started running for such
+ interactive use in the most ordinary way, to print or display an
+ announcement including an appropriate copyright notice and a
+ notice that there is no warranty (or else, saying that you provide
+ a warranty) and that users may redistribute the program under
+ these conditions, and telling the user how to view a copy of this
+ License. (Exception: if the Program itself is interactive but
+ does not normally print such an announcement, your work based on
+ the Program is not required to print an announcement.)
+
+These requirements apply to the modified work as a whole. If
+identifiable sections of that work are not derived from the Program,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works. But when you
+distribute the same sections as part of a whole which is a work based
+on the Program, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Program.
+
+In addition, mere aggregation of another work not based on the Program
+with the Program (or with a work based on the Program) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+ 3. You may copy and distribute the Program (or a work based on it,
+under Section 2) in object code or executable form under the terms of
+Sections 1 and 2 above provided that you also do one of the following:
+
+ a) Accompany it with the complete corresponding machine-readable
+ source code, which must be distributed under the terms of Sections
+ 1 and 2 above on a medium customarily used for software interchange; or,
+
+ b) Accompany it with a written offer, valid for at least three
+ years, to give any third party, for a charge no more than your
+ cost of physically performing source distribution, a complete
+ machine-readable copy of the corresponding source code, to be
+ distributed under the terms of Sections 1 and 2 above on a medium
+ customarily used for software interchange; or,
+
+ c) Accompany it with the information you received as to the offer
+ to distribute corresponding source code. (This alternative is
+ allowed only for noncommercial distribution and only if you
+ received the program in object code or executable form with such
+ an offer, in accord with Subsection b above.)
+
+The source code for a work means the preferred form of the work for
+making modifications to it. For an executable work, complete source
+code means all the source code for all modules it contains, plus any
+associated interface definition files, plus the scripts used to
+control compilation and installation of the executable. However, as a
+special exception, the source code distributed need not include
+anything that is normally distributed (in either source or binary
+form) with the major components (compiler, kernel, and so on) of the
+operating system on which the executable runs, unless that component
+itself accompanies the executable.
+
+If distribution of executable or object code is made by offering
+access to copy from a designated place, then offering equivalent
+access to copy the source code from the same place counts as
+distribution of the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+ 4. You may not copy, modify, sublicense, or distribute the Program
+except as expressly provided under this License. Any attempt
+otherwise to copy, modify, sublicense or distribute the Program is
+void, and will automatically terminate your rights under this License.
+However, parties who have received copies, or rights, from you under
+this License will not have their licenses terminated so long as such
+parties remain in full compliance.
+
+ 5. You are not required to accept this License, since you have not
+signed it. However, nothing else grants you permission to modify or
+distribute the Program or its derivative works. These actions are
+prohibited by law if you do not accept this License. Therefore, by
+modifying or distributing the Program (or any work based on the
+Program), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Program or works based on it.
+
+ 6. Each time you redistribute the Program (or any work based on the
+Program), the recipient automatically receives a license from the
+original licensor to copy, distribute or modify the Program subject to
+these terms and conditions. You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties to
+this License.
+
+ 7. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License. If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Program at all. For example, if a patent
+license would not permit royalty-free redistribution of the Program by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Program.
+
+If any portion of this section is held invalid or unenforceable under
+any particular circumstance, the balance of the section is intended to
+apply and the section as a whole is intended to apply in other
+circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system, which is
+implemented by public license practices. Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+ 8. If the distribution and/or use of the Program is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Program under this License
+may add an explicit geographical distribution limitation excluding
+those countries, so that distribution is permitted only in or among
+countries not thus excluded. In such case, this License incorporates
+the limitation as if written in the body of this License.
+
+ 9. The Free Software Foundation may publish revised and/or new versions
+of the General Public License from time to time. Such new versions will
+be similar in spirit to the present version, but may differ in detail to
+address new problems or concerns.
+
+Each version is given a distinguishing version number. If the Program
+specifies a version number of this License which applies to it and "any
+later version", you have the option of following the terms and conditions
+either of that version or of any later version published by the Free
+Software Foundation. If the Program does not specify a version number of
+this License, you may choose any version ever published by the Free Software
+Foundation.
+
+ 10. If you wish to incorporate parts of the Program into other free
+programs whose distribution conditions are different, write to the author
+to ask for permission. For software which is copyrighted by the Free
+Software Foundation, write to the Free Software Foundation; we sometimes
+make exceptions for this. Our decision will be guided by the two goals
+of preserving the free status of all derivatives of our free software and
+of promoting the sharing and reuse of software generally.
+
+ NO WARRANTY
+
+ 11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
+FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
+OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
+PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
+OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
+TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
+PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
+REPAIR OR CORRECTION.
+
+ 12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
+WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
+REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
+INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
+OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
+TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
+YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
+PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
+POSSIBILITY OF SUCH DAMAGES.
+
+ END OF TERMS AND CONDITIONS
+
+ How to Apply These Terms to Your New Programs
+
+ If you develop a new program, and you want it to be of the greatest
+possible use to the public, the best way to achieve this is to make it
+free software which everyone can redistribute and change under these terms.
+
+ To do so, attach the following notices to the program. It is safest
+to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least
+the "copyright" line and a pointer to where the full notice is found.
+
+ <one line to give the program's name and a brief idea of what it does.>
+ Copyright (C) <year> <name of author>
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or
+ (at your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+ You should have received a copy of the GNU General Public License along
+ with this program; if not, write to the Free Software Foundation, Inc.,
+ 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
+
+Also add information on how to contact you by electronic and paper mail.
+
+If the program is interactive, make it output a short notice like this
+when it starts in an interactive mode:
+
+ Gnomovision version 69, Copyright (C) year name of author
+ Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
+ This is free software, and you are welcome to redistribute it
+ under certain conditions; type `show c' for details.
+
+The hypothetical commands `show w' and `show c' should show the appropriate
+parts of the General Public License. Of course, the commands you use may
+be called something other than `show w' and `show c'; they could even be
+mouse-clicks or menu items--whatever suits your program.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the program, if
+necessary. Here is a sample; alter the names:
+
+ Yoyodyne, Inc., hereby disclaims all copyright interest in the program
+ `Gnomovision' (which makes passes at compilers) written by James Hacker.
+
+ <signature of Ty Coon>, 1 April 1989
+ Ty Coon, President of Vice
+
+This General Public License does not permit incorporating your program into
+proprietary programs. If your program is a subroutine library, you may
+consider it more useful to permit linking proprietary applications with the
+library. If this is what you want to do, use the GNU Lesser General
+Public License instead of this License.
diff --git a/Changelog.txt b/Changelog.txt
new file mode 100644
index 0000000..a763fb5
--- /dev/null
+++ b/Changelog.txt
@@ -0,0 +1,3 @@
+2007/12/11 - fta - 0.01
+ - initial release after a full rewrite
+ - Add debian packaging
diff --git a/Makefile b/Makefile
index 3e33b47..249ee6a 100644
--- a/Makefile
+++ b/Makefile
@@ -1,293 +1,2 @@
-# Created by Fabien Tassin <fta@sofaraway.org> in Sept 2007
-
-MOZ_CLIENT = mozilla/client.mk
-CVS_LOC = :pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot
-
-STAMP ?= stamped
-
-ifdef DEBIAN_TAG
-DEBIAN_LTAG = $(shell echo $(DEBIAN_TAG) | sed -e 's/=.*//')
-DEBIAN_DTAG = $(shell echo $(DEBIAN_TAG) | sed -e 's/.*=//')
-DEBIAN_CO_TAG = -r $(DEBIAN_LTAG)
-DEBIAN_MOZ_CO_TAG = MOZ_CO_TAG=$(DEBIAN_LTAG)
-else
-ifdef DEBIAN_DATE
-DEBIAN_CO_DATE = $(shell echo "-D \"$(DEBIAN_DATE)\"" | sed -e 's/[rt]/ /')
-endif
-ifdef DEBIAN_BRANCH
-DEBIAN_CO_TAG = -r $(DEBIAN_BRANCH)
-endif
-endif
-
-DEBIAN_EXCLUDE_SCRIPT := remove.binonly.sh
-NOBINONLY := nobinonly
-
-############################################################################
-DEBIAN_FF3_TARGET := firefox-orig
-DEBIAN_FF3_APPNAME := firefox-3.0
-DEBIAN_FF3_FILE := mozilla/browser/config/version.txt
-DEBIAN_FF3_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=SeaMonkeyBrowser&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=week&mindate=&maxdate=&cvsroot=%2Fcvsroot'
-
-DEBIAN_XUL_TARGET := xulrunner-orig
-DEBIAN_XUL_APPNAME := xulrunner-1.9
-DEBIAN_XUL_FILE := mozilla/config/milestone.txt
-DEBIAN_XUL_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=SeaMonkeyBrowser&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=week&mindate=&maxdate=&cvsroot=%2Fcvsroot'
-
-DEBIAN_TB_TARGET := thunderbird-orig
-DEBIAN_TB_APPNAME := thunderbird-3.0
-DEBIAN_TB_FILE := mozilla/mail/config/version.txt
-DEBIAN_TB_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=SeaMonkeyMailNews&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=week&mindate=&maxdate=&cvsroot=%2Fcvsroot'
-
-DEBIAN_NSS_TARGET := nss-orig
-DEBIAN_NSS_APPNAME := nss
-DEBIAN_NSS_FILE := mozilla/security/nss/lib/nss/nss.h
-DEBIAN_NSS_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=NSS&module=all&branch=HEAD&branchtype=match&dir=mozilla%2Fdbm+mozilla%2Fsecurity%2Fnss+mozilla%2Fsecurity%2Fcoreconf+mozilla%2Fsecurity%2Fdbm&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=month&mindate=&maxdate=&cvsroot=%2Fcvsroot'
-
-DEBIAN_NSPR_TARGET := nspr-orig
-DEBIAN_NSPR_APPNAME := nspr
-DEBIAN_NSPR_FILE := mozilla/nsprpub/configure.in
-DEBIAN_NSPR_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=all&branch=HEAD&branchtype=match&dir=mozilla%2Fnsprpub&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=explicit&mindate=1177522884&maxdate=1588258884&cvsroot=%2Fcvsroot'
-
-DEBIAN_SM2_TARGET := seamonkey-orig
-DEBIAN_SM2_APPNAME := seamonkey-2.0
-DEBIAN_SM2_FILE := mozilla/suite/config/version.txt
-DEBIAN_SM2_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=SeaMonkeyBrowser&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=week&mindate=&maxdate=&cvsroot=%2Fcvsroot'
-
-DEBIAN_SB0_TARGET := sunbird-orig
-DEBIAN_SB0_APPNAME := lightning-sunbird
-DEBIAN_SB0_FILE := mozilla/calendar/sunbird/config/version.txt
-DEBIAN_SB0_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=CalendarClient&branch=MOZILLA_1_8_BRANCH&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=week&mindate=&maxdate=&cvsroot=%2Fcvsroot'
-
-############################################################################
-
-EXCLUDE := --exclude=CVS --exclude=.cvsignore
-GET := wget -O - -q --read-timeout=10 --user-agent='' --tries=3 $$URL 2> /dev/null | grep "href='http://webtools" | head -1 | tr '<>' '@' | cut -d@ -f5 | tr -d ':-' | sed -e 's/&nbsp;/t/'
-
-help:
- @echo "Usage:"
- @echo " make client Fetch and patch mozilla client"
- @echo " make status List all Mozilla CVS tags"
- @printf " make %-20s Create %s sources tarball\n" $(DEBIAN_FF3_TARGET) $(DEBIAN_FF3_APPNAME)
- @printf " make %-20s Create %s sources tarball\n" $(DEBIAN_XUL_TARGET) $(DEBIAN_XUL_APPNAME)
- @printf " make %-20s Create %s sources tarball\n" $(DEBIAN_TB_TARGET) $(DEBIAN_TB_APPNAME)
- @printf " make %-20s Create %s sources tarball\n" $(DEBIAN_SM2_TARGET) $(DEBIAN_SM2_APPNAME)
- @printf " make %-20s Create %s sources tarball\n" $(DEBIAN_NSS_TARGET) $(DEBIAN_NSS_APPNAME)
- @printf " make %-20s Create %s sources tarball\n" $(DEBIAN_NSPR_TARGET) $(DEBIAN_NSPR_APPNAME)
- @printf " make %-20s Create %s sources tarball (MOZILLA_1_8_BRANCH)\n" $(DEBIAN_SB0_TARGET) $(DEBIAN_SB0_APPNAME)
- @echo
- @echo " you can also recreate a tarball from a specific timestamp by specifying"
- @echo " DEBIAN_DATE in the form YYYYMMDDtHHMM"
- @echo
- @echo " Ex: make DEBIAN_DATE=20070911t1711 nspr-orig"
- @echo
- @echo " you can fetch a specific branch by specifying DEBIAN_BRANCH."
- @echo
- @echo " Ex: make DEBIAN_BRANCH=MOZILLA_1_9a8_MINIBRANCH firefox-orig"
- @echo
- @echo " It is also possible to use both DEBIAN_DATE and DEBIAN_BRANCH to fetch"
- @echo " the content of a branch at a particular date"
- @echo
- @echo " Alternatively, you can fetch a specific CO tag using DEBIAN_TAG."
- @echo " See 'make status' for a list of available tags."
- @echo
- @echo " Ex: make DEBIAN_TAG=MOZILLA_1_9a8_RELEASE=3.0~alpha8 firefox-orig"
-
-deps:
- @if [ ! -f /usr/bin/cvs ] ; then echo "**ERROR** Depends on missing cvs. Abort"; exit 1; fi
- @if [ ! -f /usr/bin/quilt ] ; then echo "**ERROR** Depends on missing quilt. Abort"; exit 1; fi
- @if [ ! -f /usr/bin/wget ] ; then echo "**ERROR** Depends on missing wget. Abort"; exit 1; fi
-
-$(MOZ_CLIENT): deps
- cvs -d $(CVS_LOC) co $(DEBIAN_CO_DATE) $(DEBIAN_CO_TAG) $@
- rm -rf .pc $(STAMP)
-
-client18: deps
- cvs -d $(CVS_LOC) co -r MOZILLA_1_8_BRANCH $(DEBIAN_CO_DATE) $(DEBIAN_CO_TAG) $(MOZ_CLIENT)
-
-client: $(STAMP)
-
-$(DEBIAN_FF3_FILE):
- cvs -d $(CVS_LOC) co $(DEBIAN_CO_DATE) $(DEBIAN_CO_TAG) $@
-$(DEBIAN_XUL_FILE):
- cvs -d $(CVS_LOC) co $(DEBIAN_CO_DATE) $(DEBIAN_CO_TAG) $@
-$(DEBIAN_TB_FILE):
- cvs -d $(CVS_LOC) co $(DEBIAN_CO_DATE) $(DEBIAN_CO_TAG) $@
-$(DEBIAN_SM2_FILE):
- cvs -d $(CVS_LOC) co $(DEBIAN_CO_DATE) $(DEBIAN_CO_TAG) $@
-$(DEBIAN_NSS_FILE):
- cvs -d $(CVS_LOC) co $(DEBIAN_CO_DATE) $(DEBIAN_CO_TAG) $@
-$(DEBIAN_NSPR_FILE):
- cvs -d $(CVS_LOC) co $(DEBIAN_CO_DATE) $(DEBIAN_CO_TAG) $@
-$(DEBIAN_SB0_FILE):
- cvs -d $(CVS_LOC) co -r MOZILLA_1_8_BRANCH $(DEBIAN_CO_DATE) $(DEBIAN_CO_TAG) $@
-
-status: $(MOZ_CLIENT)
- ( cd mozilla ; cvs status -v client.mk )
-
-$(STAMP): $(MOZ_CLIENT)
- @echo Patching
- quilt --quiltrc /dev/null push -a || test $$? = 2
- touch $(STAMP)
-
-unpatch:
- @echo Unpatching
- -quilt --quiltrc /dev/null pop -a -R || test $$? = 2
- rm -rf .pc $(STAMP)
-
-clean: unpatch
- rm -rf cvsco.log* $(MOZ_CLIENT) mozilla
-
-all: $(DEBIAN_FF3_TARGET) $(DEBIAN_XUL_TARGET) $(DEBIAN_NSS_TARGET)
-
-$(DEBIAN_FF3_TARGET): $(MOZ_CLIENT) $(STAMP) $(DEBIAN_FF3_FILE)
- URL=$(DEBIAN_FF3_URL) ; \
- if [ "$(DEBIAN_TAG)" != "" ] ; then \
- DEBIAN_FF3_VERSION=$(DEBIAN_DTAG) ; \
- DEBIAN_FF3_DATE=$$DEBIAN_FF3_VERSION ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=xulbrowser $(DEBIAN_MOZ_CO_TAG) ; \
- else \
- if [ "$(DEBIAN_DATE)" != "" ] ; then DEBIAN_FF3_DATE=$(DEBIAN_DATE) ; else DEBIAN_FF3_DATE=`$(GET)` ; fi ; \
- DEBIAN_FF3_CO_DATE=`echo "$$DEBIAN_FF3_DATE" | sed -e 's/[rt]/ /'` ; \
- DEBIAN_FF3_VERSION="`cat $(DEBIAN_FF3_FILE) | sed -e 's/pre//; s/a\([0-9]*\)/~alpha\1/; s/b\([0-9]*\)/~b\1/; s/$$/~cvs'"$$DEBIAN_FF3_DATE"'/'`" ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=xulbrowser MOZ_CO_DATE="$$DEBIAN_FF3_CO_DATE" ; \
- fi ; \
- ( cd mozilla ; sh ../$(DEBIAN_EXCLUDE_SCRIPT) > REMOVED+$(NOBINONLY).txt 2>&1 ) ; \
- DEBIAN_FF3_VERSION=$$DEBIAN_FF3_VERSION+$(NOBINONLY) ; \
- rm -rf $(DEBIAN_FF3_APPNAME)-$$DEBIAN_FF3_VERSION $(DEBIAN_FF3_APPNAME)_$$DEBIAN_FF3_VERSION.orig.tar.gz && \
- mkdir $(DEBIAN_FF3_APPNAME)-$$DEBIAN_FF3_VERSION && \
- echo "Creating $(DEBIAN_FF3_APPNAME)-$$DEBIAN_FF3_VERSION/browser-snapshot-$$DEBIAN_FF3_DATE.tar.bz2 ..." && \
- tar jcf $(DEBIAN_FF3_APPNAME)-$$DEBIAN_FF3_VERSION/browser-snapshot-$$DEBIAN_FF3_DATE.tar.bz2 $(EXCLUDE) mozilla && \
- rm -f $(DEBIAN_FF3_APPNAME)_$$DEBIAN_FF3_VERSION.orig.tar.gz && \
- echo "Creating $(DEBIAN_FF3_APPNAME)_$$DEBIAN_FF3_VERSION.orig.tar.gz ..." && \
- tar zcf $(DEBIAN_FF3_APPNAME)_$$DEBIAN_FF3_VERSION.orig.tar.gz $(DEBIAN_FF3_APPNAME)-$$DEBIAN_FF3_VERSION && \
- rm -rf mozilla cvsco.log* $(STAMP) .pc $(DEBIAN_FF3_APPNAME)-$$DEBIAN_FF3_VERSION ; \
- ls -l $(DEBIAN_FF3_APPNAME)_$$DEBIAN_FF3_VERSION.orig.tar.gz
-
-$(DEBIAN_XUL_TARGET): $(MOZ_CLIENT) $(STAMP) $(DEBIAN_XUL_FILE)
- URL=$(DEBIAN_XUL_URL) ; \
- if [ "$(DEBIAN_TAG)" != "" ] ; then \
- DEBIAN_XUL_VERSION=$(DEBIAN_DTAG) ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=xulrunner $(DEBIAN_MOZ_CO_TAG) ; \
- else \
- if [ "$(DEBIAN_DATE)" != "" ] ; then DEBIAN_XUL_DATE=$(DEBIAN_DATE) ; else DEBIAN_XUL_DATE=`$(GET)` ; fi ; \
- DEBIAN_XUL_CO_DATE="`echo $$DEBIAN_XUL_DATE | sed -e 's/[rt]/ /'`" ; \
- DEBIAN_XUL_VERSION="`tail -1 $(DEBIAN_XUL_FILE) | sed -e 's/pre//; s/\([ab]\)\([0-9]*\)/~\1\2/'`~cvs$$DEBIAN_XUL_DATE" ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=xulrunner MOZ_CO_DATE="$$DEBIAN_XUL_CO_DATE" ; \
- fi ; \
- ( cd mozilla ; sh ../$(DEBIAN_EXCLUDE_SCRIPT) > REMOVED+$(NOBINONLY).txt 2>&1 ) ; \
- DEBIAN_XUL_VERSION=$$DEBIAN_XUL_VERSION+$(NOBINONLY) ; \
- mkdir $(DEBIAN_XUL_APPNAME)-$$DEBIAN_XUL_VERSION && \
- mv mozilla $(DEBIAN_XUL_APPNAME)-$$DEBIAN_XUL_VERSION && \
- rm -f $(DEBIAN_XUL_APPNAME)_$$DEBIAN_XUL_VERSION.orig.tar.gz && \
- echo "Creating $(DEBIAN_XUL_APPNAME)_$$DEBIAN_XUL_VERSION.orig.tar.gz ..." && \
- tar zcf $(DEBIAN_XUL_APPNAME)_$$DEBIAN_XUL_VERSION.orig.tar.gz $(EXCLUDE) $(DEBIAN_XUL_APPNAME)-$$DEBIAN_XUL_VERSION && \
- rm -rf cvsco.log* $(STAMP) .pc $(DEBIAN_XUL_APPNAME)-$$DEBIAN_XUL_VERSION ; \
- ls -l $(DEBIAN_XUL_APPNAME)_$$DEBIAN_XUL_VERSION.orig.tar.gz
-
-$(DEBIAN_TB_TARGET): $(MOZ_CLIENT) $(STAMP) $(DEBIAN_TB_FILE)
- URL=$(DEBIAN_TB_URL) ; \
- if [ "$(DEBIAN_TAG)" != "" ] ; then \
- DEBIAN_TB_VERSION=$(DEBIAN_DTAG) ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=mail $(DEBIAN_MOZ_CO_TAG) ; \
- else \
- if [ "$(DEBIAN_DATE)" != "" ] ; then DEBIAN_TB_DATE=$(DEBIAN_DATE) ; else DEBIAN_TB_DATE=`$(GET)` ; fi ; \
- DEBIAN_TB_CO_DATE="`echo $$DEBIAN_TB_DATE | sed -e 's/[rt]/ /'`" ; \
- DEBIAN_TB_VERSION="`tail -1 $(DEBIAN_TB_FILE) | sed -e 's/pre//; s/\([ab]\)\([0-9]*\)/~\1\2/'`~cvs$$DEBIAN_TB_DATE" ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=mail MOZ_CO_DATE="$$DEBIAN_TB_CO_DATE" ; \
- fi ; \
- ( cd mozilla ; sh ../$(DEBIAN_EXCLUDE_SCRIPT) > REMOVED+$(NOBINONLY).txt 2>&1 ) ; \
- DEBIAN_TB_VERSION=$$DEBIAN_TB_VERSION+$(NOBINONLY) ; \
- mkdir $(DEBIAN_TB_APPNAME)-$$DEBIAN_TB_VERSION && \
- mv mozilla $(DEBIAN_TB_APPNAME)-$$DEBIAN_TB_VERSION && \
- rm -f $(DEBIAN_TB_APPNAME)_$$DEBIAN_TB_VERSION.orig.tar.gz && \
- echo "Creating $(DEBIAN_TB_APPNAME)_$$DEBIAN_TB_VERSION.orig.tar.gz ..." && \
- tar zcf $(DEBIAN_TB_APPNAME)_$$DEBIAN_TB_VERSION.orig.tar.gz $(EXCLUDE) $(DEBIAN_TB_APPNAME)-$$DEBIAN_TB_VERSION && \
- rm -rf cvsco.log* $(STAMP) .pc $(DEBIAN_TB_APPNAME)-$$DEBIAN_TB_VERSION ; \
- ls -l $(DEBIAN_TB_APPNAME)_$$DEBIAN_TB_VERSION.orig.tar.gz
-
-$(DEBIAN_SM2_TARGET): $(MOZ_CLIENT) $(STAMP) $(DEBIAN_SM2_FILE)
- URL=$(DEBIAN_SM2_URL) ; \
- if [ "$(DEBIAN_TAG)" != "" ] ; then \
- DEBIAN_SM2_VERSION=$(DEBIAN_DTAG) ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=suite $(DEBIAN_MOZ_CO_TAG) ; \
- else \
- if [ "$(DEBIAN_DATE)" != "" ] ; then DEBIAN_SM2_DATE=$(DEBIAN_DATE) ; else DEBIAN_SM2_DATE=`$(GET)` ; fi ; \
- DEBIAN_SM2_CO_DATE="`echo $$DEBIAN_SM2_DATE | sed -e 's/[rt]/ /'`" ; \
- DEBIAN_SM2_VERSION="`tail -1 $(DEBIAN_SM2_FILE) | sed -e 's/pre//; s/\([ab]\)\([0-9]*\)/~\1\2/'`~cvs$$DEBIAN_SM2_DATE" ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=suite MOZ_CO_DATE="$$DEBIAN_SM2_CO_DATE" ; \
- fi ; \
- ( cd mozilla ; sh ../$(DEBIAN_EXCLUDE_SCRIPT) > REMOVED+$(NOBINONLY).txt 2>&1 ) ; \
- DEBIAN_SM2_VERSION=$$DEBIAN_SM2_VERSION+$(NOBINONLY) ; \
- mv mozilla $(DEBIAN_SM2_APPNAME)-$$DEBIAN_SM2_VERSION && \
- rm -f $(DEBIAN_SM2_APPNAME)_$$DEBIAN_SM2_VERSION.orig.tar.gz && \
- echo "Creating $(DEBIAN_SM2_APPNAME)_$$DEBIAN_SM2_VERSION.orig.tar.gz ..." && \
- tar zcf $(DEBIAN_SM2_APPNAME)_$$DEBIAN_SM2_VERSION.orig.tar.gz $(EXCLUDE) $(DEBIAN_SM2_APPNAME)-$$DEBIAN_SM2_VERSION && \
- rm -rf cvsco.log* $(STAMP) .pc $(DEBIAN_SM2_APPNAME)-$$DEBIAN_SM2_VERSION ; \
- ls -l $(DEBIAN_SM2_APPNAME)_$$DEBIAN_SM2_VERSION.orig.tar.gz
-
-$(DEBIAN_NSS_TARGET): $(MOZ_CLIENT) $(STAMP) $(DEBIAN_NSS_FILE)
- URL=$(DEBIAN_NSS_URL) ; \
- if [ "$(DEBIAN_TAG)" != "" ] ; then \
- DEBIAN_NSS_VERSION=$(DEBIAN_DTAG) ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=nss $(DEBIAN_MOZ_CO_TAG) ; \
- else \
- if [ "$(DEBIAN_DATE)" != "" ] ; then DEBIAN_NSS_DATE=$(DEBIAN_DATE) ; else DEBIAN_NSS_DATE=`$(GET)` ; fi ; \
- DEBIAN_NSS_CO_DATE="`echo $$DEBIAN_NSS_DATE | sed -e 's/[rt]/ /'`" ; \
- DEBIAN_NSS_VERSION="`grep -E '^\#define NSS_V(MAJOR|MINOR|PATCH)' $(DEBIAN_NSS_FILE) | awk '{print $$3}' | tr '\n' '.' | sed -e 's,\.$$,,'`~cvs$$DEBIAN_NSS_DATE" ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=nss MOZ_CO_DATE="$$DEBIAN_NSS_CO_DATE" ; \
- fi ; \
- ( cd mozilla ; sh ../$(DEBIAN_EXCLUDE_SCRIPT) > REMOVED+$(NOBINONLY).txt 2>&1 ) ; \
- DEBIAN_NSS_VERSION=$$DEBIAN_NSS_VERSION+$(NOBINONLY) ; \
- mkdir $(DEBIAN_NSS_APPNAME)-$$DEBIAN_NSS_VERSION && \
- mv mozilla $(DEBIAN_NSS_APPNAME)-$$DEBIAN_NSS_VERSION && \
- rm -f $(DEBIAN_NSS_APPNAME)_$$DEBIAN_NSS_VERSION.orig.tar.gz && \
- echo "Creating $(DEBIAN_NSS_APPNAME)_$$DEBIAN_NSS_VERSION.orig.tar.gz ..." && \
- tar zcf $(DEBIAN_NSS_APPNAME)_$$DEBIAN_NSS_VERSION.orig.tar.gz $(EXCLUDE) $(DEBIAN_NSS_APPNAME)-$$DEBIAN_NSS_VERSION && \
- rm -rf cvsco.log* $(STAMP) .pc $(DEBIAN_NSS_APPNAME)-$$DEBIAN_NSS_VERSION ; \
- ls -l $(DEBIAN_NSS_APPNAME)_$$DEBIAN_NSS_VERSION.orig.tar.gz
-
-$(DEBIAN_NSPR_TARGET): $(MOZ_CLIENT) $(STAMP) $(DEBIAN_NSPR_FILE)
- URL=$(DEBIAN_NSPR_URL) ; \
- if [ "$(DEBIAN_TAG)" != "" ] ; then \
- DEBIAN_NSPR_VERSION=$(DEBIAN_DTAG) ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=nspr $(DEBIAN_MOZ_CO_TAG) ; \
- else \
- if [ "$(DEBIAN_DATE)" != "" ] ; then DEBIAN_NSPR_DATE=$(DEBIAN_DATE) ; else DEBIAN_NSPR_DATE=`$(GET)` ; fi ; \
- DEBIAN_NSPR_CO_DATE="`echo $$DEBIAN_NSPR_DATE | sed -e 's/[rt]/ /'`" ; \
- DEBIAN_NSPR_VERSION="`grep -E '^MOD_(MAJOR|MINOR|PATCH)_VERSION' $(DEBIAN_NSPR_FILE) | cut -d= -f2 | tr '\n' '.' | sed -e 's,\.$$,,'`~cvs$$DEBIAN_NSPR_DATE" ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=nspr MOZ_CO_DATE="$$DEBIAN_NSPR_CO_DATE" ; \
- fi ; \
- ( cd mozilla ; sh ../$(DEBIAN_EXCLUDE_SCRIPT) > REMOVED+$(NOBINONLY).txt 2>&1 ) ; \
- DEBIAN_NSPR_VERSION=$$DEBIAN_NSPR_VERSION+$(NOBINONLY) ; \
- mkdir $(DEBIAN_NSPR_APPNAME)-$$DEBIAN_NSPR_VERSION && \
- mv mozilla $(DEBIAN_NSPR_APPNAME)-$$DEBIAN_NSPR_VERSION && \
- rm -f $(DEBIAN_NSPR_APPNAME)_$$DEBIAN_NSPR_VERSION.orig.tar.gz && \
- echo "Creating $(DEBIAN_NSPR_APPNAME)_$$DEBIAN_NSPR_VERSION.orig.tar.gz ..." && \
- tar zcf $(DEBIAN_NSPR_APPNAME)_$$DEBIAN_NSPR_VERSION.orig.tar.gz $(EXCLUDE) $(DEBIAN_NSPR_APPNAME)-$$DEBIAN_NSPR_VERSION && \
- rm -rf cvsco.log* $(STAMP) .pc $(DEBIAN_NSPR_APPNAME)-$$DEBIAN_NSPR_VERSION ; \
- ls -l $(DEBIAN_NSPR_APPNAME)_$$DEBIAN_NSPR_VERSION.orig.tar.gz
-
-$(DEBIAN_SB0_TARGET): client18 $(DEBIAN_SB0_FILE)
- URL=$(DEBIAN_SB0_URL) ; \
- if [ "$(DEBIAN_TAG)" != "" ] ; then \
- DEBIAN_SB0_VERSION=$(DEBIAN_DTAG) ; \
- make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=calendar $(DEBIAN_MOZ_CO_TAG) ; \
- else \
- if [ "$(DEBIAN_DATE)" != "" ] ; then DEBIAN_SB0_DATE=$(DEBIAN_DATE) ; else DEBIAN_SB0_DATE=`$(GET)` ; fi ; \
- DEBIAN_SB0_CO_DATE="`echo $$DEBIAN_SB0_DATE | sed -e 's/[rt]/ /'`" ; \
- DEBIAN_SB0_VERSION="`tail -1 $(DEBIAN_SB0_FILE) | sed -e 's/pre//; s/\([ab]\)\([0-9]*\)/~\1\2/'`~cvs$$DEBIAN_SB0_DATE" ; \
- make -f $(MOZ_CLIENT) checkout -r MOZILLA_1_8_BRANCH MOZ_CO_PROJECT=calendar MOZ_CO_DATE="$$DEBIAN_SB0_CO_DATE" ; \
- fi ; \
- ( cd mozilla ; sh ../$(DEBIAN_EXCLUDE_SCRIPT) > REMOVED+$(NOBINONLY).txt 2>&1 ) ; \
- DEBIAN_SB0_VERSION=$$DEBIAN_SB0_VERSION+$(NOBINONLY) ; \
- rm -rf $(DEBIAN_SB0_APPNAME)-$$DEBIAN_SB0_VERSION $(DEBIAN_SB0_APPNAME)_$$DEBIAN_SB0_VERSION.orig.tar.gz && \
- mkdir $(DEBIAN_SB0_APPNAME)-$$DEBIAN_SB0_VERSION && \
- echo "Creating $(DEBIAN_SB0_APPNAME)-$$DEBIAN_SB0_VERSION/$(DEBIAN_SB0_APPNAME)-$$DEBIAN_SB0_VERSION-source.tar.bz2 ..." && \
- tar jcf $(DEBIAN_SB0_APPNAME)-$$DEBIAN_SB0_VERSION/$(DEBIAN_SB0_APPNAME)-$$DEBIAN_SB0_VERSION-source.tar.bz2 $(EXCLUDE) mozilla && \
- rm -f $(DEBIAN_SB0_APPNAME)_$$DEBIAN_SB0_VERSION.orig.tar.gz && \
- echo "Creating $(DEBIAN_SB0_APPNAME)_$$DEBIAN_SB0_VERSION.orig.tar.gz ..." && \
- tar zcf $(DEBIAN_SB0_APPNAME)_$$DEBIAN_SB0_VERSION.orig.tar.gz $(DEBIAN_SB0_APPNAME)-$$DEBIAN_SB0_VERSION && \
- rm -rf mozilla cvsco.log* $(STAMP) .pc $(DEBIAN_SB0_APPNAME)-$$DEBIAN_SB0_VERSION ; \
- ls -l $(DEBIAN_SB0_APPNAME)_$$DEBIAN_SB0_VERSION.orig.tar.gz
-
-.PHONY : all clean help deps client client18 unpatch status
+include firefox.mk
+get-orig-source: mozclient-get-orig-source
diff --git a/README b/README
index a346352..abd530f 100644
--- a/README
+++ b/README
@@ -1,51 +1,70 @@
-This package has been created by Fabien Tassin <fta@sofaraway.org>.
+mozclient is an abstract tarball creator based on Makefile inheritance which
+provides a get-new-orig target usable by Mozilla packages in Ubuntu.
+
+The package contains rules for the following projects:
+ - firefox-3.0
+ - lightning-sunbird (from MOZILLA_1_8_BRANCH)
+ - nspr
+ - nss
+ - seamonkey-2.0
+ - thunderbird-3.0
+ - xulrunner-1.9
+
+A clean-up script, called "remove.binonly.sh", is called to remove all
+binary-only files. It is applied to all projects before packing.
+Traces of the cleaning are preserved inside that resulting tarball
+in REMOVED+nobinonly.txt. If nothing has been removed, both the log and
+the "+nobinonly" signature are dropped.
+
+To use :
+
+- in debian/control: add mozclient to Build-Depends
+- in debian/rules: add "include /usr/share/mozclient/yourproject.mk"
+
+The following targets are then available to the caller of debian/rules:
+- get-orig-source
+ Build a tarball according to parameters from project.mk
+ and optionally using either DEBIAN_DATE or DEBIAN_TAG
+- mozclient-status
+ List all the registered CVS tags from upstream server
+
+The caller could specify the following parameters:
+DEBIAN_DATE in the form YYYYMMDDtHHMM
+ ex: DEBIAN_DATE=20070911t1711
+or
+DEBIAN_TAG in the form CVS_TAG=debian_version
+ ex: DEBIAN_TAG=FIREFOX_3_0b2_RC1=3.0~b2~rc1
+
+Projects files are stored in /usr/share/mozclient as .mk files.
+They contain the following parameters:
+
+- MOZCLIENT_TARGET (mandatory): a label, usually 'project-orig'
+- MOZCLIENT_APPNAME (mandatory): package name
+- MOZCLIENT_PROJECT (mandatory): CVS project name
+- MOZCLIENT_BRANCH (optional): CVS branch name
+- MOZCLIENT_FILE (mandatory): source file containing the version
+- MOZCLIENT_GETVERSION (mandatory): how to transform the version
+- MOZCLIENT_URL (mandatory): an URL (usually on Bonsai) listing commits
+- MOZCLIENT_GETDATE (mandatory): get the last commit date for the project
+- MOZCLIENT_EMBEDDED (optional): create an embedded tarball (default: 0)
+- MOZCLIENT_WANTMOZDIR (optional): should the root dir be 'mozilla'?
+ (default: 0 unless MOZCLIENT_EMBEDDED=1)
+
+Example with firefox-3.0:
+
+- in debian/control, add mozclient to Build-Depends
+- in debian/rules, add:
+ include /usr/share/mozclient/firefox-3.0.mk
+
+That's it. You've gained get-orig-source.
+
+You can now call it:
+- debian/rules get-orig-source
+ => firefox-3.0_3.0~b2~cvs20071120t1456+nobinonly.orig.tar.gz
+
+- debian/rules get-orig-source DEBIAN_DATE=20070914t1713
+ => firefox-3.0_3.0~a8~cvs20070914t1713+nobinonly.orig.tar.gz
+
+- debian/rules get-orig-source DEBIAN_TAG=FIREFOX_3_0b2_RC1=3.0~b2~rc1
+ => firefox-3.0_3.0~b2~rc1+nobinonly.orig.tar.gz
-It is *not* a debian package.
-
-It is composed of just a Makefile and a pile of patches.
-Those patches are targetting mozilla/client.mk and add targets to
-fetch respectively nss, nspr and xulbrowser (browser build with libxul
-from xulrunner package).
-
-Depends on cvs, wget and quilt.
-
-To use:
-
- $ make (display usage)
-
- Usage:
- make client Fetch and patch mozilla client
- make firefox-orig Create firefox-3.0 sources tarball
- make xulrunner-orig Create xulrunner-1.9 sources tarball
- make thunderbird-orig Create thunderbird-3.0 sources tarball
- make seamonkey-orig Create seamonkey-2.0 sources tarball
- make nss-orig Create nss sources tarball
- make nspr-orig Create nspr sources tarball
- make sunbird-orig Create lightning-sunbird sources tarball (*)
-
- (*): this is in the MOZILLA_1_8_BRANCH, while everything else is in trunk
-
- You can also recreate a tarball from a specific timestamp by specifying
- DEBIAN_DATE in the form YYYYMMDDtHHMM
-
- Ex: make DEBIAN_DATE=20070911t1711 nspr-orig
-
- You can fetch a specific branch by specifying DEBIAN_BRANCH.
-
- Ex: make DEBIAN_BRANCH=MOZILLA_1_9a8_MINIBRANCH firefox-orig
-
- It is also possible to use both DEBIAN_DATE and DEBIAN_BRANCH to fetch
- the content of a branch at a particular date
-
- Alternatively, you can fetch a specific CO tag using DEBIAN_TAG.
- See 'make status' for a list of available tags.
-
- Ex: make DEBIAN_TAG=MOZILLA_1_9a8_RELEASE=3.0~alpha8 firefox-orig
- will create a tarball named firefox-3.0-3.0~alpha8+nobinonly.orig.tar.gz
-
- It is also possible to just call the new client.mk targets without
- building tarballs:
-
- $ make -f mozilla/client.mk checkout MOZ_CO_PROJECT=nss
- $ make -f mozilla/client.mk checkout MOZ_CO_PROJECT=nspr
- $ make -f mozilla/client.mk checkout MOZ_CO_PROJECT=xulbrowser
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..cbf1998
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,5 @@
+mozclient (0.01) UNRELEASED; urgency=low
+
+ * Initial version
+
+ -- Fabien Tassin <fta@sofaraway.org> Tue, 11 Dec 2007 20:00:00 +0100
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 0000000..7ed6ff8
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+5
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..cd0e75d
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,16 @@
+Source: mozclient
+Section: devel
+Priority: optional
+Maintainer: Ubuntu Mozilla Team <ubuntu-mozillateam@lists.ubuntu.com>
+Uploaders: Fabien Tassin <fta@sofaraway.org>
+Build-Depends: debhelper (>= 5), cdbs
+Standards-Version: 3.7.3
+Vcs-Bzr: https://code.launchpad.net/~mozillateam/mozclient/mozclient
+
+Package: mozclient
+Architecture: all
+Depends: cvs, wget, quilt
+Description: tarball creator for Ubuntu Mozilla packages
+ This package contains mozclient, an abstract tarball creator
+ based on Makefile inheritance which provides a get-new-orig target
+ usable by Mozilla packages in Ubuntu.
diff --git a/debian/copyright b/debian/copyright
new file mode 100644
index 0000000..623b665
--- /dev/null
+++ b/debian/copyright
@@ -0,0 +1,19 @@
+This package was debianized by Fabien Tassin <fta@sofaraway.org> on
+Tue, 11 Dec 2007 20:01:53 +0100
+
+Authors: Fabien Tassin
+
+Copyright :
+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2 of the License, or (at
+ your option) any later version.
+
+ This program is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ GNU General Public License for more details.
+
+On Debian systems, the complete text of the GNU General Public License
+can be found in the file /usr/share/common-licenses/GPL-2.
diff --git a/debian/mozclient.install b/debian/mozclient.install
new file mode 100644
index 0000000..b11ecb5
--- /dev/null
+++ b/debian/mozclient.install
@@ -0,0 +1 @@
+debian/tmp/usr/share/mozclient
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000..52873db
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,37 @@
+#!/usr/bin/make -f
+
+# Copyright (c) 2007 Fabien Tassin <fta@sofaraway.org>
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+# 02111-1307 USA.
+
+DEB_SOURCE_PACKAGE = mozclient
+DEB_INDEP_PACKAGES = $(DEB_SOURCE_PACKAGE)
+DEB_ARCH_PACKAGES = $(NULL)
+
+include /usr/share/cdbs/1/rules/debhelper.mk
+include /usr/share/cdbs/1/class/makefile.mk
+
+DEB_SRCDIR := $(CURDIR)/src
+DEB_MAKE_BUILD_TARGET := build
+DEB_MAKE_INSTALL_TARGET := install DESTDIR=$(CURDIR)/debian/tmp/
+DEB_MAKE_CHECK_TARGET := $(NULL)
+
+DEB_INSTALL_CHANGELOGS_ALL := Changelog.txt
+DEB_INSTALL_DOCS_ALL := README
+
+DEB_VERSION := $(shell dpkg-parsechangelog | sed -n 's/^Version: *\(.*\)$$/\1/ p')
+DEB_UPSTREAM_VERSION := $(shell echo $(DEBIAN_VERSION) | sed 's/^\(.*\)-[^-]*$$/\1/')
+DEB_ISNATIVE := 1
diff --git a/src/Makefile b/src/Makefile
new file mode 100644
index 0000000..ef645e9
--- /dev/null
+++ b/src/Makefile
@@ -0,0 +1,54 @@
+# -*- mode: makefile; coding: utf-8 -*-
+
+# Copyright (c) 2007 Fabien Tassin <fta@sofaraway.org>
+# Description: Build system for mozclient
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+# 02111-1307 USA.
+
+PREFIX ?= /usr
+
+DATADIR = $(PREFIX)/share/mozclient
+
+mk_files = \
+ firefox-3.0.mk \
+ lightning-sunbird.mk \
+ nspr.mk \
+ nss.mk \
+ seamonkey-2.0.mk \
+ thunderbird-3.0.mk \
+ xulrunner-1.9.mk \
+ mozclient.mk \
+ $(NULL)
+
+extra_mk_files = \
+ remove.binonly.sh \
+ $(NULL)
+
+%.mk: %.mk.in
+ cat $< | sed \
+ -e "s|^\(include\) \(.*\)|\1 $(DATADIR)/\2|" \
+ -e "s|^\(MOZCLIENT_EXCLUDE_SCRIPT.*=[ ][ ]*\)\(.*\)|\1$(DATADIR)/\2|" \
+ > $@
+ chmod 644 $@
+
+build: $(mk_files)
+
+install: $(mk_files) $(extra_mk_files)
+ install -m 755 -d $(DESTDIR)$(DATADIR)
+ install -m 644 $^ $(DESTDIR)$(DATADIR)
+
+clean:
+ rm -f $(mk_files)
diff --git a/src/firefox-3.0.mk.in b/src/firefox-3.0.mk.in
new file mode 100644
index 0000000..b0e65a1
--- /dev/null
+++ b/src/firefox-3.0.mk.in
@@ -0,0 +1,31 @@
+# -*- mode: makefile; coding: utf-8 -*-
+
+# Copyright (c) 2007 Fabien Tassin <fta@sofaraway.org>
+# Description: Project firefox 3.0
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+# 02111-1307 USA.
+
+MOZCLIENT_TARGET := firefox-3.0-orig
+MOZCLIENT_APPNAME := firefox-3.0
+MOZCLIENT_PROJECT := xulbrowser
+MOZCLIENT_FILE := mozilla/browser/config/version.txt
+MOZCLIENT_GETVERSION := sed -e 's/pre//; s/a\([0-9]*\)/~alpha\1/; s/b\([0-9]*\)/~b\1/' $(MOZCLIENT_FILE)
+MOZCLIENT_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=SeaMonkeyBrowser&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=week&mindate=&maxdate=&cvsroot=%2Fcvsroot'
+MOZCLIENT_GETDATE = wget -O - -q --read-timeout=10 --user-agent='' --tries=3 $(MOZCLIENT_URL) 2> /dev/null | grep "href='http://webtools" | head -1 | tr '<>' '@' | cut -d@ -f5 | tr -d ':-' | sed -e 's/&nbsp;/t/'
+MOZCLIENT_EMBEDDED := 1
+MOZCLIENT_WANTMOZDIR := 1
+
+include mozclient.mk
diff --git a/src/lightning-sunbird.mk.in b/src/lightning-sunbird.mk.in
new file mode 100644
index 0000000..d01abf9
--- /dev/null
+++ b/src/lightning-sunbird.mk.in
@@ -0,0 +1,32 @@
+# -*- mode: makefile; coding: utf-8 -*-
+
+# Copyright (c) 2007 Fabien Tassin <fta@sofaraway.org>
+# Description: Project Sunbird 0.* (MOZILLA_1_8_BRANCH)
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+# 02111-1307 USA.
+
+MOZCLIENT_TARGET := lightning-sunbird-orig
+MOZCLIENT_APPNAME := lightning-sunbird
+MOZCLIENT_PROJECT := calendar
+MOZCLIENT_BRANCH := MOZILLA_1_8_BRANCH
+MOZCLIENT_FILE := mozilla/calendar/sunbird/config/version.txt
+MOZCLIENT_GETVERSION := tail -1 $(MOZCLIENT_FILE) | sed -e 's/pre//; s/\([ab]\)\([0-9]*\)/~\1\2/'
+MOZCLIENT_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=CalendarClient&branch=MOZILLA_1_8_BRANCH&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=week&mindate=&maxdate=&cvsroot=%2Fcvsroot'
+MOZCLIENT_GETDATE = wget -O - -q --read-timeout=10 --user-agent='' --tries=3 $(MOZCLIENT_URL) 2> /dev/null | grep "href='http://webtools" | head -1 | tr '<>' '@' | cut -d@ -f5 | tr -d ':-' | sed -e 's/&nbsp;/t/'
+MOZCLIENT_EMBEDDED := 1
+MOZCLIENT_WANTMOZDIR := 1
+
+include mozclient.mk
diff --git a/src/mozclient.mk.in b/src/mozclient.mk.in
new file mode 100644
index 0000000..f81fc1e
--- /dev/null
+++ b/src/mozclient.mk.in
@@ -0,0 +1,204 @@
+# -*- mode: makefile; coding: utf-8 -*-
+
+# Copyright (c) 2007 Fabien Tassin <fta@sofaraway.org>
+# Description: The core of mozclient
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+# 02111-1307 USA.
+
+#####################################################################
+
+# Don't include this file directly, include one of the project.mk
+# file instead, which will include this file for you.
+
+# The caller could specify the following parameters:
+# DEBIAN_DATE in the form YYYYMMDDtHHMM
+# ex: DEBIAN_DATE=20070911t1711
+# or
+# DEBIAN_TAG in the form CVS_TAG=debian_version
+# ex: DEBIAN_TAG=FIREFOX_3_0b2_RC1=3.0~b2~rc1
+
+# The following targets are available to the caller:
+# - get-orig-source
+# Build a tarball according to parameters from project.mk
+# and optionally using either DEBIAN_DATE or DEBIAN_TAG
+# - mozclient-status
+# List all the registered CVS tags from upstream server
+
+# project.mk contains the following parameters
+# - MOZCLIENT_TARGET (mandatory): a label, usually 'project-orig'
+# - MOZCLIENT_APPNAME (mandatory): package name
+# - MOZCLIENT_PROJECT (mandatory): CVS project name
+# - MOZCLIENT_BRANCH (optional): CVS branch name
+# - MOZCLIENT_FILE (mandatory): source file containing the version
+# - MOZCLIENT_GETVERSION (mandatory): how to transform the version
+# - MOZCLIENT_URL (mandatory): an URL (usually on Bonsai) listing commits
+# - MOZCLIENT_GETDATE (mandatory): get the last commit date for the project
+# - MOZCLIENT_EMBEDDED (optional): create an embedded tarball (default: 0)
+# - MOZCLIENT_WANTMOZDIR (optional): should the root dir be 'mozilla'?
+# (default: 0 unless MOZCLIENT_EMBEDDED=1)
+
+# Example with firefox-3.0:
+#
+# - in debian/control, add mozclient to Build-Depends
+# - in debian/rules, add:
+# include /usr/share/mozclient/firefox-3.0.mk
+#
+# That's it. You've gained get-orig-source.
+#
+# You can now call it:
+# - debian/rules get-orig-source
+# => firefox-3.0_3.0~b2~cvs20071120t1456+nobinonly.orig.tar.gz
+#
+# - debian/rules get-orig-source DEBIAN_DATE=20070914t1713
+# => firefox-3.0_3.0~a8~cvs20070914t1713+nobinonly.orig.tar.gz
+#
+# - debian/rules get-orig-source DEBIAN_TAG=FIREFOX_3_0b2_RC1=3.0~b2~rc1
+# => firefox-3.0_3.0~b2~rc1+nobinonly.orig.tar.gz
+
+# Notes:
+# - the script 'remove.binonly.sh' is applied to all projects, in order
+# to remove binary-only files before packing. Traces of the cleaning
+# are preserved inside that resulting tarball in REMOVED+nobinonly.txt.
+# If nothing has been removed, the log and the "+nobinonly" signature
+# are both dropped.
+
+MOZ_CLIENT = mozilla/client.mk
+MOZCLIENT_CVS_LOC = :pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot
+
+MOZCLIENT_STAMP ?= stamped
+MOZCLIENT_TMP := mozclient-tmp
+
+MOZCLIENT_EXCLUDE_SCRIPT := remove.binonly.sh
+NOBINONLY := nobinonly
+
+TAR_EXCLUDE := --exclude=CVS --exclude=.cvsignore
+
+ifdef DEBIAN_TAG
+DEBIAN_DATE = $(NULL)
+DEBIAN_LTAG = $(shell echo $(DEBIAN_TAG) | sed -e 's/=.*//')
+DEBIAN_DTAG = $(shell echo $(DEBIAN_TAG) | sed -e 's/.*=//')
+DEBIAN_CO_TAG = -r $(DEBIAN_LTAG)
+DEBIAN_MOZ_CO_TAG = MOZ_CO_TAG=$(DEBIAN_LTAG)
+else
+DEBIAN_MOZ_CO_TAG = $(NULL)
+ifdef DEBIAN_DATE
+DEBIAN_CO_DATE = $(shell echo "-D \"$(DEBIAN_DATE)\"" | sed -e 's/[rt]/ /')
+endif
+ifdef DEBIAN_BRANCH
+DEBIAN_CO_TAG = -r $(DEBIAN_BRANCH)
+endif
+endif
+
+############################################################################
+
+mozclient-deps:
+ @if [ ! -f /usr/bin/cvs ] ; then echo "**ERROR** Depends on missing cvs. Abort"; exit 1; fi
+ @if [ ! -f /usr/bin/quilt ] ; then echo "**ERROR** Depends on missing quilt. Abort"; exit 1; fi
+ @if [ ! -f /usr/bin/wget ] ; then echo "**ERROR** Depends on missing wget. Abort"; exit 1; fi
+
+# Get the client
+ifneq (,$(MOZCLIENT_BRANCH))
+$(MOZ_CLIENT): MOZCLIENT_TBRANCH = -r $(MOZCLIENT_BRANCH)
+else
+$(MOZ_CLIENT): MOZCLIENT_TBRANCH = $(NULL)
+endif
+$(MOZ_CLIENT): mozclient-deps
+ rm -rf $(MOZCLIENT_TMP)
+ mkdir $(MOZCLIENT_TMP)
+ cd $(MOZCLIENT_TMP) && cvs -d $(MOZCLIENT_CVS_LOC) co $(MOZCLIENT_TBRANCH) $(DEBIAN_CO_DATE) $(DEBIAN_CO_TAG) $@
+
+mozclient-client: $(MOZCLIENT_TMP)/$(MOZCLIENT_STAMP)
+
+# List all tags
+mozclient-status: $(MOZ_CLIENT)
+ cd $(MOZCLIENT_TMP)/mozilla && cvs status -v client.mk
+
+# Patch
+# - don't patch when a branch name is specified
+mozclient-patch: $(MOZCLIENT_TMP)/$(MOZCLIENT_STAMP)
+
+$(MOZCLIENT_TMP)/$(MOZCLIENT_STAMP): $(MOZ_CLIENT)
+ifeq (,$(MOZCLIENT_BRANCH))
+ if [ ! -L $(MOZCLIENT_TMP)/patches ] ; then ln -s ../../patches $(MOZCLIENT_TMP)/patches ; fi
+ cd $(MOZCLIENT_TMP) && quilt --quiltrc /dev/null push -a || test $$? = 2
+endif
+ touch $(MOZCLIENT_TMP)/$(MOZCLIENT_STAMP)
+
+# Unpatch
+mozclient-unpatch:
+ifeq (,$(MOZCLIENT_BRANCH))
+ cd $(MOZCLIENT_TMP) && quilt --quiltrc /dev/null pop -a -R || test $$? = 2
+endif
+ rm -rf $(MOZCLIENT_TMP)/.pc $(MOZCLIENT_TMP)/$(MOZCLIENT_STAMP) $(MOZCLIENT_TMP)/patches
+
+# Clean
+mozclient-clean:
+ rm -rf $(MOZCLIENT_TMP)
+
+# Checkout using either a TAG, a date or nothing (last commit date)
+ifneq (,$(DEBIAN_TAG))
+mozclient-checkout: MOZCLIENT_DATE = $(NULL)
+else
+ifneq (,$(DEBIAN_DATE))
+mozclient-checkout: MOZCLIENT_DATE = MOZ_CO_DATE="$(DEBIAN_DATE)"
+else
+mozclient-checkout: DEBIAN_DATE = $(shell $(MOZCLIENT_GETDATE))
+mozclient-checkout: MOZCLIENT_DATE = MOZ_CO_DATE="$(shell echo $(DEBIAN_DATE) | sed -e 's/[rt]/ /')"
+endif
+endif
+mozclient-checkout:
+ @echo DEBIAN_DATE=$(DEBIAN_DATE)
+ cd $(MOZCLIENT_TMP) && make -f $(MOZ_CLIENT) checkout MOZ_CO_PROJECT=$(MOZCLIENT_PROJECT) $(MOZCLIENT_DATE) $(DEBIAN_MOZ_CO_TAG)
+ @echo DEBIAN_DATE=$(DEBIAN_DATE)
+ echo $(DEBIAN_DATE) > $(MOZCLIENT_TMP)/.date
+
+# Remove bin-only files using the remove.binonly.sh script.
+# Keep a log in REMOVED+nobinonly.txt
+mozclient-remove-bin:
+ cd $(MOZCLIENT_TMP)/mozilla && sh ../../$(MOZCLIENT_EXCLUDE_SCRIPT) > REMOVED+$(NOBINONLY).txt 2>&1
+ if [ ! -s $(MOZCLIENT_TMP)/mozilla/REMOVED+$(NOBINONLY).txt ] ; then rm $(MOZCLIENT_TMP)/mozilla/REMOVED+$(NOBINONLY).txt ; fi
+
+# Pack
+# - only use the +nobinonly suffix is something has been deleted
+# - for embedded tarballs (bzipped), use MOZCLIENT_EMBEDDED=1
+# - to preserve the mozilla root dir, use MOZCLIENT_WANTMOZDIR=1
+ifneq (,$(DEBIAN_TAG))
+mozclient-pack: MOZCLIENT_TVERSION = $(DEBIAN_DTAG)
+else
+mozclient-pack: MOZCLIENT_TVERSION = $(shell cd $(MOZCLIENT_TMP) && $(MOZCLIENT_GETVERSION))~cvs$(shell cat $(MOZCLIENT_TMP)/.date)
+endif
+mozclient-pack: MOZCLIENT_VERSION = $(MOZCLIENT_TVERSION)$(shell test -f $(MOZCLIENT_TMP)/mozilla/REMOVED+$(NOBINONLY).txt && echo "+$(NOBINONLY)")
+mozclient-pack:
+ rm -rf $(MOZCLIENT_TMP)/$(MOZCLIENT_APPNAME)-$(MOZCLIENT_VERSION)
+ifneq (,$(findstring 1,$(MOZCLIENT_WANTMOZDIR)$(MOZCLIENT_EMBEDDED)))
+ mkdir $(MOZCLIENT_TMP)/$(MOZCLIENT_APPNAME)-$(MOZCLIENT_VERSION)
+endif
+ifeq (1,$(MOZCLIENT_EMBEDDED))
+ cd $(MOZCLIENT_TMP) && tar jcf $(MOZCLIENT_APPNAME)-$(MOZCLIENT_VERSION)/$(MOZCLIENT_PROJECT)-$(MOZCLIENT_TVERSION)-source.tar.bz2 $(TAR_EXCLUDE) mozilla
+else
+ mv $(MOZCLIENT_TMP)/mozilla $(MOZCLIENT_TMP)/$(MOZCLIENT_APPNAME)-$(MOZCLIENT_VERSION)
+endif
+ rm -f $(MOZCLIENT_APPNAME)_$(MOZCLIENT_VERSION).orig.tar.gz
+ cd $(MOZCLIENT_TMP) && tar zcf ../$(MOZCLIENT_APPNAME)_$(MOZCLIENT_VERSION).orig.tar.gz $(TAR_EXCLUDE) $(MOZCLIENT_APPNAME)-$(MOZCLIENT_VERSION)
+ rm -rf $(MOZCLIENT_TMP)
+ -ls -l $(MOZCLIENT_APPNAME)_$(MOZCLIENT_VERSION).orig.tar.gz
+
+# The real target
+$(MOZCLIENT_TARGET): $(MOZ_CLIENT) $(MOZCLIENT_TMP)/$(MOZCLIENT_STAMP) mozclient-checkout mozclient-remove-bin mozclient-pack
+
+get-orig-source: $(MOZCLIENT_TARGET)
+
+.PHONY: mozclient-patch mozclient-unpatch mozclient-checkout mozclient-remove-bin mozclient-pack $(MOZCLIENT_TARGET) get-orig-source
diff --git a/src/nspr.mk.in b/src/nspr.mk.in
new file mode 100644
index 0000000..ece12da
--- /dev/null
+++ b/src/nspr.mk.in
@@ -0,0 +1,30 @@
+# -*- mode: makefile; coding: utf-8 -*-
+
+# Copyright (c) 2007 Fabien Tassin <fta@sofaraway.org>
+# Description: Project NSPR
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+# 02111-1307 USA.
+
+MOZCLIENT_TARGET := nspr-orig
+MOZCLIENT_APPNAME := nspr
+MOZCLIENT_PROJECT := nspr
+MOZCLIENT_FILE := mozilla/nsprpub/configure.in
+MOZCLIENT_GETVERSION := grep -E '^MOD_(MAJOR|MINOR|PATCH)_VERSION' $(MOZCLIENT_FILE) | cut -d= -f2 | tr '\n' '.' | sed -e 's,\.$$,,'
+MOZCLIENT_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=all&branch=HEAD&branchtype=match&dir=mozilla%2Fnsprpub&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=explicit&mindate=1177522884&maxdate=1588258884&cvsroot=%2Fcvsroot'
+MOZCLIENT_GETDATE = wget -O - -q --read-timeout=10 --user-agent='' --tries=3 $(MOZCLIENT_URL) 2> /dev/null | grep "href='http://webtools" | head -1 | tr '<>' '@' | cut -d@ -f5 | tr -d ':-' | sed -e 's/&nbsp;/t/'
+MOZCLIENT_WANTMOZDIR := 1
+
+include mozclient.mk
diff --git a/src/nss.mk.in b/src/nss.mk.in
new file mode 100644
index 0000000..c9cde27
--- /dev/null
+++ b/src/nss.mk.in
@@ -0,0 +1,30 @@
+# -*- mode: makefile; coding: utf-8 -*-
+
+# Copyright (c) 2007 Fabien Tassin <fta@sofaraway.org>
+# Description: Project NSS
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+# 02111-1307 USA.
+
+MOZCLIENT_TARGET := nss-orig
+MOZCLIENT_APPNAME := nss
+MOZCLIENT_PROJECT := nss
+MOZCLIENT_FILE := mozilla/security/nss/lib/nss/nss.h
+MOZCLIENT_GETVERSION := grep -E '^\#define NSS_V(MAJOR|MINOR|PATCH)' $(MOZCLIENT_FILE) | awk '{print $$3}' | tr '\n' '.' | sed -e 's,\.$$,,'
+MOZCLIENT_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=NSS&module=all&branch=HEAD&branchtype=match&dir=mozilla%2Fdbm+mozilla%2Fsecurity%2Fnss+mozilla%2Fsecurity%2Fcoreconf+mozilla%2Fsecurity%2Fdbm&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=month&mindate=&maxdate=&cvsroot=%2Fcvsroot'
+MOZCLIENT_GETDATE = wget -O - -q --read-timeout=10 --user-agent='' --tries=3 $(MOZCLIENT_URL) 2> /dev/null | grep "href='http://webtools" | head -1 | tr '<>' '@' | cut -d@ -f5 | tr -d ':-' | sed -e 's/&nbsp;/t/'
+MOZCLIENT_WANTMOZDIR := 1
+
+include mozclient.mk
diff --git a/remove.binonly.sh b/src/remove.binonly.sh
index df04617..df04617 100644
--- a/remove.binonly.sh
+++ b/src/remove.binonly.sh
diff --git a/src/seamonkey-2.0.mk.in b/src/seamonkey-2.0.mk.in
new file mode 100644
index 0000000..b9ac04d
--- /dev/null
+++ b/src/seamonkey-2.0.mk.in
@@ -0,0 +1,30 @@
+# -*- mode: makefile; coding: utf-8 -*-
+
+# Copyright (c) 2007 Fabien Tassin <fta@sofaraway.org>
+# Description: Project SeaMonkey 2.0
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+# 02111-1307 USA.
+
+MOZCLIENT_TARGET := seamonkey-2.0.orig
+MOZCLIENT_APPNAME := seamonkey-2.0
+MOZCLIENT_PROJECT := suite
+MOZCLIENT_FILE := mozilla/suite/config/version.txt
+MOZCLIENT_GETVERSION := tail -1 $(MOZCLIENT_FILE) | sed -e 's/pre//; s/\([ab]\)\([0-9]*\)/~\1\2/'
+MOZCLIENT_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=SeaMonkeyBrowser&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=week&mindate=&maxdate=&cvsroot=%2Fcvsroot'
+MOZCLIENT_GETDATE = wget -O - -q --read-timeout=10 --user-agent='' --tries=3 $(MOZCLIENT_URL) 2> /dev/null | grep "href='http://webtools" | head -1 | tr '<>' '@' | cut -d@ -f5 | tr -d ':-' | sed -e 's/&nbsp;/t/'
+MOZCLIENT_WANTMOZDIR := 0
+
+include mozclient.mk
diff --git a/src/thunderbird-3.0.mk.in b/src/thunderbird-3.0.mk.in
new file mode 100644
index 0000000..587bb90
--- /dev/null
+++ b/src/thunderbird-3.0.mk.in
@@ -0,0 +1,30 @@
+# -*- mode: makefile; coding: utf-8 -*-
+
+# Copyright (c) 2007 Fabien Tassin <fta@sofaraway.org>
+# Description: Project Thunderbird 3.0
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+# 02111-1307 USA.
+
+MOZCLIENT_TARGET := thunderbird-3.0-orig
+MOZCLIENT_APPNAME := thunderbird-3.0
+MOZCLIENT_PROJECT := mail
+MOZCLIENT_FILE := mozilla/mail/config/version.txt
+MOZCLIENT_GETVERSION := tail -1 $(MOZCLIENT_FILE) | sed -e 's/pre//; s/\([ab]\)\([0-9]*\)/~\1\2/'
+MOZCLIENT_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=SeaMonkeyMailNews&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=week&mindate=&maxdate=&cvsroot=%2Fcvsroot'
+MOZCLIENT_GETDATE = wget -O - -q --read-timeout=10 --user-agent='' --tries=3 $(MOZCLIENT_URL) 2> /dev/null | grep "href='http://webtools" | head -1 | tr '<>' '@' | cut -d@ -f5 | tr -d ':-' | sed -e 's/&nbsp;/t/'
+MOZCLIENT_WANTMOZDIR := 1
+
+include mozclient.mk
diff --git a/src/xulrunner-1.9.mk.in b/src/xulrunner-1.9.mk.in
new file mode 100644
index 0000000..6cd0c1c
--- /dev/null
+++ b/src/xulrunner-1.9.mk.in
@@ -0,0 +1,30 @@
+# -*- mode: makefile; coding: utf-8 -*-
+
+# Copyright (c) 2007 Fabien Tassin <fta@sofaraway.org>
+# Description: Project XULRunner 1.9
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2, or (at
+# your option) any later version.
+#
+# This program is distributed in the hope that it will be useful, but
+# WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+# General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+# 02111-1307 USA.
+
+MOZCLIENT_TARGET := xulrunner-1.9-orig
+MOZCLIENT_APPNAME := xulrunner-1.9
+MOZCLIENT_PROJECT := xulrunner
+MOZCLIENT_FILE := mozilla/config/milestone.txt
+MOZCLIENT_GETVERSION := tail -1 $(MOZCLIENT_FILE) | sed -e 's/pre//; s/\([ab]\)\([0-9]*\)/~\1\2/'
+MOZCLIENT_URL := 'http://bonsai.mozilla.org/cvsquery.cgi?treeid=default&module=SeaMonkeyBrowser&branch=HEAD&branchtype=match&dir=&file=&filetype=match&who=&whotype=match&sortby=Date&hours=2&date=week&mindate=&maxdate=&cvsroot=%2Fcvsroot'
+MOZCLIENT_GETDATE = wget -O - -q --read-timeout=10 --user-agent='' --tries=3 $(MOZCLIENT_URL) 2> /dev/null | grep "href='http://webtools" | head -1 | tr '<>' '@' | cut -d@ -f5 | tr -d ':-' | sed -e 's/&nbsp;/t/'
+MOZCLIENT_WANTMOZDIR := 1
+
+include mozclient.mk