Merge remote-tracking branch 'origin/master' into modern-harvey3
commit
d5d552eb40
|
@ -106,7 +106,6 @@ CONSTANT: default-components
|
||||||
"stage2: deployment mode" print
|
"stage2: deployment mode" print
|
||||||
] [
|
] [
|
||||||
"debugger" require
|
"debugger" require
|
||||||
os unix? [ "debugger.unix" require ] when
|
|
||||||
"listener" require
|
"listener" require
|
||||||
] if
|
] if
|
||||||
|
|
||||||
|
|
|
@ -391,3 +391,5 @@ M: callsite-not-compiled summary
|
||||||
drop "Caller not compiled with the optimizing compiler" ;
|
drop "Caller not compiled with the optimizing compiler" ;
|
||||||
|
|
||||||
{ "threads" "debugger" } "debugger.threads" require-when
|
{ "threads" "debugger" } "debugger.threads" require-when
|
||||||
|
|
||||||
|
os unix? [ "debugger.unix" require ] when
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
! Copyright (C) 2009 Slava Pestov.
|
! Copyright (C) 2009 Slava Pestov.
|
||||||
! See http://factorcode.org/license.txt for BSD license.
|
! See http://factorcode.org/license.txt for BSD license.
|
||||||
USING: accessors debugger io kernel math prettyprint sequences
|
USING: debugger io kernel prettyprint sequences system
|
||||||
system unix.signals ;
|
unix.signals ;
|
||||||
IN: debugger.unix
|
IN: debugger.unix
|
||||||
|
|
||||||
: signal-name. ( n -- )
|
|
||||||
signal-name [ " (" ")" surround write ] when* ;
|
|
||||||
|
|
||||||
M: unix signal-error. ( obj -- )
|
M: unix signal-error. ( obj -- )
|
||||||
"Unix signal #" write
|
"Unix signal #" write
|
||||||
third [ pprint ] [ signal-name. ] bi nl ;
|
third [ pprint ] [ signal-name. ] bi nl ;
|
||||||
|
|
|
@ -1,12 +1,10 @@
|
||||||
USING: accessors calendar concurrency.promises continuations
|
USING: accessors calendar concurrency.promises destructors io
|
||||||
debugger.unix destructors io io.backend.unix io.directories
|
io.backend.unix io.directories io.encodings.ascii
|
||||||
io.encodings.ascii io.encodings.binary io.encodings.utf8
|
io.encodings.binary io.encodings.utf8 io.files io.launcher
|
||||||
io.files io.launcher io.launcher.unix io.streams.duplex
|
io.streams.duplex io.timeouts kernel libc locals math namespaces
|
||||||
io.timeouts kernel libc locals math namespaces sequences threads
|
sequences threads tools.test unix.process unix.signals ;
|
||||||
tools.test unix.process ;
|
|
||||||
IN: io.launcher.unix.tests
|
IN: io.launcher.unix.tests
|
||||||
|
|
||||||
|
|
||||||
[
|
[
|
||||||
{ } [ { "touch" "launcher-test-1" } try-process ] unit-test
|
{ } [ { "touch" "launcher-test-1" } try-process ] unit-test
|
||||||
|
|
||||||
|
|
|
@ -5,6 +5,7 @@ continuations environment fry io.backend io.backend.unix
|
||||||
io.files.private io.files.unix io.launcher io.launcher.private
|
io.files.private io.files.unix io.launcher io.launcher.private
|
||||||
io.pathnames io.ports kernel libc math namespaces sequences
|
io.pathnames io.ports kernel libc math namespaces sequences
|
||||||
simple-tokenizer strings system unix unix.ffi unix.process ;
|
simple-tokenizer strings system unix unix.ffi unix.process ;
|
||||||
|
QUALIFIED-WITH: unix.signals sig
|
||||||
IN: io.launcher.unix
|
IN: io.launcher.unix
|
||||||
|
|
||||||
: get-arguments ( process -- seq )
|
: get-arguments ( process -- seq )
|
||||||
|
@ -104,10 +105,8 @@ M: unix (kill-process) ( process -- )
|
||||||
: find-process ( handle -- process )
|
: find-process ( handle -- process )
|
||||||
processes get keys [ handle>> = ] with find nip ;
|
processes get keys [ handle>> = ] with find nip ;
|
||||||
|
|
||||||
TUPLE: signal n ;
|
|
||||||
|
|
||||||
: code>status ( code -- obj )
|
: code>status ( code -- obj )
|
||||||
dup WIFSIGNALED [ WTERMSIG signal boa ] [ WEXITSTATUS ] if ;
|
dup WIFSIGNALED [ WTERMSIG sig:signal boa ] [ WEXITSTATUS ] if ;
|
||||||
|
|
||||||
M: unix (wait-for-processes) ( -- ? )
|
M: unix (wait-for-processes) ( -- ? )
|
||||||
{ int } [ -1 swap WNOHANG waitpid ] with-out-parameters
|
{ int } [ -1 swap WNOHANG waitpid ] with-out-parameters
|
||||||
|
|
|
@ -11,7 +11,7 @@ IN: openssl.libcrypto
|
||||||
|
|
||||||
<< "libcrypto" {
|
<< "libcrypto" {
|
||||||
{ [ os windows? ] [ "libcrypto-37.dll" ] }
|
{ [ os windows? ] [ "libcrypto-37.dll" ] }
|
||||||
{ [ os macosx? ] [ { "libcrypto.46.dylib" "libcrypto.44.dylib" } find-library-from-list ] }
|
{ [ os macosx? ] [ { "libcrypto.46.dylib" "libcrypto.44.dylib" "libcrypto.dylib" } find-library-from-list ] }
|
||||||
{ [ os unix? ] [ "libcrypto.so" ] }
|
{ [ os unix? ] [ "libcrypto.so" ] }
|
||||||
} cond cdecl add-library >>
|
} cond cdecl add-library >>
|
||||||
|
|
||||||
|
|
|
@ -9,7 +9,7 @@ IN: openssl.libssl
|
||||||
|
|
||||||
<< "libssl" {
|
<< "libssl" {
|
||||||
{ [ os windows? ] [ "libssl-38.dll" ] }
|
{ [ os windows? ] [ "libssl-38.dll" ] }
|
||||||
{ [ os macosx? ] [ { "libssl.44.dylib" "libssl.42.dylib" } find-library-from-list ] }
|
{ [ os macosx? ] [ { "libssl.44.dylib" "libssl.42.dylib" "libssl.dylib" } find-library-from-list ] }
|
||||||
{ [ os unix? ] [ "libssl.so" ] }
|
{ [ os unix? ] [ "libssl.so" ] }
|
||||||
} cond cdecl add-library >>
|
} cond cdecl add-library >>
|
||||||
|
|
||||||
|
|
|
@ -59,7 +59,7 @@ delete-staging-images
|
||||||
! { } [ "bunny" shake-and-bake 2559640 small-enough? ] long-unit-test
|
! { } [ "bunny" shake-and-bake 2559640 small-enough? ] long-unit-test
|
||||||
{ } [ "bunny" shake-and-bake 2700000 small-enough? ] long-unit-test
|
{ } [ "bunny" shake-and-bake 2700000 small-enough? ] long-unit-test
|
||||||
|
|
||||||
{ } [ "gpu.demos.bunny" shake-and-bake 3650000 small-enough? ] long-unit-test
|
{ } [ "gpu.demos.bunny" shake-and-bake 3660000 small-enough? ] long-unit-test
|
||||||
|
|
||||||
os macosx? [
|
os macosx? [
|
||||||
[ ] [ "webkit-demo" shake-and-bake 600000 small-enough? ] long-unit-test
|
[ ] [ "webkit-demo" shake-and-bake 600000 small-enough? ] long-unit-test
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
! Copyright (C) 2011 Joe Groff.
|
! Copyright (C) 2011 Joe Groff.
|
||||||
! See http://factorcode.org/license.txt for BSD license.
|
! See http://factorcode.org/license.txt for BSD license.
|
||||||
USING: accessors assocs kernel math namespaces sequences threads ;
|
USING: accessors assocs io kernel math namespaces sequences
|
||||||
|
system threads ;
|
||||||
IN: unix.signals
|
IN: unix.signals
|
||||||
|
|
||||||
CONSTANT: signal-names
|
CONSTANT: signal-names
|
||||||
|
@ -21,6 +22,9 @@ M: signal signal-name n>> signal-name ;
|
||||||
|
|
||||||
M: integer signal-name ( n -- str/f ) 1 - signal-names ?nth ;
|
M: integer signal-name ( n -- str/f ) 1 - signal-names ?nth ;
|
||||||
|
|
||||||
|
: signal-name. ( n -- )
|
||||||
|
signal-name [ " (" ")" surround write ] when* ;
|
||||||
|
|
||||||
SYMBOL: dispatch-signal-hook
|
SYMBOL: dispatch-signal-hook
|
||||||
|
|
||||||
dispatch-signal-hook [ [ drop ] ] initialize
|
dispatch-signal-hook [ [ drop ] ] initialize
|
||||||
|
|
Loading…
Reference in New Issue