No rule to make target

Discussions and support about ChibiOS/RT, the free embedded RTOS.
sazem
Posts: 17
Joined: Thu Jun 28, 2018 9:48 am

No rule to make target

Postby sazem » Fri Jun 29, 2018 4:53 am

Hi all;

I have been compiling my main program and the console had posted an error message

Code: Select all

No rule to make target
, which is mean that No such file or directory

Code: Select all

rules.mk
. I had checked the path of my file and it is well done.

I would just to ask you where is the problem and are there someone who is solved this issue ?

The following error message is :

Code: Select all

make -j8 all
Makefile:248: ../../../ChibiOS_2_6_6/os/ports/GCC/ARMCMx/rules.mk: No such file or directory
make: *** No rule to make target '../../../ChibiOS_2_6_6/os/ports/GCC/ARMCMx/rules.mk'.  Stop.


I impatiently await your responses.

Thank you very much

Best Regards;

SAMIR ZEMAM

sazem
Posts: 17
Joined: Thu Jun 28, 2018 9:48 am

Re: No rule to make target

Postby sazem » Fri Jun 29, 2018 7:24 am

Hi all;

In the following of message posted Thu Jun 28, 2018 11:53 pm about a same subject "No rule to make target" with chibios_2.6.6. I have said that may be the problem due to the latest versions of chibios , given that chibios_2.6.6 is older version of chibistudio.

I have tried again with a latest version (chibios_18.2.1) and i have copied make file of demos of my board STM32F303 discovery into make file of my main program.

The problem remains the same, end error stays the same

Code: Select all

02:04:00 **** Incremental Build of configuration Default for project ARMCM4-STM32F303-DISCOVERY ****
make -j8 all
Makefile:266: ../../ChibiOS_18.2.1/os/common/startup/ARMCMx/compilers/GCC/rules.mk: No such file or directory
make: *** No rule to make target '../../ChibiOS_18.2.1/os/common/startup/ARMCMx/compilers/GCC/rules.mk'.  Stop.

02:04:00 Build Finished (took 100ms)


I do not understand why?

Please help me.

P.S:

The full make file program with chibios_18.2.1

Code: Select all

# ChibiOS-RT project compilation, for STM32F3 Discovery Board

##############################################################################
# Build global options
# NOTE: Can be overridden externally.
#

# Compiler options here.
ifeq ($(USE_OPT),)
  USE_OPT = -O2 -ggdb -fomit-frame-pointer -falign-functions=16
endif

# C specific options here (added to USE_OPT).
ifeq ($(USE_COPT),)
  USE_COPT =
endif

# C++ specific options here (added to USE_OPT).
ifeq ($(USE_CPPOPT),)
  USE_CPPOPT = -fno-rtti
endif

# Enable this if you want the linker to remove unused code and data
ifeq ($(USE_LINK_GC),)
  USE_LINK_GC = yes
endif

# Linker extra options here.
ifeq ($(USE_LDOPT),)
  USE_LDOPT =
endif

# Enable this if you want link time optimizations (LTO)
ifeq ($(USE_LTO),)
  USE_LTO = yes
endif

# If enabled, this option allows to compile the application in THUMB mode.
ifeq ($(USE_THUMB),)
  USE_THUMB = yes
endif

# Enable this if you want to see the full log while compiling.
ifeq ($(USE_VERBOSE_COMPILE),)
  USE_VERBOSE_COMPILE = no
endif

# If enabled, this option makes the build process faster by not compiling
# modules not used in the current configuration.
ifeq ($(USE_SMART_BUILD),)
  USE_SMART_BUILD = yes
endif

#
# Build global options
##############################################################################

##############################################################################
# Architecture or project specific options
#

# Stack size to be allocated to the Cortex-M process stack. This stack is
# the stack used by the main() thread.
ifeq ($(USE_PROCESS_STACKSIZE),)
  USE_PROCESS_STACKSIZE = 0x400
endif

# Stack size to the allocated to the Cortex-M main/exceptions stack. This
# stack is used for processing interrupts and exceptions.
ifeq ($(USE_EXCEPTIONS_STACKSIZE),)
  USE_EXCEPTIONS_STACKSIZE = 0x400
endif

# Enables the use of FPU (no, softfp, hard).
ifeq ($(USE_FPU),)
  USE_FPU = no
