Skip to content

-lpico_servo no such file or directory #2

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

Open
skeyvin opened this issue Sep 13, 2022 · 0 comments
Open

-lpico_servo no such file or directory #2

skeyvin opened this issue Sep 13, 2022 · 0 comments

Comments

@skeyvin
Copy link

skeyvin commented Sep 13, 2022

did as the instructions said
when i run make in my project folder i get /usr/lib/gcc/arm-none-eabi/12.2.0/../../../../arm-none-eabi/bin/ld: cannot find -lpico_servo: No such file or directory
my cmake file for the project

# Generated Cmake Pico project file

cmake_minimum_required(VERSION 3.13)

set(CMAKE_C_STANDARD 11)
set(CMAKE_CXX_STANDARD 17)

# Initialise pico_sdk from installed location
# (note this can come from environment, CMake cache etc)
set(PICO_SDK_PATH "/home/keyvan/Desktop/pico/pico-sdk")

# Pull in Raspberry Pi Pico SDK (must be before project)
include(pico_sdk_import.cmake)
include(./lib/RF24/CMakeLists.txt)
#include(lib/pico_servo/CMakeLists.txt)


project(test C CXX ASM)

# Initialise the Raspberry Pi Pico SDK
pico_sdk_init()

# Add executable. Default name is the project name, version 0.1

add_executable(test test.cpp )

pico_set_program_name(test "test")
pico_set_program_version(test "0.1")

pico_enable_stdio_uart(test 1)
pico_enable_stdio_usb(test 1)

# Add the standard library to the build
link_directories(${CMAKE_SOURCE_DIR}/lib)
target_link_libraries(test pico_stdlib RF24 hardware_pwm pico_servo)
target_include_directories(${CMAKE_PROJECT_NAME} PRIVATE ${CMAKE_CURRENT_LIST_DIR} lib/pico-servo/include)
#target_include_directories( lib/pico-servo/include)
# Add any user requested libraries
target_link_libraries(test
        hardware_spi
        hardware_pio
        hardware_adc
        pico_multicore
        hardware_pwm

        )

pico_add_extra_outputs(test)

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

1 participant