Git Product home page Git Product logo

Comments (4)

Emilgardis avatar Emilgardis commented on June 3, 2024 1

we don't have openssl installed in our images, you'll have to install it yourself or use vendored

You can maybe use system packages using debian (ubuntu doesn't distribute mips anymore).

I'd recommend you to use the vendored feature

from cross.

ramabu avatar ramabu commented on June 3, 2024 1

Pasting the Dockerfile I used for a custom cross image

FROM  ghcr.io/cross-rs/mips-unknown-linux-musl:latest
## Base rust 'cross' image for compiling on mips-unknown-linux-musl (gl-inet)
ENV OPENSSL_V="1.1.1t"
ENV OPENSSL_LIB_DIR=/tmp/openssl-${OPENSSL_V}
ENV OPENSSL_INCLUDE_DIR=/tmp/openssl-${OPENSSL_V}/include

RUN set -o errexit \
    && apt-get update \
    && apt install --yes wget clang g++-multilib \
    && cd /tmp \
    && wget https://www.openssl.org/source/openssl-${OPENSSL_V}.tar.gz \
    && tar xzf openssl-${OPENSSL_V}.tar.gz \
    && export MACHINE=mips \
    && export ARCH=mips-linux-muslsf \
    && export CC=${ARCH}-gcc \
    && cd /tmp/openssl-${OPENSSL_V} \
    && ./config \
    && make

RUN export OPENSSL_V="1.1.1t" \
    && export OPENSSL_LIB_DIR=/tmp/openssl-${OPENSSL_V} \
    && export OPENSSL_DIR=/tmp/openssl-${OPENSSL_V} \
    && export OPENSSL_INCLUDE_DIR=/tmp/openssl-${OPENSSL_V}/include

from cross.

ramabu avatar ramabu commented on June 3, 2024

specifically for mips-unknown-linux-musl, I had to download openssl, compile it, and set OPENSSL_LIB_DIR/OPENSSL_INCLUDE_DIR properly for this to happen, as I could not apt install openssl-devel nor libssl-dev (not found)

I basically followed the instructions in the first answer here, changed as follows:

`
cd /tmp

apt update
apt install wget

wget https://www.openssl.org/source/openssl-1.1.1t.tar.gz
tar xzf openssl-1.1.1t.tar.gz
export MACHINE=mips
export ARCH=mips
export CC=mips-unknown-linux-musl-gcc
cd openssl-1.1.1t && ./config && make

cd $PROJECT_DIR

export OPENSSL_LIB_DIR=/tmp/openssl-1.1.1t/
export OPENSSL_INCLUDE_DIR=/tmp/openssl-1.1.1t/include

cargo build --target mips-unknown-linux-musl --release
`

from cross.

ramabu avatar ramabu commented on June 3, 2024

Got this working and attached a working description

from cross.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.