endif

#
# Architecture or project specific options
##############################################################################

##############################################################################
# Project, sources and paths
#

# Define project name here
PROJECT = rtos_demo
# Imported source files and paths
#CHIBIOS = ../..
#CHIBIOS = /Users/jleny/Software/Embedded/ChibiOS_git
CHIBIOS = ../../ChibiOS_18.2.1
#include $(CHIBIOS)/boards/ST_STM32F3_DISCOVERY/board.mk
#include $(CHIBIOS)/os/hal/platforms/STM32F30x/platform.mk
#include $(CHIBIOS)/os/hal/hal.mk
#include $(CHIBIOS)/os/ports/GCC/ARMCMx/STM32F3xx/port.mk
#include $(CHIBIOS)/os/kernel/kernel.mk
#include $(CHIBIOS)/test/test.mk
# Licensing files.
include $(CHIBIOS)/os/license/license.mk
# Startup files.
include $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC/mk/startup_stm32f3xx.mk
# HAL-OSAL files (optional).
include $(CHIBIOS)/os/hal/hal.mk
include $(CHIBIOS)/os/hal/ports/STM32/STM32F3xx/platform.mk
include $(CHIBIOS)/os/hal/boards/ST_STM32F3_DISCOVERY/board.mk
include $(CHIBIOS)/os/hal/osal/rt/osal.mk
# RTOS files (optional).
include $(CHIBIOS)/os/rt/rt.mk
include $(CHIBIOS)/os/common/ports/ARMCMx/compilers/GCC/mk/port_v7m.mk
# Other files (optional).
include $(CHIBIOS)/test/lib/test.mk
include $(CHIBIOS)/test/rt/rt_test.mk
include $(CHIBIOS)/test/oslib/oslib_test.mk

# Define linker script file here
LDSCRIPT= $(STARTUPLD)/STM32F303xC.ld

# C sources that can be compiled in ARM or THUMB mode depending on the global
# setting.
#CSRC = $(PORTSRC) \
       $(KERNSRC) \
       $(TESTSRC) \
       $(HALSRC) \
       $(PLATFORMSRC) \
       $(BOARDSRC) \
       $(CHIBIOS)/os/various/chprintf.c \
       usbcfg.c main.c
# C sources that can be compiled in ARM or THUMB mode depending on the global
# setting.
CSRC = $(ALLCSRC) \
       $(TESTSRC) \
       main.c

# C++ sources that can be compiled in ARM or THUMB mode depending on the global
# setting.
CPPSRC = $(ALLCPPSRC)

# C sources to be compiled in ARM mode regardless of the global setting.
# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
#       option that results in lower performance and larger code size.
ACSRC =

# C++ sources to be compiled in ARM mode regardless of the global setting.
# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
#       option that results in lower performance and larger code size.
ACPPSRC =

# C sources to be compiled in THUMB mode regardless of the global setting.
# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
#       option that results in lower performance and larger code size.
TCSRC =

# C sources to be compiled in THUMB mode regardless of the global setting.
# NOTE: Mixing ARM and THUMB mode enables the -mthumb-interwork compiler
#       option that results in lower performance and larger code size.
TCPPSRC =

# List ASM source files here
ASMSRC = $(ALLASMSRC)
ASMXSRC = $(ALLXASMSRC)

INCDIR = $(ALLINC) $(TESTINC)
#
# Project, sources and paths
##############################################################################

##############################################################################
# Compiler settings
#

MCU  = cortex-m4

#TRGT = arm-elf-
TRGT = arm-none-eabi-
CC   = $(TRGT)gcc
CPPC = $(TRGT)g++
# Enable loading with g++ only if you need C++ runtime support.
# NOTE: You can use C++ even without C++ support if you are careful. C++
#       runtime support makes code size explode.
LD   = $(TRGT)gcc
#LD   = $(TRGT)g++
CP   = $(TRGT)objcopy
AS   = $(TRGT)gcc -x assembler-with-cpp
AR   = $(TRGT)ar
OD   = $(TRGT)objdump
SZ   = $(TRGT)size
HEX  = $(CP) -O ihex
BIN  = $(CP) -O binary

# ARM-specific options here
AOPT =

# THUMB-specific options here
TOPT = -mthumb -DTHUMB

