Skip to content
This repository has been archived by the owner on Apr 17, 2023. It is now read-only.

Fixed #98 by removing camelCasing of library names #99

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions cmake/Platform/Libraries/LibrariesFinder.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,6 @@ function(find_arduino_library _target_name _library_name)

is_platform_library(${_library_name} is_plib) # Detect whether library is a platform library

if (NOT parsed_args_3RD_PARTY AND NOT is_plib)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm afraid you can't simply delete this block.
It's been a long time since I've written any code in this project, so I don't exactly remember the details, but I do remember that this is important, for other libraries.
You've got to find another way around this.

convert_string_to_pascal_case(${_library_name} _library_name)
endif ()

find_file(library_path
NAMES "${_library_name}"
PATHS ${ARDUINO_CMAKE_PLATFORM_LIBRARIES_PATH} ${ARDUINO_SDK_LIBRARIES_PATH}
Expand Down
1 change: 1 addition & 0 deletions examples/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
set(CMAKE_TOOLCHAIN_FILE ../cmake/Arduino-Toolchain.cmake)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unnecessary, please remove this line

cmake_minimum_required(VERSION 3.8.2)

project(Examples LANGUAGES C CXX ASM)
Expand Down
2 changes: 1 addition & 1 deletion examples/arduino-library/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ arduino_cmake_project(Arduino_Library BOARD_NAME nano BOARD_CPU atmega328)
add_arduino_executable(Arduino_Library test.cpp)

# Find and link the Stepper library
find_arduino_library(stepper_lib stePpEr) # Library name is case-insensitive to the user
find_arduino_library(stepper_lib Stepper)
link_arduino_library(Arduino_Library stepper_lib)

# Find and link the Servo library - Custom implementation for many architectures,
Expand Down
3 changes: 3 additions & 0 deletions examples/platform-library/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,6 @@ link_arduino_library(Platform_Library wire)

find_arduino_library(spi SPI)
link_arduino_library(Platform_Library spi)

find_arduino_library(sd SD)
link_arduino_library(Platform_Library sd)
1 change: 1 addition & 0 deletions examples/platform-library/platformLibrary.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include <Arduino.h>
#include <Wire.h>
#include <SPI.h>
#include <SD.h>

void setup()
{
Expand Down