Skip to content

Dark Souls level frustration with compilation project with this library #83

Open
@M1chlCZ

Description

Alright, I am having deep trouble to get this stuff up and running inside me project.

So first I've tried to compile on Mac, natively, with musl, with zig cc. Various errors, but most often that, tried to add -I/ -L flags to point out to downloaded package from google, nothing always more or less this error:

/root/go/pkg/mod/github.com/galeone/tensorflow/tensorflow/[email protected]/attrs.go:20:11: fatal error: tensorflow/c/c_api.h: No such file or directory
    20 | // #include "tensorflow/c/c_api.h"
       |           ^~~~~~~~~~~~~~~~~~~~~~
 compilation terminated.

So alright, there is the added difficulty with ARM64 and x64_86 libs, so...why not try a docker, with the image listed on this github:

FROM tensorflow/tensorflow:2.9.1

RUN apt-get update && apt-get install -y \
    wget \
    git \
    gcc \
    build-essential

ENV GOLANG_VERSION 1.20.3
RUN wget https://golang.org/dl/go${GOLANG_VERSION}.linux-amd64.tar.gz && \
    tar -C /usr/local -xzf go${GOLANG_VERSION}.linux-amd64.tar.gz && \
    rm go${GOLANG_VERSION}.linux-amd64.tar.gz

ENV PATH /usr/local/go/bin:$PATH

WORKDIR /app

COPY . .

RUN  go get -d -v ./... && \
    CGO_ENABLED=1 go build -o main .

LABEL authors="M1chl"

ENTRYPOINT ["./main", "arg1"]

Well no dice, same error. I by no means want to waste any ones time, but I would really need to get this up and running.

Does anyone has any suggestion how to fix it?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions