-
Notifications
You must be signed in to change notification settings - Fork 44
Enable using postgrestd #56
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This reverts commit 79cb819.
52c8e06 to
f24b35e
Compare
|
( sorry, last commit was erroneous. ) |
|
Link error against undefined symbols, but... only on macOS, apparently, as Ubuntu does fine? Okay then. |
This reverts commit 15cbc2f. This feels superstitious, but I am trying it anyways.
|
When I run this on a clean machine I get this (x86_64 Arch Linux): [ana@architect plrust]$ cargo pgx test --features target_postgrestd
"cargo" "test" "--features" "target_postgrestd pg_test"
Compiling ring v0.16.21 (https://github.com/workingjubilee/ring?branch=postgres-os#52f2ad16)
Compiling mio v0.8.3
Compiling socket2 v0.4.4
Compiling rand v0.4.6
Compiling rand_core v0.6.3
Compiling parking_lot v0.12.1
Compiling uuid v1.1.2
error: failed to run custom build command for `ring v0.16.21 (https://github.com/workingjubilee/ring?branch=postgres-os#52f2ad16)`
Caused by:
process didn't exit successfully: `/home/ana/git/tcdi/plrust/target/debug/build/ring-99d869df8d5ff526/build-script-build` (exit status: 101)
--- stdout
OPT_LEVEL = Some("0")
TARGET = Some("x86_64-unknown-linux-gnu")
HOST = Some("x86_64-unknown-linux-gnu")
CC_x86_64-unknown-linux-gnu = None
CC_x86_64_unknown_linux_gnu = None
HOST_CC = None
CC = None
CFLAGS_x86_64-unknown-linux-gnu = None
CFLAGS_x86_64_unknown_linux_gnu = None
HOST_CFLAGS = None
CFLAGS = None
CRATE_CC_NO_DEFAULTS = None
DEBUG = Some("true")
CARGO_CFG_TARGET_FEATURE = Some("fxsr,sse,sse2")
--- stderr
running "cc" "-O0" "-ffunction-sections" "-fdata-sections" "-fPIC" "-g" "-fno-omit-frame-pointer" "-m64" "-I" "include" "-Wall" "-Wextra" "-pedantic" "-pedantic-errors" "-Wall" "-Wextra" "-Wcast-align" "-Wcast-qual" "-Wconversion" "-Wenum-compare" "-Wfloat-equal" "-Wformat=2" "-Winline" "-Winvalid-pch" "-Wmissing-field-initializers" "-Wmissing-include-dirs" "-Wredundant-decls" "-Wshadow" "-Wsign-compare" "-Wsign-conversion" "-Wundef" "-Wuninitialized" "-Wwrite-strings" "-fno-strict-aliasing" "-fvisibility=hidden" "-fstack-protector" "-g3" "-Werror" "-c" "-o/home/ana/git/tcdi/plrust/target/debug/build/ring-621c5209cb56140a/out/sha512-x86_64-elf.o" "/home/ana/git/tcdi/plrust/target/debug/build/ring-621c5209cb56140a/out/sha512-x86_64-elf.S"
/home/ana/git/tcdi/plrust/target/debug/build/ring-621c5209cb56140a/out/sha512-x86_64-elf.S:10: error: unterminated #if
10 | #if defined(__x86_64__) && !defined(OPENSSL_NO_ASM)
|
thread 'main' panicked at 'execution failed', /home/ana/.cargo/git/checkouts/ring-b0b6b149cfdc0877/52f2ad1/build.rs:656:9
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
warning: build failed, waiting for other jobs to finish...Do I need to fulfill some prerequisite? |
| [patch.crates-io] | ||
| libc = { git = "https://github.com/workingjubilee/libc", branch = "postgres-os" } | ||
| getrandom = { git = "https://github.com/workingjubilee/getrandom", branch = "postgres-os" } | ||
| ring = { git = "https://github.com/workingjubilee/ring", branch = "postgres-os" } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Noting for future us that we think we can get rid of ring, getrandom, and libc here, hence they are not on the tcdi org. I am unsure if we plan to include that work in this PR, I don't really mind either way.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, that won't happen immediately here, but Soon.
|
Really excited to give this a spin. Is there any parts of postgrestd or the other libraries you'd like me to review closely as well? I'll give the postgrestd a skim for sure. |
Signed-off-by: Ana Hobden <operator@hoverbear.org>
Signed-off-by: Ana Hobden <operator@hoverbear.org>
.github/workflows/ci.yml
Outdated
|
|
||
| - name: Install cargo-pgx | ||
| continue-on-error: true # We might have it. | ||
| run: cargo install --force cargo-pgx --version $CARGO_PGX_VERSION |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible we need to install the cargo-pgx off the branch?
|
Hmmm so does this mean |
|
Yeah, I thiiink the |
|
Okay, I am throwing in the towel on making Intel Mac work. One is in the mail to me so I will be able to plug it in and poke around and fix this soon, but for right now, eff it. |
|
@workingjubilee I'm fine with not doing this on intel Macs yet. They can just not use that feature. It is a dying platform anyways. |
This lays out some target selection logic using a
PLRUST_TARGETenv var, adds a feature for selecting an appropriate tuple by default, and otherwise provides for actually using postgrestd. This is logically complete but doesn't actually include the full test and build script. I'm going to let CI/review make noises at me before I do anything further that would mangle that signal.