Code Monkey home page Code Monkey logo

Comments (16)

babelouest avatar babelouest commented on May 18, 2024 1

It's even better than that, thanks to CMake's magic!

All you need is to pass the argument -DWITH_JOURNALD=off to cmake when you build Ulfius and this options will be passed to sub libraries, so Yder will be built without systemd support.

$ cd <ulfius source>
$ mkdir build
$ cd build
$ cmake -DWITH_JOURNALD=off ..
$ make && sudo make install

from ulfius.

babelouest avatar babelouest commented on May 18, 2024 1

Sorry, I misread you last message and mixed /usr/include and /usr/local/include.

I could add a constant path in the include search but I'd rather keep this script as much system agnostic as possible.
Can you check, then maybe change your environment variable C_INCLUDE_PATH and see if it works?

See:
http://www.network-theory.co.uk/docs/gccintro/gccintro_23.html
https://docs.freebsd.org/info/gcc/gcc.info.Environment_Variables.html

from ulfius.

Surgams avatar Surgams commented on May 18, 2024 1

Thanks

from ulfius.

babelouest avatar babelouest commented on May 18, 2024

Hello @bluecub ,

Thanks for the support!
The quick workaround is to build yder without systemd logging, then install ulfius:

$ git clone https://github.com/babelouest/yder.git
$ cd yder/
$ mkdir build
$ cd build
$ cmake .. -DWITH_JOURNALD=off
$ make && sudo make install
$ cd ../../ulfius # or cd /path/to/ulfius/source
$ mkdir build && cd build
$ cmake .. && make && sudo make install

This should fix your problem.
I'll also add the option -DWITH_JOURNALD to Ulfius CMake script as well so systems without systemd installed will be able to install Ulfius more easily.

About FreeBSD port of Ulfius, I would like to have one, although I don't know nor use any *BSD on a daily basis.
So I'm very cool with the idea, but I can't make it myself at the moment. If you volunteer to make a BSD port, that would be awesome!

from ulfius.

Surgams avatar Surgams commented on May 18, 2024

Thanks I will try it and let you know how it goes. Cheers

from ulfius.

Surgams avatar Surgams commented on May 18, 2024

Thanks so much, I really appreciate your support ... had another tiny issue which I will look into it as Iā€™m not familiar with cmake. FreeBSD keeps user installed lib in /usr/local/lib and /usr/local/include and to link it is needed to add the path in cmake.
Cheers

from ulfius.

babelouest avatar babelouest commented on May 18, 2024

Maybe try with DESTDIR: https://cmake.org/cmake/help/v3.0/variable/CMAKE_INSTALL_PREFIX.html

$ make DESTDIR=/home/john install

from ulfius.

Surgams avatar Surgams commented on May 18, 2024

The error I am getting is as below because it seems CMake does not find headers installed in /usr/local/include by default. On FreeBSD by default the local is /usr/local/include.

make
[ 7%] Building C object orcania-build/CMakeFiles/orcania.dir/src/base64.c.o
In file included from /home/code/app/lib/ulfius/build/orcania-src/src/base64.c:10:
/home/code/app/lib/ulfius/build/orcania-src/src/../include/orcania.h:14:10: fatal error: 'jansson.h' file not found
#include <jansson.h>
^~~~~~~~~~~

The solution I guess must be something like this... yet I am not sure where I should add this

if(CMAKE_SYSTEM_NAME STREQUAL FreeBSD)
  set(CMAKE_REQUIRED_INCLUDES "/usr/local/include" "/usr/include")
endif()

from ulfius.

babelouest avatar babelouest commented on May 18, 2024

That's weird, because /usr/include is the default include path for Linux as well. So it should look in this path as well obviously.
How did you install jansson library? Using the source, a freeBSD port, something else?

from ulfius.

Surgams avatar Surgams commented on May 18, 2024

Yes using FreeBSD ports. All user installed libs go to /usr/local/lib and headers to /usr/local/include. In normal make I add those in the CFLags.

from ulfius.

Surgams avatar Surgams commented on May 18, 2024

$pkgconf --cflags jansson
-I/usr/local/include

from ulfius.

Surgams avatar Surgams commented on May 18, 2024

I want to add that path to which file in the package I should add it?
Thanks

from ulfius.

babelouest avatar babelouest commented on May 18, 2024

Can you try with the environment variable first?

from ulfius.

Surgams avatar Surgams commented on May 18, 2024

Environment variable solved that issue. Thanks :)

from ulfius.

babelouest avatar babelouest commented on May 18, 2024

Awesome!
I'll add this in the install document :)

from ulfius.

babelouest avatar babelouest commented on May 18, 2024

@bluecub , if Ulfius builds completely on your FreeBSD, I'd close this issue then.

If you have other problems or concerns, don't hesitate to open a new issue on the repo.

from ulfius.

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.