-
Notifications
You must be signed in to change notification settings - Fork 66
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
Error in make #6
Comments
looks like a path problem. Have you looked at the contents of
/home/peyman/toolchain/STM32F10x_StdPeriph_Lib_V3.5.0/Libraries/STM32F10x_StdPeriph_Driver
?? Did you download the standard peripheral libraries ?
Why don't you switch from the codesourcery tools to the arm launchpad tools
here: https://launchpad.net/gcc-arm-embedded.
…On Sat, Nov 26, 2016 at 11:29 AM, peymankhalili ***@***.***> wrote:
when typed "make" ... ends to this:
/home/peyman/toolchain/Sourcery/bin/arm-none-eabi-gcc -T../stm32f100.ld
-mthumb -mcpu=cortex-m3 -o BlinkingLights.elf startup_stm32f10x.o
system_stm32f10x.o main.o
main.o: In function main': **# /home/peyman/toolchain/STM32-
Template/BlinkingLights/main.c:12: undefined reference to
RCC_APB2PeriphClockCmd'**
collect2: error: ld returned 1 exit status
../Makefile.common:61: recipe for target 'BlinkingLights.elf' failed
I think marked text says that could not include "stm32f10x_gpio.c" &
"stm32f10x_rcc.c" files in "/home/peyman/toolchain/
STM32F10x_StdPeriph_Lib_V3.5.0/Libraries/STM32F10x_StdPeriph_Driver"
directory.
How to fix??
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#6>, or mute the
thread
<https://github.com/notifications/unsubscribe-auth/ABq_UjGj-NtdJ_ORzImP9lhTyT3dwclAks5rCF5UgaJpZM4K87re>
.
|
of course.. I used arm launchpad tools instead of Sourcery. just for compatibility with your code changed folder name to Sourcery. I downloaded standard peripheral libraries from here. |
I just downloaded standard peripheral libraries from link you mentioned in book( from St.com ) but nothing changed. and I copied "stm32f10x_gpio.c" & "stm32f10x_rcc.c" to that folder(near makefile) but still same. I study GNU-make book by Richard M. Stallman to diagnoctic the error but everything looks true in makefile system. |
At the end problem solved... I added and make completed successfully. compilation flags for gdbCFLAGS = -O1 -g object filesOBJS= $(STARTUP) main.o include common make fileinclude $(TEMPLATEROOT)/Makefile.common |
That is curious. I'm glad you solved the problem. When I do the build on
my system, there's no issue. But then it is always hard to know if there
isn't something subtly different about how a machine is set up.
Geoffrey
…On Sun, Nov 27, 2016 at 2:23 AM, peymankhalili ***@***.***> wrote:
At the end problem solved...
from here <https://github.com/StuartHa/DisoveringSTM32Solutions>.
by studing edited makefile in that solutions I just found that this parts
must added to makefile:
OBJS += stm32f10x_gpio.o stm32f10x_rcc.o
I added and make completed successfully.
final makefile is this:
////////////////////////////////////////////////////////////
//////////////////////////
TEMPLATEROOT = ..
compilation flags for gdb
CFLAGS = -O1 -g
ASFLAGS = -g
object files
OBJS= $(STARTUP) main.o
OBJS += stm32f10x_gpio.o stm32f10x_rcc.o
include common make file
include $(TEMPLATEROOT)/Makefile.common
////////////////////////////////////////////////////////////
//////////////////////////
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#6 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABq_UnHSQBMv-P4LHUqq-yocNCjG77SIks5rCS_ngaJpZM4K87re>
.
|
I had the same problem, but due to peymankhalili is solved. Many thanks. |
RCC_APB2PeriphClockCmd |
when typed "make" ... ends to this:
/home/peyman/toolchain/Sourcery/bin/arm-none-eabi-gcc -T../stm32f100.ld -mthumb -mcpu=cortex-m3 -o BlinkingLights.elf startup_stm32f10x.o system_stm32f10x.o main.o
main.o: In function
main': **# /home/peyman/toolchain/STM32-Template/BlinkingLights/main.c:12: undefined reference to
RCC_APB2PeriphClockCmd'**collect2: error: ld returned 1 exit status
../Makefile.common:61: recipe for target 'BlinkingLights.elf' failed
I think marked text says that could not include "stm32f10x_gpio.c" & "stm32f10x_rcc.c" files in "/home/peyman/toolchain/STM32F10x_StdPeriph_Lib_V3.5.0/Libraries/STM32F10x_StdPeriph_Driver" directory.
How to fix??
The text was updated successfully, but these errors were encountered: