Skip to content

Commit c4107ba

Browse files
Rui Costakraj
authored andcommitted
avro: extend avro-c++ to native and nativesdk
- fix HOMEPAGE for both avro recipes - fix cmake install paths in patch
1 parent ad340c8 commit c4107ba

5 files changed

Lines changed: 35 additions & 32 deletions

File tree

meta-oe/recipes-support/avro/avro-c++/0001-Remove-cpp-unittest-compilation.patch

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
11
From 6be1c45e1f7ee78499bdca76c25ec23a61317134 Mon Sep 17 00:00:00 2001
22
From: Rui Costa <rui.ms.costa@ctw.bmwgroup.com>
33
Date: Wed, 20 Mar 2024 14:58:27 +0000
4-
Subject: [PATCH 1/2] Remove cpp unittest compilation
4+
Subject: [PATCH] Remove cpp unittest compilation
55

66
Upstream-Status: Inappropriate [oe-specific]
7+
78
---
89
lang/c++/CMakeLists.txt | 61 -----------------------------------------
910
1 file changed, 61 deletions(-)
@@ -83,6 +84,3 @@ index 4a3793152..d94ba42d3 100644
8384
include (InstallRequiredSystemLibraries)
8485

8586
set (CPACK_PACKAGE_FILE_NAME "avrocpp-${AVRO_VERSION_MAJOR}")
86-
--
87-
2.44.0
88-

meta-oe/recipes-support/avro/avro-c++/0002-Add-package-configuration-files.patch

Lines changed: 25 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,47 @@
1-
From 56feaa90d070a5011f380d3ae47c01643b9fafe0 Mon Sep 17 00:00:00 2001
1+
From 86aa3f2333a9b8e6f1c631e6d5cb7296b6e8380b Mon Sep 17 00:00:00 2001
22
From: Rui Costa <rui.ms.costa@ctw.bmwgroup.com>
33
Date: Fri, 22 Mar 2024 13:27:38 +0000
4-
Subject: [PATCH 2/2] Add package configuration files
4+
Subject: [PATCH] Add package configuration files
55

66
Upstream-Status: Pending
7+
78
---
8-
lang/c++/CMakeLists.txt | 35 +++++++++++++++++++++++++++---
9-
lang/c++/cmake/AvroCppConfig.cmake | 5 +++++
10-
2 files changed, 37 insertions(+), 3 deletions(-)
9+
lang/c++/CMakeLists.txt | 45 ++++++++++++++++++++++++------
10+
lang/c++/cmake/AvroCppConfig.cmake | 5 ++++
11+
2 files changed, 42 insertions(+), 8 deletions(-)
1112
create mode 100644 lang/c++/cmake/AvroCppConfig.cmake
1213

1314
diff --git a/CMakeLists.txt b/CMakeLists.txt
14-
index d94ba42d3..2e5a394cb 100644
15+
index d94ba42d3..4748b111d 100644
1516
--- a/CMakeLists.txt
1617
+++ b/CMakeLists.txt
17-
@@ -140,12 +140,16 @@ set (CPACK_PACKAGE_FILE_NAME "avrocpp-${AVRO_VERSION_MAJOR}")
18+
@@ -140,14 +140,18 @@ set (CPACK_PACKAGE_FILE_NAME "avrocpp-${AVRO_VERSION_MAJOR}")
1819

1920
include (CPack)
2021

