Bug 12731 - avr-cgg can't find header files during compilation
Summary: avr-cgg can't find header files during compilation
Status: CLOSED NOTABUG
Alias: None
Product: Sisyphus
Classification: Development
Component: avr-gcc (show other bugs)
Version: unstable
Hardware: all Linux
: P2 minor
Assignee: Grigory Milev
QA Contact: qa-sisyphus
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-09-09 21:36 MSD by Denis Sergeevich
Modified: 2009-07-21 15:06 MSD (History)
3 users (show)

See Also:


Attachments
Пример Makefile (3.37 KB, application/octet-stream)
2009-07-21 13:21 MSD, Grigory Milev
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Denis Sergeevich 2007-09-09 21:36:50 MSD
gcc give error when I run "make" in my project's folde:
"avr/io.h: No such file or directory" and etc.
Headers file install in /usr/include/avr but gcc look at the
/usr/lib/avr/lib/gcc/avr/3.4.4/include.
Steps to Reproduce:
Every time during compilation the programms for AVR microcontrollers
Comment 1 Mikhail Gusarov 2008-06-13 12:59:26 MSD

    
Comment 2 Dmitry V. Levin 2008-11-22 05:23:00 MSK
Nobody is ever going to work on this issue.
Comment 3 Vyatcheslav Perevalov 2009-07-21 12:16:07 MSD
В сизифе ошибка устойчиво воспроизводится.
Comment 4 Grigory Milev 2009-07-21 12:28:25 MSD
А установить библиотеку avr-libc пробовали?
rpm -qf /usr/include/avr/avr/io.h
avr-libc-1.6.6-alt1

Сам использую постоянно и все отлично работает, вот пример сборки моего проекта:
make
avr-gcc -c -g -Os -Wall -Wstrict-prototypes -Wa,-ahlms=tv-switch.lst -MD -MP -MF .dep/tv-switch.o.d -I. -I/usr/include/avr -I./include -I. -mmcu=atmega32 -I. -I/usr/include/avr -I./include -D__AVR_ATmega32__ tv-switch.c -o tv-switch.o
avr-gcc -c -g -Os -Wall -Wstrict-prototypes -Wa,-ahlms=lcd.lst -MD -MP -MF .dep/lcd.o.d -I. -I/usr/include/avr -I./include -I. -mmcu=atmega32 -I. -I/usr/include/avr -I./include -D__AVR_ATmega32__ lcd.c -o lcd.o
avr-gcc -c -g -Os -Wall -Wstrict-prototypes -Wa,-ahlms=matrix.lst -MD -MP -MF .dep/matrix.o.d -I. -I/usr/include/avr -I./include -I. -mmcu=atmega32 -I. -I/usr/include/avr -I./include -D__AVR_ATmega32__ matrix.c -o matrix.o
avr-gcc -S -g -Os -Wall -Wstrict-prototypes -Wa,-ahlms=tv-switch.lst -MD -MP -MF .dep/tv-switch.s.d -I. -I/usr/include/avr -I./include -I. -mmcu=atmega32 -I. -I/usr/include/avr -I./include -D__AVR_ATmega32__ tv-switch.c -o tv-switch.s
avr-gcc  tv-switch.o lcd.o matrix.o  -Wl,-Map=tv-switch.map,--cref  -mmcu=atmega32 -o tv-switch.elf
avr-objcopy -O ihex tv-switch.elf tv-switch.hex
avr-size tv-switch.elf
   text    data     bss     dec     hex filename
   2694     152      17    2863     b2f tv-switch.elf
Comment 5 Vyatcheslav Perevalov 2009-07-21 12:46:29 MSD
rpm -qf /usr/include/avr/avr/io.h
avr-libc-1.6.4-alt1
# apt-get install avr-libc
Reading Package Lists... Done
Building Dependency Tree... Done
avr-libc is already the newest version.
0 upgraded, 0 newly installed, 0 removed and 0 not upgraded.

# apt-get install avr-libc --reinstall
Reading Package Lists... Done
Building Dependency Tree... Done
Reinstallation of avr-libc is not possible, it cannot be downloaded.
0 upgraded, 0 newly installed, 0 removed and 0 not upgraded.


http://sisyphus.ru/ru/find.shtml?request=avr-libc


Кто из нас неправ?
Comment 6 Grigory Milev 2009-07-21 13:21:24 MSD
Created attachment 3679 [details]
Пример Makefile

В атаче пример Makefile, которым собирается мое приложение и все гарантированно работает. Ищи, что у тебя не так :)
Comment 7 Vyatcheslav Perevalov 2009-07-21 13:54:37 MSD
INCLUDES = -I. -I/usr/include/avr -I./include
Это понятно. Как это применить, к примеру, в случае http://www.cadmaniac.org/projectMain.php?projectName=kontrollerlab&section=docs_firstSteps и других подобных примеров "для новичков"?
Comment 8 Grigory Milev 2009-07-21 15:06:55 MSD
Тут я не подскажу, читай доки по написанию Makefile или по той оболочке, в которой пишешь и т.д.