# Define C warning options here
CWARN = -Wall -Wextra -Wundef -Wstrict-prototypes

# Define C++ warning options here
CPPWARN = -Wall -Wextra -Wundef
#
# Compiler settings
##############################################################################

##############################################################################

# Start of user section
#

# List all user C define here, like -D_DEBUG=1
UDEFS =

# Define ASM defines here
UADEFS =

# List all user directories here
UINCDIR =

# List the user directory to look for the libraries here
ULIBDIR =

# List all user libraries here
ULIBS =

#
# End of user defines
##############################################################################

#ifeq ($(USE_FPU),yes)
  #USE_OPT += -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -fsingle-precision-constant
  #DDEFS += -DCORTEX_USE_FPU=TRUE
#else
  #DDEFS += -DCORTEX_USE_FPU=FALSE
#endif

#ifeq ($(USE_FWLIB),yes)
  #include $(CHIBIOS)/ext/stm32lib/stm32lib.mk
 # CSRC += $(STM32SRC)
  #INCDIR += $(STM32INC)
  #USE_OPT += -DUSE_STDPERIPH_DRIVER
#endif

##############################################################################
# Jerome: recipes for programming the board immediately after compiling
# with 'make program'
# location of OpenOCD Board .cfg files (only used with 'make program')
#OPENOCD_BOARD_DIR=/usr/local/Cellar/open-ocd/0.9.0/share/openocd/scripts/board
#OPENOCD_BOARD_DIR=$(CHIBIOS)/tools/openocd/scripts/board
# Configuration (cfg) file containing programming directives for OpenOCD
#OPENOCD_PROC_FILE=extra/stm32f3-openocd.cfg

#.PHONY: all program

#all: $(MAKE)

#program: all
   #openocd -f $(OPENOCD_BOARD_DIR)/stm32f3discovery.cfg -c "program `pwd`/build/$(PROJECT).elf verify reset exit"
   #openocd -f $(OPENOCD_BOARD_DIR)/stm32f3discovery.cfg -f $(OPENOCD_PROC_FILE) -c "stm_flash `pwd`/build/$(PROJECT).bin" -c shutdown

# End of user defines
##############################################################################
#include $(CHIBIOS)/os/ports/GCC/ARMCMx/rules.mk
RULESPATH = $(CHIBIOS)/os/common/startup/ARMCMx/compilers/GCC
include $(RULESPATH)/rules.mk



My main program is (I want to read the data from sensors of STM32F discovery):

Code: Select all

ChibiOS/RT - Copyright (C) 2006-2014 Giovanni Di Sirio.

  This file is part of ChibiOS/RT.

  ChibiOS/RT is free software; you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation; either version 3 of the License, or
  (at your option) any later version.

  ChibiOS/RT is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  GNU General Public License for more details.

  You should have received a copy of the GNU General Public License
  along with this program.  If not, see <http://www.gnu.org/licenses/>.
*/

#include "ch.h"
#include "hal.h"
#include "test.h"
#include "spi.h"
#include "i2c.h"
#include "usbcfg.h"
#include "chprintf.h"

#define usb_lld_connect_bus(usbp)
#define usb_lld_disconnect_bus(usbp)

/***********************/
/* LED Indicator tasks */
/***********************/

/* Red LED blinker thread, times are in milliseconds */
 
static WORKING_AREA(waThread1, 128);
static msg_t Thread1(void *arg) {

  (void)arg;
  msg_t dummy;
  chRegSetThreadName("blinker1");
  while (TRUE) {
    palSetPad(GPIOE, GPIOE_LED3_RED);
    chThdSleepMilliseconds(2000);
    palClearPad(GPIOE, GPIOE_LED3_RED);
    chThdSleepMilliseconds(2000);
  }
  return dummy;
}

/* Red LED blinker thread, times are in milliseconds */

static WORKING_AREA(waThread2, 128);
static msg_t Thread2(void *arg) {

  (void)arg;
  msg_t dummy;
  chRegSetThreadName("blinker2");
  while (TRUE) {
    palClearPad(GPIOE, GPIOE_LED7_GREEN);
    chThdSleepMilliseconds(50);
    palSetPad(GPIOE, GPIOE_LED7_GREEN);
    chThdSleepMilliseconds(50);
  }
  return dummy;
}

/***************************/
/* Communication protocols */
/***************************/

