Merge remote-tracking branch 'origin/master' into modern-harvey3

modern-harvey3
Doug Coleman 2019-09-28 09:54:13 -05:00
commit d5d552eb40
9 changed files with 19 additions and 20 deletions

View File

@ -106,7 +106,6 @@ CONSTANT: default-components
"stage2: deployment mode" print
] [
"debugger" require
os unix? [ "debugger.unix" require ] when
"listener" require
] if

View File

@ -391,3 +391,5 @@ M: callsite-not-compiled summary
drop "Caller not compiled with the optimizing compiler" ;
{ "threads" "debugger" } "debugger.threads" require-when
os unix? [ "debugger.unix" require ] when

View File

@ -1,12 +1,9 @@
! Copyright (C) 2009 Slava Pestov.
! See http://factorcode.org/license.txt for BSD license.
USING: accessors debugger io kernel math prettyprint sequences
system unix.signals ;
USING: debugger io kernel prettyprint sequences system
unix.signals ;
IN: debugger.unix
: signal-name. ( n -- )
signal-name [ " (" ")" surround write ] when* ;
M: unix signal-error. ( obj -- )
"Unix signal #" write
third [ pprint ] [ signal-name. ] bi nl ;

View File

@ -1,12 +1,10 @@
USING: accessors calendar concurrency.promises continuations
debugger.unix destructors io io.backend.unix io.directories
io.encodings.ascii io.encodings.binary io.encodings.utf8
io.files io.launcher io.launcher.unix io.streams.duplex
io.timeouts kernel libc locals math namespaces sequences threads
tools.test unix.process ;
USING: accessors calendar concurrency.promises destructors io
io.backend.unix io.directories io.encodings.ascii
io.encodings.binary io.encodings.utf8 io.files io.launcher
io.streams.duplex io.timeouts kernel libc locals math namespaces
sequences threads tools.test unix.process unix.signals ;
IN: io.launcher.unix.tests
[
{ } [ { "touch" "launcher-test-1" } try-process ] unit-test

View File

@ -5,6 +5,7 @@ continuations environment fry io.backend io.backend.unix
io.files.private io.files.unix io.launcher io.launcher.private
io.pathnames io.ports kernel libc math namespaces sequences
simple-tokenizer strings system unix unix.ffi unix.process ;
QUALIFIED-WITH: unix.signals sig
IN: io.launcher.unix
: get-arguments ( process -- seq )
@ -104,10 +105,8 @@ M: unix (kill-process) ( process -- )
: find-process ( handle -- process )
processes get keys [ handle>> = ] with find nip ;
TUPLE: signal n ;
: code>status ( code -- obj )
dup WIFSIGNALED [ WTERMSIG signal boa ] [ WEXITSTATUS ] if ;
dup WIFSIGNALED [ WTERMSIG sig:signal boa ] [ WEXITSTATUS ] if ;
M: unix (wait-for-processes) ( -- ? )
{ int } [ -1 swap WNOHANG waitpid ] with-out-parameters

View File

@ -11,7 +11,7 @@ IN: openssl.libcrypto
<< "libcrypto" {
{ [ 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" ] }
} cond cdecl add-library >>

View File

@ -9,7 +9,7 @@ IN: openssl.libssl
<< "libssl" {
{ [ 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" ] }
} cond cdecl add-library >>

View File

@ -59,7 +59,7 @@ delete-staging-images
! { } [ "bunny" shake-and-bake 2559640 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? [
[ ] [ "webkit-demo" shake-and-bake 600000 small-enough? ] long-unit-test

View File

@ -1,6 +1,7 @@
! Copyright (C) 2011 Joe Groff.
! 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
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 ;
: signal-name. ( n -- )
signal-name [ " (" ")" surround write ] when* ;
SYMBOL: dispatch-signal-hook
dispatch-signal-hook [ [ drop ] ] initialize