Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

libmicroros.a', needed by 'int32_publisher.elf', missing and no known rule to make it #183

Open
Usama-Arshad16 opened this issue Apr 3, 2023 · 7 comments

Comments

@Usama-Arshad16
Copy link

int32_publisher example not building

  • Hardware description: I was trying to build it for esp32
  • Installation type: ROS2 foxy with micro_ros_espidf_component
  • Version or commit hash: microros foxy

Steps to reproduce the issue

I have Ros Foxy installed on my PC. In order to use microros with esp32, I first cloned esp_idf and then I cloned micro_ros_espidf_component repo.
These are the commands i followed

  • . $IDF_PATH/export.sh
  • cd examples/int32_publisher
  • idf.py set-target esp32
  • idf.py build

Expected behavior

I was expecting it to build successfully.

Actual behavior

But Actually it was giving me error shown below

image
image

Additional information

@liamhan0905
Copy link

I'm getting the same error

@nilseuropa
Copy link

Me too,but on humble branch.

@liamhan0905
Copy link

liamhan0905 commented Apr 7, 2023

@nilseuropa what branch have you tried that worked? Since humble is supported, I thought it would work. I just tried using the foxy branch but getting the same error

@UsamaArshad16
Copy link

Please someone solve this.
I also tried this using docker, but the error stays the same
image

@glmnet
Copy link

glmnet commented Jun 5, 2023

I was getting this error then I run

cd ~/esp/esp-idf
source ./export.sh
pip3 install catkin_pkg lark-parser empy colcon-common-extensions

then I clean build and it worked, seems like the source before pip3 install didn't work when I did it first time.

@dgarcu
Copy link

dgarcu commented Jun 19, 2023

I have also solved it with the solution provided by @glmnet 😄

@2b-t
Copy link
Contributor

2b-t commented Dec 3, 2023

I had the very same issue. My issue might be very specific but in my case the problem was my .gitconfig in combination with a YubiKey hardware identification device. A while back I had configured an insteadOf rule for Git so that it would use SSH for cloning any Github repository instead of HTTPS.

$ cat /home/$USER/.gitconfig
[user]
	signingKey = <my_gpg_key>
	name = <my_name>
	email = <my_email>
[commit]
	gpgsign = true
[gpg]
	program = gpg
[url "ssh://[email protected]/"]
	insteadOf = https://github.com/

The SSH keys are saved on my Yubikey ($ ssh-add -K) and I need to confirm by tapping my YubiKey.

After executing $ idf.py set-target <target_type>, various repositories should be pulled from Github and libmicroros.a should be compiled. As this would fail silently /micro_ros_espidf_component/micro_ros_src/build would be almost empty and /micro_ros_espidf_component/libmicroros.a would not exist at all. Furthermore also building with the Docker would fail as my .gitconfig on the host system would be copied inside my Docker, resulting in the very same issue.
Simply deleting the entire .gitconfig inside my Docker with $ rm /home/$USER/.gitconfig (or alternatively deleting just this rule) solved the issue and I was able to build and flash micro-ROS onto my ESP32-C3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants