Kiln » TortoiseHg » WinBuild Read More
Clone URL:  
Pushed to one repository · View In Graph Contained in tip

reconfigure relative paths, source repos are at same level as thg-winbuild

* thg-winbuild now expects to exist as an hg-build subrepo
* hg-main renamed to hg
* dulwich updated to 0.8.0
* cleanup ignore filter

Changeset 8145a2a26fe2

Parent be36d975ec40

by Steve Borho

Changes to 4 files · Browse files at 8145a2a26fe2 Showing diff from parent be36d975ec40 Diff from another changeset...

Change 1 of 1 Show Entire File .hgignore Stacked
 
1
2
3
4
 
5
6
7
8
9
10
 
1
 
2
3
4
5
6
7
8
 
9
@@ -1,10 +1,9 @@
 syntax: glob -output/  misc/ThgShellx??.dll  misc/terminate.exe +misc/cacert.pem  *.pfx  *~  *.pyc  .*.swp -misc/cacert.pem  *key*
Change 1 of 3 Show Entire File README.txt Stacked
 
1
2
3
 
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
 
120
121
122
123
 
124
125
126
 
140
141
142
143
 
 
1
2
 
3
4
5
6
7
 
 
 
 
 
 
 
 
 
 
 
 
8
9
10
 
108
109
110
 
111
112
113
114
 
128
129
130
 
131
@@ -1,22 +1,10 @@
 TortoiseHg and Mercurial installer builder for Windows   -Repository subdirs: +Contents:    contrib/ - Bundled libraries and utilities external to (T)HG  misc/ - Miscellaneous files used to build packages   -Clones (setup.py will create these clones at runtime): - -hg-main - Mercurial repository -thg - TortoiseHg repository -hgfold - case folding conflict detection and resolution extension -keyring - python-keyring-lib -hgkeyring - mercurial keyring extension -perfarce - perforce integration extension -fixfrozenexts - allow 'hg help extensions' to work on Windows -iniparse - allow thg to apply changes to ini (hgrc) files -dulwich - Python interface to git repositories -  === Mercurial Prerequisites ===    - Python 2.6.6 @@ -120,7 +108,7 @@
  http://sourceforge.net/projects/pywin32/   pywin32-216.win32-py2.6.exe   -- comtypes (optional, for BugTraq) +- comtypes (no longer optional)     comtypes-0.6.2.win32.exe from   http://sourceforge.net/projects/comtypes/files/ @@ -140,4 +128,4 @@
   To build x64 packages, you use:   -C:\python26_x64\python.exe setup.py --help +C:\python26x64\python.exe setup.py --help
 
2
3
4
5
 
6
7
 
8
9
10
 
 
11
12
13
 
2
3
4
 
5
6
 
7
8
 
 
9
10
11
12
13
@@ -2,12 +2,12 @@
    hgfold: 0d5ced144f81 https://bitbucket.org/bradobro/hgfold/   perfarce: 31fbf702b844 http://www.kingswood-consulting.co.uk/hg/perfarce/ - keyring: 2b131278feee https://bitbucket.org/kang/python-keyring-lib/ + keyring: 31f21c5c87e0 https://bitbucket.org/kang/python-keyring-lib/   hgkeyring: 476937ac8644 https://bitbucket.org/Mekk/mercurial_keyring/ - dulwich: 48bef37ec98d https://bitbucket.org/abderrahim/dulwich/ + dulwich: ed3596b25fd1 https://bitbucket.org/abderrahim/dulwich/   iniparse: bd83edee7300 https://bitbucket.org/sborho/iniparse/ - zipdoc: cde7b15f4d53 https://bitbucket.org/gobell/hg-zipdoc/ - hgcr-gui: dcc0160aef78 https://bitbucket.org/glimchb/hgcr-gui/ + zipdoc: a2ca45ccfd64 https://bitbucket.org/gobell/hg-zipdoc/ + hgcr-gui: 227f2eee94e6 https://bitbucket.org/glimchb/hgcr-gui/   python-svn: 1.6.13 http://bitbucket.org/tortoisehg/thg/downloads   pygments: 1.4 http://pygments.org/download/   pywin32: 216 http://sourceforge.net/projects/pywin32/
