-
-
Notifications
You must be signed in to change notification settings - Fork 163
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[test] Add test/configure-effects.sh
Our build detection is inconsistent between C++ and Python. This test will help make it consistent. - Fix flag typo in ./configure - Refactor ./configure
- Loading branch information
Andy C
committed
Jan 5, 2025
1 parent
1aeec95
commit c1eb56c
Showing
8 changed files
with
143 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
#!/usr/bin/env bash | ||
# | ||
# What happens if various build features aren't detected? | ||
# In Python and C++ | ||
# | ||
# Usage: | ||
# test/configure-effects.sh <function name> | ||
|
||
set -o nounset | ||
set -o pipefail | ||
set -o errexit | ||
|
||
# bugs: | ||
# echo | tr | ||
# echo | cat | ||
# history | less | ||
|
||
prepare-cpp() { | ||
./NINJA-config.sh | ||
|
||
# This overwrites the config | ||
./configure --without-readline --without-libc-features --without-systemtap-sdt | ||
|
||
ninja | ||
} | ||
|
||
prepare-py() { | ||
make | ||
} | ||
|
||
test-osh() { | ||
local osh=$1 | ||
|
||
$osh -x -c 'set -o vi' | ||
$osh -x -c 'set -o emacs' | ||
|
||
# GLOB_PERIOD | ||
$osh -x -c 'shopt -s dotglob' | ||
|
||
# FNM_EXTMATCH | ||
# Hm this will works | ||
$osh -x -c 'echo */@(*.bash|*.asdl)' | ||
|
||
# HAVE_PWENT | ||
$osh -x -c 'compgen -A user' | ||
} | ||
|
||
cpp() { | ||
#prepare | ||
|
||
test-osh _bin/cxx-asan/osh | ||
} | ||
|
||
py() { | ||
#prepare-py | ||
|
||
ln -s -f -v oil.ovm _bin/osh | ||
|
||
test-osh _bin/osh | ||
} | ||
|
||
"$@" |