Giter Club home page Giter Club logo

Comments (8)

littleboot avatar littleboot commented on September 24, 2024 2

@ophirHav I will try this out tomorrow (actually I already gave up so many thanks for your reply). Can you elaborate a bit?

so changing line 9 of the makefile from:
$(CC) $(CFLAG) $(INC) $(LIB) -o $(BASE) $(BASE).c

To:
$(CC) $(BASE).c $(CFLAG) $(INC) $(LIB) -o $(BASE)

It seems you only changed the order of the parameters passed to gcc, does this mean original make file was always incorrect or did gcc change or something.
How did you arrive at this fix if I may ask?

Update: It works now, I can compile the program without errors, thank you very much!

from lampify.

t-chab avatar t-chab commented on September 24, 2024 2

I had to replace line 3 of the Makefile to use pkg-config to build on Ubuntu 22.04 :

INC   = -I /usr/include/glib-2.0 -I /usr/lib/glib-2.0/include -I /usr/include/gdk-pixbuf-2.0

with

INC   = $(shell pkg-config --cflags glib-2.0) $(shell pkg-config --cflags gdk-pixbuf-2.0)

from lampify.

ophirHav avatar ophirHav commented on September 24, 2024 1

to fix build fail #2
change the Makefile for the compilation to be -
$(CC) $(BASE).c $(CFLAG) $(INC) $(LIB) -o $(BASE)

from lampify.

Guenda85 avatar Guenda85 commented on September 24, 2024

Same problem with me :-(

from lampify.

Guenda85 avatar Guenda85 commented on September 24, 2024

worked for me as well :-)

from lampify.

yvesdm3000 avatar yvesdm3000 commented on September 24, 2024

Newer versions of GCC have made the order of arguments relevant for linking and optimization purposes. That's why your sources should go first and then reference libraries the code uses.

from lampify.

micahchoo avatar micahchoo commented on September 24, 2024

I had to replace line 3

For Ubuntu 24.04 also, this worked

from lampify.

mak448a avatar mak448a commented on September 24, 2024

Yup, it built. Anyone else having the problem where it outputs [I] Connecting to the lamp [E] Failed to set advertising parameters!? I also tried running as root, but that didn't work. Also it doesn't make the light blink, and lights are unresponsive.

from lampify.

Related Issues (3)

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.