Change 1 of 20 Show Entire File setup.py Stacked
 
63
64
65
66
 
67
68
69
 
87
88
89
90
 
91
92
93
 
103
104
105
106
 
107
108
109
 
118
119
120
121
122
123
124
125
126
127
128
129
130
 
254
255
256
257
 
258
259
260
 
312
313
314
315
 
316
317
318
 
323
324
325
326
 
327
328
329
 
341
342
343
344
 
345
346
 
347
348
349
 
364
365
366
 
367
368
369
370
 
371
372
373
 
378
379
380
 
381
382
383
 
480
481
482
483
 
484
485
486
 
563
564
565
566
567
568
 
 
 
 
 
 
569
570
571
 
655
656
657
658
 
659
660
661
 
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
 
712
713
714
715
716
717
718
 
722
723
724
725
726
727
728
729
 
733
734
735
736
737
738
739
 
740
741
742
743
744
745
 
747
748
749
750
751
752
753
 
763
764
765
766
767
768
769
770
 
782
783
784
785
786
787
788
789
 
790
791
 
792
793
794
795
796
797
 
798
799
 
800
801
802
 
 
803
804
805
 
820
821
822
823
824
825
826
827
 
63
64
65
 
66
67
68
69
 
87
88
89
 
90
91
92
93
 
103
104
105
 
106
107
108
109
 
118
119
120
 
 
 
 
 
 
 
121
122
123
 
247
248
249
 
250
251
252
253
 
305
306
307
 
308
309
310
311
 
316
317
318
 
319
320
321
322
 
334
335
336
 
337
338
 
339
340
341
342
 
357
358
359
360
361
362
363
 
364
365
366
367
 
372
373
374
375
376
377
378
 
475
476
477
 
478
479
480
481
 
558
559
560
 
 
 
561
562
563
564
565
566
567
568
569
 
653
654
655
 
656
657
658
659
 
695
696
697
 
698
699
 
 
700
701
702
703
704
705
 
706
707
708
 
 
709
710
711
 
715
716
717
 
 
718
719
720
 
724
725
726
 
727
728
 
729
730
731
 
732
733
734
 
736
737
738
 
739
740
741
 
751
752
753
 
 
754
755
756
 
768
769
770
 
 
 
771
 
772
773
 
774
775
776
777
778
779
 
780
781
 
782
783
 
 
784
785
786
787
788
 