/* Virtual serial port over USB.*/
SerialUSBDriver SDU1;

static float mdps_per_digit = 8.75;

/* SPI: connection for L3GD20 (Gyro) */
static const SPIConfig spi1cfg = {
  NULL,
  /* HW dependent part.*/
  GPIOE,
  GPIOE_SPI1_CS,
  SPI_CR1_BR_0 | SPI_CR1_BR_1 | SPI_CR1_CPOL | SPI_CR1_CPHA,
  0
};

static uint8_t readByteSPI(uint8_t reg)
{
  char txbuf[2] = {0x80 | reg, 0xFF};
  char rxbuf[2];
  spiSelect(&SPID1);
  spiExchange(&SPID1, 2, txbuf, rxbuf);
  spiUnselect(&SPID1);
  return rxbuf[1];
}
static uint8_t writeByteSPI(uint8_t reg, uint8_t val)
{
  char txbuf[2] = {reg, val};
  char rxbuf[2];
  spiSelect(&SPID1);
  spiExchange(&SPID1, 2, txbuf, rxbuf);
  spiUnselect(&SPID1);
  return rxbuf[1];
}

/* I2C: connection for LSM303DLHC (Acc. + Mag.) */
static const I2CConfig i2cconfig = {
  0x00902025, //voodoo magic
  0,
  0
};

static uint8_t readByteI2C(uint8_t addr, uint8_t reg)
{
  uint8_t data;
  i2cAcquireBus(&I2CD1);
  (void)i2cMasterTransmitTimeout(&I2CD1, addr, &reg, 1, &data, 1, TIME_INFINITE);
  i2cReleaseBus(&I2CD1);
  return data;
}
static void writeByteI2C(uint8_t addr, uint8_t reg, uint8_t val)
{
  uint8_t cmd[] = {reg, val};
  i2cAcquireBus(&I2CD1);
  (void)i2cMasterTransmitTimeout(&I2CD1, addr, cmd, 2, NULL, 0, TIME_INFINITE);
  i2cReleaseBus(&I2CD1);
}

/***************************************/
/* Initializations of the MEMS sensors */
/***************************************/

static void initGyro(void)
{
  /* see the L3GD20 Datasheet */
  writeByteSPI(0x20, 0xcF);
}

static void initAccel(void)
{
  // Highest speed, enable all axes
  writeByteI2C(0x19, 0x20, 0x97);
}

static void initMag(void)
{
  // Highest speed
  writeByteI2C(0x1E, 0x00, 0x1C);
  writeByteI2C(0x1E, 0x02, 0x00);
}

static uint8_t readGyro(float* data)
{
  /* read from L3GD20 registers and assemble data */
  /* 0xc0 sets read and address increment */
  char txbuf[8] = {0xc0 | 0x27, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF};
  char rxbuf[8];
  spiSelect(&SPID1);
  spiExchange(&SPID1, 8, txbuf, rxbuf);
  spiUnselect(&SPID1);
  if (rxbuf[1] & 0x7) {
    int16_t val_x = (rxbuf[3] << 8) | rxbuf[2];
    int16_t val_y = (rxbuf[5] << 8) | rxbuf[4];
    int16_t val_z = (rxbuf[7] << 8) | rxbuf[6];
    data[0] = (((float)val_x) * mdps_per_digit)/1000.0;
    data[1] = (((float)val_y) * mdps_per_digit)/1000.0;
    data[2] = (((float)val_z) * mdps_per_digit)/1000.0;
    return 1;
  }
  return 0;
}

static uint8_t readAccel(float* data)
{
  // setting MSB makes it increment the address for a multiple byte read
  uint8_t start_reg = 0x27 | 0x80;
  uint8_t out[7];
  i2cAcquireBus(&I2CD1);
  msg_t f = i2cMasterTransmitTimeout(&I2CD1, 0x19, &start_reg, 1, out, 7, TIME_INFINITE);
  (void)f;
  i2cReleaseBus(&I2CD1);
  if (out[0] & 0x8) {
    int16_t val_x = (out[2] << 8) | out[1];
    int16_t val_y = (out[4] << 8) | out[3];
    int16_t val_z = (out[6] << 8) | out[5];
    // Accel scale is +- 2.0g
    data[0] = ((float)val_x)*(4.0/(65535.0))*9.81;
    data[1] = ((float)val_y)*(4.0/(65535.0))*9.81;
    data[2] = ((float)val_z)*(4.0/(65535.0))*9.81;
    return 1;
  }
  return 0;
}

