1: [[!meta title="How to update pkgsrc/www/firefox"]]
2:
3: This article shows you how to update pkgsrc/www/firefox package to latest
4: release.
5: You can use Mozilla's Mercurial (hg) repositories to track upstream changes.
6:
7: You should have pkgsrc/meta-pkgs/pkg_developer package
8: and pkgsrc/devel/py-mercurial package.
9:
10: # Clone hg tree
11: See <http://mozilla-version-control-tools.readthedocs.io/en/latest/hgmozilla/unifiedrepo.html>
12:
13: You should follow "Working with the Unified Repo" section.
14: In short, run:
15:
16: $ hg clone https://hg.mozilla.org/mozilla-unified
17:
18: # Update trees to latest
19:
20: $ hg update
21:
22:
23: # Checkout last release source, and create your branch
24:
25: Find latest release.
26:
27: $ hg tags|grep 50_
28: (snip)
29: FIREFOX_50_1_0_RELEASE 359965:8612c3320053
30: (snip)
31:
32: Checkout the branch.
33:
34: $ hg checkout FIREFOX_50_1_0_RELEASE
35:
36: Create named branch for applying pkgsrc patches
37:
38: $ hg branch pkgsrc_firefox-50.1.0
39: $ hg commit -m "Create pkgsrc_firefox-50.1.0 branch for applying pkgsrc patches"
40:
41: Add .*\.orig$ to .hgignore, and commit this change
42:
43: $ hg commit -m "Ignore .orig files" .hgignore
44:
45:
46: # Apply pkgsrc patches
47:
48: $ pushd /usr/pkgsrc/www/firefox
49: $ mkpatches -c
50: $ popd
51: $ cat /usr/pkgsrc/www/firefox/patches/patch-*|patch -p0
52: $ hg add ...(necessary files)
53: $ hg commit -m "Apply pkgsrc patches for firefox-50.1.0nb3"
54:
55:
56: # Checkout latest beta source, and create your branch
57:
58: Find latest branch.
59:
60: $ hg tags | grep 51_
61: (snip)
62: FIREFOX_51_0b14_RELEASE 364880:09142d07fd73
63: (snip)
64:
65: Checkout the branch.
66:
67: $ hg checkout FIREFOX_51_0b14_RELEASE
68:
69: Create named branch for working.
70:
71: $ hg branch ryoon_firefox-51.0
72: $ hg commit -m "Create ryoon_firefox-51.0 branch for merging pkgsrc patches"
73:
74: Add .*\.orig$ to .hgignore, and commit this change
75:
76: $ hg commit -m "Ignore .orig files" .hgignore
77:
78: # Merge your patches
79:
80: $ hg merge pkgsrc_firefox-50.1.0
81: $ hg resolve -l
82: $ vi file/marked/as/U
83: $ hg resolve --mark file/marked/as/U
84: (loop)
85: $ hg commit -m "Merge pkgsrc_firefox-50.1.0 branch to 51.0"
86:
87:
88: # Create patch file for patch -p0
89:
90: $ hg diff -r (revision of first commit in ryoon_firefox-51.0) | \
91: sed -e 's!^--- a/!--- !' -e 's!^+++ b/!+++ !' > ~/firefox-51.0.diff
92: $ vi ~/firefox-51.0.diff
93: (Remove patch to .hgignore)
94: (Remove patch to .hgtags)
95:
96: # Create patches/patch-* for pkgsrc/www/firefox
97:
98: $ cd /usr/pkgsrc/www/firefox
99: $ vi Makefile
100: (Update version)
101: (Remove PKGREVISION)
102: $ make mdi
103: $ make extract
104: $ pushd ${WRKOBJDIR}/www/firefox/work/${DISTNAME}
105: $ patch -p0 < ~/firefox-51.0.diff
106: $ popd
107: $ mkpatches
108: $ patchdiff
109: $ make mps
110:
111: # Test your patches
112:
113: $ make clean && make package
CVSweb for NetBSD wikisrc <wikimaster@NetBSD.org> software: FreeBSD-CVSweb