2122
-install (TARGETS avrocpp avrocpp_s
23+
- LIBRARY DESTINATION lib
24+
- ARCHIVE DESTINATION lib
25+
- RUNTIME DESTINATION lib)
26+
-
27+
-install (TARGETS avrogencpp RUNTIME DESTINATION bin)
28+
-
29+
-install (DIRECTORY api/ DESTINATION include/avro
2230
+install (TARGETS avrocpp
2331
+ EXPORT AvroCppTargets
24-
LIBRARY DESTINATION lib
25-
ARCHIVE DESTINATION lib
26-
- RUNTIME DESTINATION lib)
27-
+ RUNTIME DESTINATION lib
32+
+ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
33+
+ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
34+
+ RUNTIME DESTINATION ${CMAKE_INSTALL_LIBDIR}
2835
+ INCLUDES DESTINATION include)
29-
30-
-install (TARGETS avrogencpp RUNTIME DESTINATION bin)
36+
+
3137
+install (TARGETS avrogencpp
3238
+ EXPORT AvroCppTargets
33-
+ RUNTIME DESTINATION bin)
34-
35-
install (DIRECTORY api/ DESTINATION include/avro
39+
+ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR})
40+
+
41+
+install (DIRECTORY api/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/avro
3642
FILES_MATCHING PATTERN *.hh)
43+
44+
if (NOT CMAKE_BUILD_TYPE)
3745
@@ -155,3 +159,28 @@ if (NOT CMAKE_BUILD_TYPE)
3846
"Choose the type of build, options are: None Debug Release RelWithDebInfo MinSizeRel."
3947
FORCE)
@@ -52,7 +60,7 @@ index d94ba42d3..2e5a394cb 100644
5260
+ COPYONLY
5361
+)
5462
+
55-
+set(ConfigPackageLocation lib/cmake/avrocpp)
63+
+set(ConfigPackageLocation ${CMAKE_INSTALL_LIBDIR}/cmake/avrocpp)
5664
+install(EXPORT AvroCppTargets
5765
+ FILE AvroCppTargets.cmake
5866
+ NAMESPACE AvroCpp::
@@ -74,6 +82,3 @@ index 000000000..deb8aaa31
7482
+ COMPONENTS filesystem iostreams program_options regex system)
7583
+
7684
+include("${CMAKE_CURRENT_LIST_DIR}/AvroCppTargets.cmake")
77-
--
78-
2.44.0
79-
Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,16 @@
1-
From 640c51c61536913b3d43714bebe228b32f043144 Mon Sep 17 00:00:00 2001
1+
From 66c08ade24e4472b5af5dca48097ed9a2ec035ec Mon Sep 17 00:00:00 2001
22
From: Rui Costa <rui.ms.costa@ctw.bmwgroup.com>
33
Date: Fri, 5 Apr 2024 11:33:51 +0000
4-
Subject: [PATCH 3/3] Update CXX standard to CXX14
4+
Subject: [PATCH] Update CXX standard to CXX14
55

66
Upstream-Status: Inappropriate [oe-specific]
7+
78
---
89
lang/c++/CMakeLists.txt | 2 +-
910
1 file changed, 1 insertion(+), 1 deletion(-)
1011

1112
diff --git a/CMakeLists.txt b/CMakeLists.txt
12-
index 2e5a394cb..f29a532ef 100644
13+
index 4748b111d..1e45c13d5 100644
1314
--- a/CMakeLists.txt
1415
+++ b/CMakeLists.txt
1516
@@ -21,7 +21,7 @@ cmake_minimum_required (VERSION 3.1)
@@ -21,6 +22,3 @@ index 2e5a394cb..f29a532ef 100644
2122
endif()
2223

2324
set(CMAKE_CXX_STANDARD_REQUIRED ON)
24-
--
25-
2.44.0
26-

meta-oe/recipes-support/avro/avro-c++_1.11.3.bb

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
SUMMARY = "Apache Avro data serialization system."
2-
HOMEPAGE = "http://apr.apache.org/"
2+
HOMEPAGE = "https://avro.apache.org/"
33
SECTION = "libs"
44

55
LICENSE = "Apache-2.0"
@@ -18,3 +18,5 @@ SRC_URI = "git://github.com/apache/avro;branch=${BRANCH};protocol=https \
1818
S = "${WORKDIR}/git/lang/c++"
1919

2020
inherit cmake pkgconfig
21+
22+
BBCLASSEXTEND = "native nativesdk"

meta-oe/recipes-support/avro/avro-c_1.11.3.bb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
SUMMARY = "Apache Avro data serialization system."
2-
HOMEPAGE = "http://apr.apache.org/"
2+
HOMEPAGE = "https://avro.apache.org/"
33
SECTION = "libs"
44

55
LICENSE = "Apache-2.0"

0 commit comments

Comments
 (0)