Closed BSoDium closed 1 year ago
Update: I now have a compilation error when running make:
/home/bsodium/Apps/miraclecast/build/src/shared/../../../src/shared/shl_log.c:160: undefined reference to `lrint'
collect2: error: ld returned 1 exit status
make[3]: *** [Makefile:442: miracle-wifid] Error 1
make[3]: Leaving directory '/home/bsodium/Apps/miraclecast/build/src/wifi'
make[2]: *** [Makefile:538: all-recursive] Error 1
make[2]: Leaving directory '/home/bsodium/Apps/miraclecast/build/src'
make[1]: *** [Makefile:422: all-recursive] Error 1
make[1]: Leaving directory '/home/bsodium/Apps/miraclecast/build'
make: *** [Makefile:354: all] Error 2
Any ideas on what dependency I might be missing here?
after first install probably need to reload dbus systemctl daemon-reload or restarts could work.
lrint comes from math.h. Usually that is glibc but depends on your system
This doesn't seem to solve it:
$ sudo systemctl stop NetworkManager.service && sudo systemctl stop wpa_supplicant.service
$ sudo systemctl daemon-reload
$ sudo miracle-wifid
ERROR: dbus: cannot claim org.freedesktop.miracle.wifi bus-name: -13 (manager_dbus_connect() in ../../../src/wifi/wifid-dbus.c:943)
I'm really out of ideas here, restarting doesn't work either.
That error means dbus is not corrctly configured.
What is your OS and which buildsystem did you use?
I am running Debian 11 buster, and used autotools since cmake did not seem to work (missing dependencies mentioned above). I can still try I get cmake to work if you think this is necessary.
13 means permission error. So dbus cannot claim that name
All buildsystem should work, but you need to notice some quirks depending on buildsystem
https://www.gnu.org/prep/standards/html_node/Directory-Variables.html
autotools configure step needs to redefine sysconfdir as it will use $prefix/etc and dbus should go into: /etc
res/Makefile.am dbuspolicydir=$(sysconfdir)/dbus-1/system.d
this is output in autogen.sh step, but maybe you miss it
----------------------------------------------------------------
Initialized build system. For a common configuration please run:
----------------------------------------------------------------
./configure CFLAGS='-g -O0 -ftrapv' --sysconfdir=/etc --localstatedir=/var --libdir=/usr/lib64
still you can see that on configure output:
configure: Build configuration:
prefix: /usr/local
exec-prefix: ${prefix}
bindir: ${exec_prefix}/bin
libdir: ${exec_prefix}/lib
includedir: ${prefix}/include
sysconfdir: ${prefix}/etc
ip-binary: /bin/ip
if you have:
/usr/local/etc/dbus-1/system.d/org.freedesktop.miracle.conf
or
/usr/etc/dbus-1/system.d/org.freedesktop.miracle.conf
that is not gonna work it should be:
/etc/dbus-1/system.d/org.freedesktop.miracle.conf
then
sudo systemctl daemon-reload
should work
Please confirm so we can add this to Wiki FAQ, is a common issue if you look at pass issues, and would be great to put that on wiki
This was already mentioned in Wifi FAQ. https://github.com/albfan/miraclecast/wiki/FAQ#install-dbus-policy
Not sure if document buildsystem quirks is a good or bad idea
Hi @BSoDium
My Raspbian OS:
pi@raspberrypi:/home/pi/miraclecast/build $ uname -a Linux raspberrypi 5.10.103-v7+ #1529 SMP Tue Mar 8 12:21:37 GMT 2022 armv7l GNU/Linux
pi@raspberrypi:/home/pi/miraclecast/build $ lsb_release -a No LSB modules are available. Distributor ID: Raspbian Description: Raspbian GNU/Linux 10 (buster) Release: 10 Codename: buster
And I have same problem when I running make:
make[3]: Entering directory '/home/pi/miraclecast/build/src/wifi' CCLD miracle-wifid /usr/bin/ld: ../shared/.libs/libmiracle-shared.a(shl_log.o): in function
log__submit':
/home/pi/miraclecast/build/src/shared/../../../src/shared/shl_log.c:160: undefined reference to lrint' collect2: error: ld returned 1 exit status make[3]: *** [Makefile:442: miracle-wifid] Error 1 make[3]: Leaving directory '/home/pi/miraclecast/build/src/wifi' make[2]: *** [Makefile:538: all-recursive] Error 1 make[2]: Leaving directory '/home/pi/miraclecast/build/src' make[1]: *** [Makefile:420: all-recursive] Error 1 make[1]: Leaving directory '/home/pi/miraclecast/build' make: *** [Makefile:352: all] Error 2
Did you solve this problem?
Hi @albfan
After search the key word in this repository, I got some info you mention before such as #458
"yes, I think that is usually glibc devel package" Could you explain more??
Because I already install reuirements lib
sudo apt-get install gstreamer1.0-tools libglib2.0-0 libglib2.0-dev libreadline-dev libperl-dev autoconf automake libsystemd-dev libudev-dev libtool
but it still can't make
Thanks
@YuanPeir-Chen I think you can try suggestion on https://github.com/albfan/miraclecast/issues/464
If reporter is able to submit a PR it should be fixed on master after merge.
Hi @albfan
Thanks for quick reply.
Unfortunately, after try suggestion on #464 , it's also not work for using "autotools" and output is same as above
/home/pi/miraclecast/build/src/shared/../../../src/shared/shl_log.c:160: undefined reference to lrint' collect2: error: ld
Alternative build for cmake on latest commit from master, it's work for me, I can successfully make and install, but have another Error when I am testing
ERROR: supplicant: HUP on supplicant socket of wlan0
I will create another issue for ask
thanks.
Hello, I have followed the documentation thoroughly, and run the installation process, stopped the wpa_supplicant service etc. Still when I run
miracle-wifid
I get this error:I am running Debian bullseye, and these are the outputs of
and
Any clues on why this could be happening?