Fix shared object relcations with multiple static arrays (#2121)

This commit is contained in:
jackcmay 2018-12-12 08:41:45 -08:00 committed by GitHub
parent fa98434096
commit cefbb7c27d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 18 additions and 2 deletions

View File

@ -0,0 +1,10 @@
#include <solana_sdk.h>
static const char msg[] = "This is a message";
static const char msg2[] = "This is a different message";
extern bool entrypoint(const uint8_t *input) {
sol_log((char*)msg);
sol_log((char*)msg2);
return true;
}

View File

@ -32,7 +32,7 @@ if [[ ! -r criterion-$machine-$version.md ]]; then
fi
# Install LLVM
version=v0.0.6
version=v0.0.7
if [[ ! -f llvm-native-$machine-$version.md ]]; then
(
filename=solana-llvm-$machine.tar.bz2

View File

@ -299,7 +299,13 @@ fn test_program_builtin_bpf_noop() {
fn test_program_bpf_c() {
logger::setup();
let programs = ["noop", "struct_pass", "struct_ret", "noop++"];
let programs = [
"noop",
"noop++",
"struct_pass",
"struct_ret",
"multiple_static",
];
for program in programs.iter() {
println!("Test program: {:?}", program);
let mut file = File::open(create_bpf_path(program)).expect("file open failed");