static uint8_t readMag(float* data)
{
  uint8_t start_reg = 0x03;
  uint8_t out[7];
  i2cAcquireBus(&I2CD1);
  msg_t f = i2cMasterTransmitTimeout(&I2CD1, 0x1E, &start_reg, 1, out, 7, TIME_INFINITE);
  (void)f;
  i2cReleaseBus(&I2CD1);
  //out[6] doesn't seem to reflect actual new data, so just push out every time
  int16_t val_x = (out[0] << 8) | out[1];
  int16_t val_z = (out[2] << 8) | out[3];
  int16_t val_y = (out[4] << 8) | out[5];
  data[0] = ((float)val_x)*1.22;
  data[1] = ((float)val_y)*1.22;
  data[2] = ((float)val_z)*1.22;
  return 1;
}

/***************/
/* Main Thread */
/***************/
int main(void) {

  halInit();
  chSysInit();

  /* Initializes a serial-over-USB CDC driver */
  sduObjectInit(&SDU1);
  sduStart(&SDU1, &serusbcfg);

  /* Activates the USB driver and then the USB bus pull-up on D+ */
  /* Note, a delay is inserted in order to not have to disconnect the cable */
  /* after a reset */
  usbDisconnectBus(serusbcfg.usbp);
  chThdSleepMilliseconds(1000);
  usbStart(serusbcfg.usbp, &usbcfg);
  usbConnectBus(serusbcfg.usbp);

  spiStart(&SPID1, &spi1cfg);
  i2cStart(&I2CD1, &i2cconfig);
  initGyro();
  initAccel();
  initMag();

  /* Creating the blinker threads */
   
  chThdCreateStatic(waThread1, sizeof(waThread1),
                    NORMALPRIO + 10, Thread1, NULL);
    /*chThdCreateStatic(waThread2, sizeof(waThread2),
                  NORMALPRIO + 10, Thread2, NULL);   
  */
 
  while (TRUE) {
    float gyroData[3];
    float accelData[3];
    float magData[3];
    if (readGyro(gyroData) && readAccel(accelData) && readMag(magData)) {
      chprintf((BaseSequentialStream *)&SDU1, "%f %f %f ", gyroData[0], gyroData[1], gyroData[2]);
      chprintf((BaseSequentialStream *)&SDU1, "%f %f %f ", accelData[0], accelData[1], accelData[2]);
      chprintf((BaseSequentialStream *)&SDU1, "%f %f %f\r\n", magData[0], magData[1], magData[2]);
    }
    chThdSleepMilliseconds(50);
  }
}

User avatar
tfAteba
Posts: 526
Joined: Fri Oct 16, 2015 11:03 pm
Location: Chartres, France
Has thanked: 80 times
Been thanked: 46 times

Re: No rule to make target

Postby tfAteba » Fri Jun 29, 2018 8:07 am

Hello Sazem,

To resolve this error, the easy way is to:

- Compil ethe demo under demos/STM32/RT-STM32F303-DISCOVERY/ and see that every things is fine.
- Make a copy of this demo to modify it whit your main program. Use the whole demo, not just the makefile. Your can then implement your program in the main.c file.
- You can the compile your application.

That is the easy way to do that.
regards,

Theo.

sazem
Posts: 17
Joined: Thu Jun 28, 2018 9:48 am

Re: No rule to make target

Postby sazem » Fri Jun 29, 2018 8:34 am

Hi ;

What do you mean by "you can implement your program in the main.c file". Can you show me the steps in depth.

Thank you very much.

SAMIR ZEMAM
tfAteba wrote:Hello Sazem,

To resolve this error, the easy way is to:

- Compil ethe demo under demos/STM32/RT-STM32F303-DISCOVERY/ and see that every things is fine.
- Make a copy of this demo to modify it whit your main program. Use the whole demo, not just the makefile. Your can then implement your program in the main.c file.
- You can the compile your application.

That is the easy way to do that.

User avatar
tfAteba
Posts: 526
Joined: Fri Oct 16, 2015 11:03 pm
Location: Chartres, France
Has thanked: 80 times
Been thanked: 46 times

