-
Notifications
You must be signed in to change notification settings - Fork 358
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
C++ support #45
C++ support #45
Conversation
☔ The latest upstream changes (presumably 795a1eb) made this pull request unmergeable. Please resolve the merge conflicts. |
closes #31
@homunkulus r+ |
📋 Looks like this PR is still in progress, ignoring approval |
Changed the test crate to a crate that has no system dependencies. |
@homunkulus r+ |
📋 Looks like this PR is still in progress, ignoring approval |
@homunkulus r+ |
📌 Commit 93124c8 has been approved by |
C++ support @dflemstr I tested (i.e. `cross build`) this against your `vcdiff` crate. It worked for x86_64 but failed for armv7 with this error: ``` running: "arm-linux-gnueabihf-g++" "-O0" "-ffunction-sections" "-fdata-sections" "-g" "-fPIC" "-march=armv7-a" "-I" "open-vcdiff/src" "-I" "src" "-Wno-deprecated-declarations" "-DHAVE_EXT_ROPE=1" "-DHAVE_MALLOC_H=1" "-DHAVE_SYS_MMAN_H=1" "-DHAVE_SYS_STAT_H=1" "-DHAVE_SYS_TIME_H=1" "-DHAVE_UNISTD_H=1" "-o" "/target/armv7-unknown-linux-gnueabihf/debug/build/open-vcdiff-sys-92ed9c97abc8a6c4/out/open-vcdiff/src/encodetable.o" "-c" "open-vcdiff/src/encodetable.cc" cargo:warning=In file included from open-vcdiff/src/google/encodetable.h:23:0, cargo:warning= from open-vcdiff/src/encodetable.cc:20: cargo:warning=open-vcdiff/src/checksum.h:22:18: fatal error: zlib.h: No such file or directory cargo:warning=compilation terminated. ExitStatus(ExitStatus(256)) ``` Installing the `zlibg1-dev` package, which install `/usr/include/zlib.h`, "fixes" the problem but that seems like a bug since you already have zlib.h in your `vcdiff-sys` crate. If you could fix that or point me to another self-contained crate that build C++ code then I could add some tests and add C++ support for other targets.
This looks really great by the way, thanks for the efforts! There's probably some quirks with code that uses global initializers, maybe that isn't triggered by Basically, |
💔 Test failed - status-travis |
also s390x has no `cross run` support so test using `cross build` instead
@homunkulus r+ |
📌 Commit acbc9e9 has been approved by |
C++ support @dflemstr I tested (i.e. `cross build`) this against your `vcdiff` crate. It worked for x86_64 but failed for armv7 with this error: ``` running: "arm-linux-gnueabihf-g++" "-O0" "-ffunction-sections" "-fdata-sections" "-g" "-fPIC" "-march=armv7-a" "-I" "open-vcdiff/src" "-I" "src" "-Wno-deprecated-declarations" "-DHAVE_EXT_ROPE=1" "-DHAVE_MALLOC_H=1" "-DHAVE_SYS_MMAN_H=1" "-DHAVE_SYS_STAT_H=1" "-DHAVE_SYS_TIME_H=1" "-DHAVE_UNISTD_H=1" "-o" "/target/armv7-unknown-linux-gnueabihf/debug/build/open-vcdiff-sys-92ed9c97abc8a6c4/out/open-vcdiff/src/encodetable.o" "-c" "open-vcdiff/src/encodetable.cc" cargo:warning=In file included from open-vcdiff/src/google/encodetable.h:23:0, cargo:warning= from open-vcdiff/src/encodetable.cc:20: cargo:warning=open-vcdiff/src/checksum.h:22:18: fatal error: zlib.h: No such file or directory cargo:warning=compilation terminated. ExitStatus(ExitStatus(256)) ``` Installing the `zlibg1-dev` package, which install `/usr/include/zlib.h`, "fixes" the problem but that seems like a bug since you already have zlib.h in your `vcdiff-sys` crate. If you could fix that or point me to another self-contained crate that build C++ code then I could add some tests and add C++ support for other targets.
@dflemstr Are those comments specifically about x86(_64)-musl? I know that those musl targets pass
That's also x86(_64)-musl specific. It's done that way so one is able to build binaries statically linked to musl without having to install the musl libc (or musl-gcc). |
☀️ Test successful - status-travis |
@dflemstr I tested (i.e.
cross build
) this against yourvcdiff
crate. It worked for x86_64 but failed for armv7 with this error:Installing the
zlibg1-dev
package, which install/usr/include/zlib.h
, "fixes" the problem but that seems like a bug since you already have zlib.h in yourvcdiff-sys
crate. If you could fix that or point me to another self-contained crate that build C++ code then I could add some tests and add C++ support for other targets.