Arduino Forum

Products => Create => Editor => Topic started by: fredoc on Oct 10, 2018, 10:52 pm

Title: Custom Library No such file or directory
Post by: fredoc on Oct 10, 2018, 10:52 pm
Hi,

In the create.arduino.cc web editor

I've uploaded an external library zip format, everything ok.

I try to "verify" an exemple and "No such file or directory"

same result with RCSwitch...

It looks like it can't find it

need help.

Tks
Title: Re: Custom Library No such file or directory
Post by: pert on Oct 10, 2018, 11:00 pm
There are quite a few reports of this issue with the Arduino Web Editor. Here are the ones I found after a quick glance:

There is a comment from one of the Arduino developers in the first link:
Thanks for your report @tko1982, we'll try to find out what is happening
So my guess is that's where we'll get the first news of any results of the investigation. You might want to subscribe to that thread.
Title: Re: Custom Library No such file or directory
Post by: pert on Oct 10, 2018, 11:01 pm
Until then, the workaround would be to use the standard Arduino IDE, which you can download here:
http://www.arduino.cc/en/Main/Software (http://www.arduino.cc/en/Main/Software)
Title: Re: Custom Library No such file or directory
Post by: fredoc on Oct 10, 2018, 11:15 pm
Tks Pert,

It seems to work on an old account i used.

But not on the new account i've just created...


Title: Re: Custom Library No such file or directory
Post by: pert on Oct 10, 2018, 11:27 pm
It does seem to be a sporadic problem. I tried to reproduce it using the exact library file that caused the issue for someone else but there was no error for me. Unfortunately that might make it harder for the developers to find the problem.
Title: Re: Custom Library No such file or directory
Post by: smellai on Oct 11, 2018, 09:59 am
Thank you @fredoc,
you provided the right information. It seems it happens to new users only, we'll investigate more
Title: Re: Custom Library No such file or directory
Post by: matteosuppo on Oct 17, 2018, 05:42 pm
It was an error on our end. It should be solved now. Can you confirm?
Title: Re: Custom Library No such file or directory
Post by: feqlzma on Oct 23, 2018, 04:41 am
I still can't get it to work.  It might be that I have installed the libraries wrong, but I can't tell.  I have tried to reinstall the libraries from the file I used when it worked but it doesn't seem to work.  I have been working on this for three weeks and I am having a hard time remembering what I have done to what account.

I have attached the zip file that holds the libraries I am trying to include.  It seems to grab the examples but not the libraries.
Title: Re: Custom Library No such file or directory
Post by: pert on Oct 23, 2018, 05:11 am
Please do this:
Title: Re: Custom Library No such file or directory
Post by: wsroboticsizzy on Oct 23, 2018, 07:45 pm
Code: [Select]
./opt/arduino-builder/arduino-builder -compile -core-api-version 10611 -hardware opt/arduino-builder/hardware -hardware ./opt/cores -tools opt/arduino-builder/tools -tools ./opt/tools -built-in-libraries opt/libraries/latest -logger humantags -fqbn arduino:avr:uno -build-cache /tmp -build-path /tmp/777816859/build -verbose -libraries /tmp/777816859/custom -libraries /tmp/777816859/pinned /tmp/777816859/MotorTest

Using board 'uno' from platform in folder: /home/ubuntu/opt/cores/arduino/avr

Using core 'arduino' from platform in folder: /home/ubuntu/opt/cores/arduino/avr

Detecting libraries used...

/home/ubuntu/opt/tools/avr-gcc/4.9.2-atmel3.5.4-arduino2/bin/avr-g++ -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -flto -w -x c++ -E -CC -mmcu=atmega328p -DF_CPU=16000000L -DARDUINO=10611 -DARDUINO_AVR_UNO -DARDUINO_ARCH_AVR -I/home/ubuntu/opt/cores/arduino/avr/cores/arduino -I/home/ubuntu/opt/cores/arduino/avr/variants/standard /tmp/777816859/build/sketch/MotorTest.ino.cpp -o /dev/null

/tmp/777816859/MotorTest/MotorTest.ino:2:21: fatal error: UCMotor.h: No such file or directory

#include <UCMotor.h>

^

compilation terminated.

exit status 1
Title: Re: Custom Library No such file or directory
Post by: pert on Oct 24, 2018, 08:37 am
@feqlzma and @wsroboticsizzy, the error was caused by the UCMotor library using the incorrect examples folder name "example". With the regular Arduino IDE this doesn't cause any real problem, and so you will find many Arduino libraries that don't follow this part of the Arduino libraries specification. However, this causes the Arduino Web Editor to think the UCMotor.zip file you provided contains sketches, not a library. So it happily imports the library's example sketches, while ignoring the library. The solution is to simply rename the example folder to the correct name: examples. I have attached a UCMotor.zip file with the problem corrected in case you don't feel like making this change yourself.

So I think the error you encountered has nothing to do with the original bug reported in this thread.

This is likely to be a fairly common problem so perhaps the Arduino developers might look at how the import's library detection can be improved. In a recent automated scan (https://github.com/per1234/inolibbuglist) of 8737 unique (not development forks) Arduino libraries on GitHub, my script detected that 345 had an incorrect examples folder name.