Re: No rule to make target

Postby tfAteba » Fri Jun 29, 2018 8:41 am

When you have made a copy of the demo that originaly compile, you can replace the main.c by your main.c and then recompile :)
regards,

Theo.

sazem
Posts: 17
Joined: Thu Jun 28, 2018 9:48 am

Re: No rule to make target

Postby sazem » Fri Jun 29, 2018 8:58 am

Hi Theo;
I have followed your steps, the demo is worked fine. and I have copy my main in originaly main, and I have recompiled it.

The console posted me that there is an error.

Code: Select all

make: Nothing to be done for 'all'


You know what does mean this error.

Thanks;
SAMIR ZEMAM
tfAteba wrote:When you have made a copy of the demo that originaly compile, you can replace the main.c by your main.c and then recompile :)

User avatar
tfAteba
Posts: 526
Joined: Fri Oct 16, 2015 11:03 pm
Location: Chartres, France
Has thanked: 80 times
Been thanked: 46 times

Re: No rule to make target

Postby tfAteba » Fri Jun 29, 2018 9:06 am

You can try to add your application code step by step and see what cause the problem.

To solve your problem quickly I will try to look at this, I will give a try.

Which version do you finiy use? 18.2.1??

Your application code is the main that you shared before?? So that I can try that, I have some idea but I want to try that out before sharing that with you.

Thanks.
regards,

Theo.

sazem
Posts: 17
Joined: Thu Jun 28, 2018 9:48 am

Re: No rule to make target

Postby sazem » Fri Jun 29, 2018 9:21 am

Hi;

I use the 18.2.1. my make file and the main are posted in the previous message.

My main is used before for the older version (chibios 2.6.6), but my main do not contain the paths and configurations. It serves for readind sensor data.

In addition, it had worked in chibiOS 2.6.6, before.

I am nervous, because I need fot that the code will be running well for my application before sunday. As soon as possible.

Thnak you for helping me.

tfAteba wrote:You can try to add your application code step by step and see what cause the problem.

To solve your problem quickly I will try to look at this, I will give a try.

Which version do you finiy use? 18.2.1??

Your application code is the main that you shared before?? So that I can try that, I have some idea but I want to try that out before sharing that with you.

Thanks.

User avatar
tfAteba
Posts: 526
Joined: Fri Oct 16, 2015 11:03 pm
Location: Chartres, France
Has thanked: 80 times
Been thanked: 46 times

Re: No rule to make target

Postby tfAteba » Fri Jun 29, 2018 9:26 am

Hello,

Just made the test:

- Dowload ChibiOS_18_2_1
- Unzip ChibiOS
- Go to demo/STM32/
- Build STM32F303-DISCOVERY to see that all is rigth
- Copy STM32F303-DISCOVERY to test
- Go to test and clean test
- Replace the main.c by your main.c
- Build the test

Then here is the error that I have:

Code: Select all

Compiler Options
arm-none-eabi-gcc -c -mcpu=cortex-m4 -O2 -ggdb -fomit-frame-pointer -falign-functions=16 -ffunction-sections -fdata-sections -fno-common -flto -Wall -Wextra -Wundef -Wstrict-prototypes -Wa,-alms=build/lst/ -DCORTEX_USE_FPU=FALSE -DTHUMB_PRESENT -mno-thumb-interwork -DTHUMB_NO_INTERWORKING -MD -MP -MF .dep/build.d -I. -I../../../os/license -I../../../os/common/portability/GCC -I../../../os/common/startup/ARMCMx/compilers/GCC -I../../../os/common/startup/ARMCMx/devices/STM32F3xx -I../../../os/common/ext/ARM/CMSIS/Core/Include -I../../../os/common/ext/ST/STM32F3xx -I../../../os/hal/include -I../../../os/hal/ports/common/ARMCMx -I../../../os/hal/ports/STM32/STM32F3xx -I../../../os/hal/ports/STM32/LLD/ADCv3 -I../../../os/hal/ports/STM32/LLD/CANv1 -I../../../os/hal/ports/STM32/LLD/DACv1 -I../../../os/hal/ports/STM32/LLD/DMAv1 -I../../../os/hal/ports/STM32/LLD/EXTIv1 -I../../../os/hal/ports/STM32/LLD/GPIOv2 -I../../../os/hal/ports/STM32/LLD/I2Cv2 -I../../../os/hal/ports/STM32/LLD/RTCv2 -I../../../os/hal/ports/STM32/LLD/SPIv2 -I../../../os/hal/ports/STM32/LLD/TIMv1 -I../../../os/hal/ports/STM32/LLD/USARTv2 -I../../../os/hal/ports/STM32/LLD/USBv1 -I../../../os/hal/ports/STM32/LLD/xWDGv1 -I../../../os/hal/boards/ST_STM32F3_DISCOVERY -I../../../os/hal/osal/rt -I../../../os/rt/include -I../../../os/common/oslib/include -I../../../os/common/ports/ARMCMx -I../../../os/common/ports/ARMCMx/compilers/GCC -I../../../test/lib -I../../../test/rt/source/test -I../../../test/oslib/source/test main.c -o main.o