803
804
805
 
 
806
807
808
@@ -63,7 +63,7 @@
 sslcertfile = 'misc/cacert.pem'    URL = { - 'hg-main' : 'http://selenic.com/repo/hg/', + 'hg' : 'http://selenic.com/repo/hg/',   'cacert.pem': 'http://curl.haxx.se/ca/cacert.pem',   'perfarce' : 'http://www.kingswood-consulting.co.uk/hg/perfarce/',   'thg' : 'https://bitbucket.org/tortoisehg/thg/', @@ -87,7 +87,7 @@
  'hgcr-gui',   ]   -thg_source_repos = ['thg', 'hg-main'] + extensions +thg_source_repos = ['thg', 'hg'] + extensions    extfiles = {   'hgfold': ['hgfold/fold.py'], @@ -103,7 +103,7 @@
 # Specify the exact revision to ship for given extension  extversions = {   'iniparse': 'bd83edee7300ce0a4fdddc3eddf743dc6ea98602', # 0.4 - 'dulwich' : '48bef37ec98db39dca1a80669303fd8f5c6608e1', # 0.7.1 + 'dulwich' : 'ed3596b25fd1039b880c2f46cb38202a6289be95', # 0.8.0  }    # Extensions which require compiled C++ Python extensions @@ -118,13 +118,6 @@
 else:   arch = 'x86'   -def checkrepo(name, ver=''): - if os.path.isdir(name): - return - run(r'hg clone -U %s file:%s' % (URL[name], name)) - run(r'hg update -R %s %s' % (name, ver)) - -  def run(cmd, cwd='.', hide=False, env=installenv):   if not hide:   print cwd + "> " + cmd @@ -254,7 +247,7 @@
    if force or not os.path.exists('build-hg'):   run(r'if exist build-hg rmdir /s /q build-hg') - run(r'hg clone file:hg-main -u %s file:build-hg' % branch) + run(r'hg clone file:../hg -u %s file:build-hg' % branch)   else:   run(r'hg -R build-hg pull')   run(r'hg -R build-hg update ' + branch) @@ -312,7 +305,7 @@
  print "signing using cert '%s'" % (cert,)   desc = '%s %s' % (name, version)   sign(r'dist\hg.exe', desc, 'build-hg') - package = r'..\output\%s-%s-%s.msi' % (name, version, arch) + package = r'..\..\output\%s-%s-%s.msi' % (name, version, arch)   wixobj = [   (r'..\build-hg\contrib\wix\help.wxs', r'..\build-hg\mercurial\help'),   (r'..\build-hg\contrib\wix\templates.wxs', r'..\build-hg\mercurial\templates'), @@ -323,7 +316,7 @@
  (r'..\build-hg\contrib\wix\contrib.wxs', r'..\build-hg\contrib')]   for file, sourcedir in wixobj:   candle(file, sourcedir=sourcedir, cwd='build-hg', defines=[('Platform', arch)]) - candle(r'..\hg-main\contrib\wix\mercurial.wxs', cwd='build-hg', defines=[ + candle(r'..\build-hg\contrib\wix\mercurial.wxs', cwd='build-hg', defines=[   ('Platform', arch),   ('Version', version),   ('Comments', comments), @@ -341,9 +334,9 @@
    if force or not os.path.exists('build-thg'):   run(r'if exist build-thg rmdir /s /q build-thg') - run(r'hg clone file:thg -u %s file:build-thg' % branch) + run(r'hg clone file:../thg -u %s file:build-thg' % branch)   else: - run(r'hg pull ../thg', 'build-thg') + run(r'hg pull ../../thg', 'build-thg')   run(r'hg update ' + branch, 'build-thg')   if tag == 'tip':   run(r'hg update', 'build-thg') @@ -364,10 +357,11 @@
  # Copy bundled Mercurial extensions into build-hg/hgext   for ext in extensions:   for loc in extfiles.get(ext, []): + loc = '../' + loc   if os.path.exists(loc):   shutil.copy(loc, 'build-hg/hgext')   if ext == 'hgcr-gui': - shutil.copy('hgcr-gui/hgcr.ui', 'build-thg/tortoisehg/hgqt') + shutil.copy('../hgcr-gui/hgcr.ui', 'build-thg/tortoisehg/hgqt')     generate_hgext_index(branch)   @@ -378,6 +372,7 @@
  # compile all Mercurial extensions that have C++ Python extensions   for ext in extensions:   if ext in compiled_extensions: + ext = '../' + ext   run(r'hg --config extensions.purge= purge --all', ext)   run_python(r'setup.py build_ext -i', ext, env=get_sdkenv(arch))   @@ -480,7 +475,7 @@
  for file, sourcedir in wixobj:   candle(file, sourcedir=sourcedir, cwd='build-thg', defines=defs)   - package = "..\output\%s-%s" % (name, thgversion) + package = r"..\..\output\%s-%s" % (name, thgversion)   commentsfmt = 'Installs TortoiseHg %s, Mercurial %s on %s'   comments = commentsfmt % (longthgversion, hgversion, arch)   productid = productid.lower() @@ -563,9 +558,12 @@
  if found:   path.append(os.path.dirname(found))   else: - print 'Unable to find msgfmt. Please download from' - print 'http://gnuwin32.sourceforge.net/packages/gettext.htm' - sys.exit(1) + if os.path.exists(r'\MinGW\bin\msgfmt.exe'): + path.append(r'\MinGW\bin') + else: + print 'Unable to find msgfmt. Please download from' + print 'http://gnuwin32.sourceforge.net/packages/gettext.htm' + sys.exit(1)     if 'WIX' in installenv:   path.append(installenv['WIX'] + 'bin') @@ -655,7 +653,7 @@
  path = ['../build-hg']   for ext in extensions:   if ext in path_extensions: - path.append('../' + ext) + path.append('../../' + ext)   path.extend(oldpath)   installenv['PYTHONPATH'] = os.pathsep.join(path)   @@ -697,22 +695,17 @@
  os.unlink(sslcertfile)   sys.exit(0)   elif opt == '--thg-doc': - checkrepo('thg')   builddoc = True   elif opt == '--thg-release': - for r in thg_source_repos: - checkrepo(r)   if dopull is None:   dopull = True   buildthg = True   thgbranch = 'stable'   thgtag = lasttag('thg', 'stable')   hgbranch = 'stable' - hgtag = lasttag('hg-main', 'stable') + hgtag = lasttag('hg', 'stable')   packagename = 'tortoisehg'   elif opt == '--thg-stable': - for r in thg_source_repos: - checkrepo(r)   if dopull is None:   dopull = True   buildthg = True @@ -722,8 +715,6 @@
  hgtag = 'tip'   packagename = 'tortoisehg-stable'   elif opt == '--thg-unstable': - for r in thg_source_repos: - checkrepo(r)   if dopull is None:   dopull = True   buildthg = True @@ -733,13 +724,11 @@
  hgtag = 'tip'   packagename = 'tortoisehg-unstable'   elif opt == '--hg-release': - checkrepo('hg-main')   buildhg = True   hgbranch = 'stable' - hgtag = lasttag('hg-main', 'stable') + hgtag = lasttag('hg', 'stable')   packagename = 'mercurial'   elif opt == '--hg-stable': - checkrepo('hg-main')   if dopull is None:   dopull = True   buildhg = True @@ -747,7 +736,6 @@
  hgtag = 'tip'   packagename = 'mercurial-stable'   elif opt == '--hg-unstable': - checkrepo('hg-main')   if dopull is None:   dopull = True   buildhg = True @@ -763,8 +751,6 @@
  elif opt == '--only-msi':   onlymsi = True   elif opt == '--all': - for r in thg_source_repos: - checkrepo(r)   all = True   onlymsi = False   if dopull is None: @@ -782,24 +768,21 @@
  contents = urllib2.urlopen(URL['cacert.pem']).read()   file(sslcertfile, 'wb').write(contents)   -if not os.path.isdir('output'): - run(r'mkdir output') -  if dopull and not onlymsi: - run(r'hg -R hg-main pull') + run(r'hg -R ../hg pull')   if buildthg or all: - run(r'hg -R thg pull') + run(r'hg -R ../thg pull')   from mercurial import ui, hg   out = 'extension-versions.txt'   f = open(out, 'w')   f.write('Extensions/modules included in this TortoiseHg package:\n\n')   for ext in extensions: - run(r'hg -R %s pull' % ext) + run(r'hg -R ../%s pull' % ext)   if ext in extversions: - run(r'hg update %s' % extversions[ext], ext) + run(r'hg update -R ../%s %s' % (ext, extversions[ext]))   else: - run(r'hg update', ext) - repo = hg.repository(ui.ui(), path=ext) + run(r'hg update -R ../' + ext) + repo = hg.repository(ui.ui(), path='../'+ext)   f.write('%12s:\t%s\t%s\n' % (ext, str(repo['.']), URL[ext]))   try:   from svn import core @@ -820,8 +803,6 @@
  ver = open(pywin32file, 'r').read().strip()   url = 'http://sourceforge.net/projects/pywin32/'   f.write('%12s:\t%-12s\t%s\n' % ('pywin32', ver, url)) - repo = hg.repository(ui.ui(), path='.') - f.write('\n\nBuilt with thg-winbuild revision %s\n' % str(repo['.']))   f.close()    if all: