s/stx/benchmark-runner.rc
author Jan Vrany <jan.vrany@fit.cvut.cz>
Fri, 18 Mar 2016 22:41:49 +0000
changeset 312 c9a8fa71d8fc
parent 270 c50baf9166d2
permissions -rw-r--r--
Web: Fixed filtering by tags in "Results" page "Results" page not allow for filtering by tags. * If both, configuration and tags are specified, only reports for specified configurations AND with at least one of the specified tags are shown. * If only tags are specified, then all reports on all configurations having at keast one of specified tags are shown. Kudos to Jan Kurs for forcing me to fix this :-)

| pp wd i p |

Smalltalk silentLoading:true.

"Search for package path, bit hacky but..."
wd := OperatingSystem pathOfSTXExecutable asFilename directory.
pp := nil.
p := wd.
i := 10."How many super-directories try"
[i > 0 and:[pp == nil]] whileTrue:[
	p := p / '..'. i := i - 1.
	((p / 'stx' / 'libbasic') exists and:[(p / 'stx' / 'libcomp') exists])
		ifTrue:[pp := p]].
pp
	ifNil:
		[Stderr nextPutAll: 'ERROR: Cannot find package path'.
		Smalltalk exit: 16]
	ifNotNil:
		[Smalltalk packagePath add: pp pathName].

(Smalltalk commandLineArguments includes:'--debug') ifTrue:[
    Stderr nextPutAll:'Package path:'; cr.
    Smalltalk packagePath do:[:each|
       Stderr nextPutAll:'  '; nextPutAll: each; cr.
    ].

    Smalltalk beHeadless: (OperatingSystem getEnvironment: 'DISPLAY') isNil.
] ifFalse: [
	Smalltalk beHeadless: true.
].

(Smalltalk at:#'BenchmarkRunner') isNil ifTrue:[
    (Smalltalk loadPackage: 'jv:calipel/s') ifFalse:[
	Stderr nextPutAll:'ERROR: cannot load jv:calipel/s'.
	Smalltalk exit: 17
    ].
].
(Smalltalk at:#'BenchmarkPlatformStX') initialize.

(Smalltalk at:#'BenchmarkRunnerAdapterStX') isNil ifTrue:[
    (Smalltalk loadPackage: 'jv:calipel/s/stx') ifFalse:[
	Stderr nextPutAll:'ERROR: cannot load jv:calipel/s/stx'.
	Smalltalk exit: 17
    ].
].



(Smalltalk at:#'BenchmarkRunnerAdapterStX') start.