Compiling crt0_v7m.S
Compiling vectors.S
Compiling chcoreasm_v7m.S
Compiling crt1.c
Compiling hal.c
Compiling hal_st.c
Compiling hal_buffers.c
Compiling hal_queues.c
Compiling hal_mmcsd.c
Compiling hal_pal.c
Compiling hal_serial.c
Compiling nvic.c
Compiling stm32_isr.c
Compiling hal_lld.c
Compiling stm32_dma.c
Compiling hal_pal_lld.c
Compiling hal_st_lld.c
Compiling hal_serial_lld.c
Compiling board.c
Compiling osal.c
Compiling chsys.c
Compiling chdebug.c
Compiling chtrace.c
Compiling chvt.c
Compiling chschd.c
Compiling chthreads.c
Compiling chtm.c
Compiling chregistry.c
Compiling chsem.c
Compiling chmtx.c
Compiling chcond.c
Compiling chevents.c
Compiling chmsg.c
Compiling chdynamic.c
Compiling chmboxes.c
Compiling chmemcore.c
Compiling chheap.c
Compiling chmempools.c
Compiling chfactory.c
Compiling chcore.c
Compiling chcore_v7m.c
Compiling ch_test.c
Compiling rt_test_root.c
Compiling rt_test_sequence_001.c
Compiling rt_test_sequence_002.c
Compiling rt_test_sequence_003.c
Compiling rt_test_sequence_004.c
Compiling rt_test_sequence_005.c
Compiling rt_test_sequence_006.c
Compiling rt_test_sequence_007.c
Compiling rt_test_sequence_008.c
Compiling rt_test_sequence_009.c
Compiling rt_test_sequence_010.c
Compiling oslib_test_root.c
Compiling oslib_test_sequence_001.c
Compiling oslib_test_sequence_002.c
Compiling oslib_test_sequence_003.c
Compiling oslib_test_sequence_004.c
Compiling main.c
main.c:22:18: fatal error: test.h: No such file or directory
compilation terminated.
../../../os/common/startup/ARMCMx/compilers/GCC/rules.mk:234 : la recette pour la cible « build/obj/main.o » a échouée
make: *** [build/obj/main.o] Erreur 1



It is not the same that you have.

So please try to follow carefuly the step to reach that point then you have to resolve some conflicts.

I notice that your main.c may be too old, I' m not sure that your need to include:

Code: Select all

#include "spi.h"
#include "i2c.h"
#include "usbcfg.h"


They are already available you just need to enable them in halconf.h file.

I hope that help :)
regards,

Theo.

User avatar
tfAteba
Posts: 526
Joined: Fri Oct 16, 2015 11:03 pm
Location: Chartres, France
Has thanked: 80 times
Been thanked: 46 times

Re: No rule to make target

Postby tfAteba » Fri Jun 29, 2018 9:38 am

Ok, understand,

Calm down we will manage the compilation errors.

First of all a lot of changes have been made since 2.6.6 so your main.c is no longer up to date.
You don't need to keep the makefile of 2.6.6 you must keep the make file of the 18.2.1 this one is up to date.
You whole main application need to be refresh so, you just need to keep functions that read from sensors.

If you whant more real time communication you can connect to the irc channel, I'm currently online so I can help your more faster.

https://webchat.freenode.net/
nickname: Chose your nick name
channels: #chibios

thanks.
regards,

Theo.


Return to “ChibiOS/RT”

Who is online

Users browsing this forum: No registered users and 3 guests