From ad2d6433ace1e9d65e2c5226bf39c0658ec1d49c Mon Sep 17 00:00:00 2001 From: JeanTracker Date: Wed, 26 Jun 2024 10:44:58 +0900 Subject: [PATCH] build ci: add nobel add ubuntu noble to build ci Signed-off-by: JeanTracker --- .github/workflows/pull_request.yaml | 5 +- .github/workflows/push.yaml | 3 + CMakeLists.txt | 6 +- packaging/noble/changelog | 29 +++++ packaging/noble/compat | 1 + packaging/noble/control | 80 ++++++++++++ packaging/noble/copyright | 114 ++++++++++++++++++ packaging/noble/libnugu-dev.install | 3 + packaging/noble/libnugu-examples.install | 2 + .../noble/libnugu-examples.lintian-overrides | 6 + .../noble/libnugu-plugins-default.install | 1 + .../libnugu-plugins-default.lintian-overrides | 6 + packaging/noble/libnugu.install | 2 + packaging/noble/libnugu.lintian-overrides | 4 + packaging/noble/rules | 26 ++++ packaging/noble/source/format | 1 + packaging/noble/source/lintian-overrides | 2 + 17 files changed, 288 insertions(+), 3 deletions(-) create mode 100644 packaging/noble/changelog create mode 100644 packaging/noble/compat create mode 100644 packaging/noble/control create mode 100644 packaging/noble/copyright create mode 100644 packaging/noble/libnugu-dev.install create mode 100644 packaging/noble/libnugu-examples.install create mode 100644 packaging/noble/libnugu-examples.lintian-overrides create mode 100644 packaging/noble/libnugu-plugins-default.install create mode 100644 packaging/noble/libnugu-plugins-default.lintian-overrides create mode 100644 packaging/noble/libnugu.install create mode 100644 packaging/noble/libnugu.lintian-overrides create mode 100755 packaging/noble/rules create mode 100644 packaging/noble/source/format create mode 100644 packaging/noble/source/lintian-overrides diff --git a/.github/workflows/pull_request.yaml b/.github/workflows/pull_request.yaml index aac1a56ac..d332a3d12 100644 --- a/.github/workflows/pull_request.yaml +++ b/.github/workflows/pull_request.yaml @@ -23,7 +23,7 @@ jobs: runs-on: ubuntu-latest needs: [checkpatch_review, clang_tidy_review] strategy: - fail-fast: true + fail-fast: false matrix: target: [ @@ -36,6 +36,9 @@ jobs: jammy_x64, jammy_arm64, jammy_armhf, + noble_x64, + noble_arm64, + noble_armhf, ] steps: - name: Check out the repo diff --git a/.github/workflows/push.yaml b/.github/workflows/push.yaml index 0af132468..717aa86b8 100644 --- a/.github/workflows/push.yaml +++ b/.github/workflows/push.yaml @@ -23,6 +23,9 @@ jobs: jammy_x64, jammy_arm64, jammy_armhf, + noble_x64, + noble_arm64, + noble_armhf, ] steps: - name: Info diff --git a/CMakeLists.txt b/CMakeLists.txt index 40a4b5c35..ea9b73fac 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -444,8 +444,10 @@ IF (NOT BUILD_LIBRARY) ENDIF() IF (NOT IS_MACOS) - # Run-time buffer overflow detection - ADD_DEFINITIONS(-D_FORTIFY_SOURCE=2) + IF (NOT "${CMAKE_BUILD_TYPE}" STREQUAL "RelWithDebInfo") + # Run-time buffer overflow detection + ADD_DEFINITIONS(-D_FORTIFY_SOURCE=2) + ENDIF() ENDIF() # Global compile options diff --git a/packaging/noble/changelog b/packaging/noble/changelog new file mode 100644 index 000000000..3524b42c0 --- /dev/null +++ b/packaging/noble/changelog @@ -0,0 +1,29 @@ +nugu (1.7.6ubuntu1~noble) noble; urgency=medium + + * Fixed memory deallocation pair + * Fixed NuguClient hang-up issue + * Fixed AudioRecorderManager to use NuguRunner + * Fixed seek time unit + * Fixed media player position handling + * Fixed pthread mutex usage + * Fixed curl log to skip CRLF data + * Fixed capability version check + * Fixed clang-tidy analysis issues + * Fixed macOS/CodeQL build error + * Added to support Windows OS + * Added nugu_audio attribute getter API + * Added voice streaming recognition + * Added black duck analysis in CI + * Updated SpeechRecognizer + * Updated NetworkManager + * Updated PlaySyncManager + * Updated plugin architecture to support embedding + * Updated method documentation + * Updated Github action to reuse workflows + * Upgraded Github action version + * Enhanced speex validation check + * Improved AudioPlayer playsync handling + * Refactoring NuguRunner + * Refactoring entire build script + + -- nugulinux Wed, 26 Jun 2024 11:30:00 +0900 diff --git a/packaging/noble/compat b/packaging/noble/compat new file mode 100644 index 000000000..f599e28b8 --- /dev/null +++ b/packaging/noble/compat @@ -0,0 +1 @@ +10 diff --git a/packaging/noble/control b/packaging/noble/control new file mode 100644 index 000000000..6996f4c85 --- /dev/null +++ b/packaging/noble/control @@ -0,0 +1,80 @@ +Source: nugu +Section: libs +Priority: optional +Maintainer: Inho Oh +Build-Depends: debhelper (>=10), + cmake, + pkgconf, + git-core, + libnugu-kwd-dev, + libnugu-epd-dev, + libglib2.0-dev, + libcurl4-openssl-dev, + libopus-dev, + portaudio19-dev, + libssl-dev, + libasound2-dev, + libgstreamer-plugins-base1.0-dev, + libgstreamer1.0-dev, + ca-certificates, + rapidjson-dev, + libasan6 +Standards-Version: 4.1.4 + +Package: libnugu +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Recommends: libnugu-plugins-default +Description: NUGU is an AI service platform + NUGU OpenSDK + . + NUGU is an AI platform that supports ASR and TTS. + . + The libnugu package provide shared libraries. + +Package: libnugu-dev +Architecture: any +Section: libdevel +Depends: libnugu, ${misc:Depends}, libnugu-kwd-dev, libnugu-epd-dev, libglib2.0-dev +Description: NUGU is an AI service platform (development files) + NUGU OpenSDK + . + NUGU is an AI platform that supports ASR and TTS. + . + The libnugu-dev package provide development files. + +Package: libnugu-dbg +Section: debug +Priority: optional +Architecture: any +Depends: libnugu (= ${binary:Version}), ${shlibs:Depends}, ${misc:Depends} +Description: NUGU is an AI service platform (debugging symbols) + NUGU OpenSDK + . + NUGU is an AI platform that supports ASR and TTS. + . + The libnugu-dbg package provide debugging symbols. + +Package: libnugu-plugins-default +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, + gstreamer1.0-plugins-base, + gstreamer1.0-plugins-good, + gstreamer1.0-plugins-bad, + gstreamer1.0-plugins-ugly +Description: NUGU is an AI service platform (plugins) + NUGU OpenSDK + . + NUGU is an AI platform that supports ASR and TTS. + . + The libnugu-plugins-default package provide default plugins. + +Package: libnugu-examples +Architecture: any +Depends: libnugu, ${shlibs:Depends}, ${misc:Depends}, curl, jq +Description: NUGU is an AI service platform (examples) + NUGU OpenSDK + . + NUGU is an AI platform that supports ASR and TTS. + . + The libnugu-examples package provide examples. diff --git a/packaging/noble/copyright b/packaging/noble/copyright new file mode 100644 index 000000000..e000ded8a --- /dev/null +++ b/packaging/noble/copyright @@ -0,0 +1,114 @@ +Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ + +Files: * +Copyright: (c) 2019 SK Telecom Co., Ltd. All rights reserved. +License: Apache-2.0 + +Files: externals/nghttp2/* +Copyright: (c) 2012, 2014, 2015, 2016 Tatsuhiro Tsujikawa + (c) 2012, 2014, 2015, 2016 nghttp2 contributors +License: MIT + +Files: externals/curl/* +Copyright: (c) 1996 - 2019, Daniel Stenberg, +License: curl + +Files: externals/opus/* +Copyright: 2001-2011 Xiph.Org, Skype Limited, Octasic, + Jean-Marc Valin, Timothy B. Terriberry, + CSIRO, Gregory Maxwell, Mark Borgerding, + Erik de Castro Lopo +License: opus + +License: Apache-2.0 + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + . + http://www.apache.org/licenses/LICENSE-2.0 + . + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. + . + On Debian systems, the full text of the Apache License version 2 can + be found in /usr/share/common-licenses/Apache-2.0. + +License: MIT + Permission to use, copy, modify, and distribute this software for any purpose + with or without fee is hereby granted, provided that the above copyright + notice and this permission notice appear in all copies. + . + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS. IN + NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR + OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE + OR OTHER DEALINGS IN THE SOFTWARE. + . + Except as contained in this notice, the name of a copyright holder shall not + be used in advertising or otherwise to promote the sale, use or other dealings + in this Software without prior written authorization of the copyright holder. + +License: curl + All rights reserved. + . + Permission to use, copy, modify, and distribute this software for any purpose + with or without fee is hereby granted, provided that the above copyright + notice and this permission notice appear in all copies. + . + THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OF THIRD PARTY RIGHTS. IN + NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, + DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR + OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE + OR OTHER DEALINGS IN THE SOFTWARE. + . + Except as contained in this notice, the name of a copyright holder shall not + be used in advertising or otherwise to promote the sale, use or other dealings + in this Software without prior written authorization of the copyright holder. + +License: opus + Redistribution and use in source and binary forms, with or without + modification, are permitted provided that the following conditions + are met: + . + - Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + . + - Redistributions in binary form must reproduce the above copyright + notice, this list of conditions and the following disclaimer in the + documentation and/or other materials provided with the distribution. + . + - Neither the name of Internet Society, IETF or IETF Trust, nor the + names of specific contributors, may be used to endorse or promote + products derived from this software without specific prior written + permission. + . + THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR + A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER + OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, + PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR + PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF + LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS + SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + . + Opus is subject to the royalty-free patent licenses which are + specified at: + . + Xiph.Org Foundation: + https://datatracker.ietf.org/ipr/1524/ + . + Microsoft Corporation: + https://datatracker.ietf.org/ipr/1914/ + . + Broadcom Corporation: + https://datatracker.ietf.org/ipr/1526/ diff --git a/packaging/noble/libnugu-dev.install b/packaging/noble/libnugu-dev.install new file mode 100644 index 000000000..9f8b96bfa --- /dev/null +++ b/packaging/noble/libnugu-dev.install @@ -0,0 +1,3 @@ +debian/tmp/usr/lib/*/*.so +debian/tmp/usr/include/* +debian/tmp/usr/lib/*/pkgconfig/* diff --git a/packaging/noble/libnugu-examples.install b/packaging/noble/libnugu-examples.install new file mode 100644 index 000000000..0acf7dffd --- /dev/null +++ b/packaging/noble/libnugu-examples.install @@ -0,0 +1,2 @@ +debian/tmp/usr/bin/* +debian/tmp/usr/share/nugu/testcases/* diff --git a/packaging/noble/libnugu-examples.lintian-overrides b/packaging/noble/libnugu-examples.lintian-overrides new file mode 100644 index 000000000..f90aeb587 --- /dev/null +++ b/packaging/noble/libnugu-examples.lintian-overrides @@ -0,0 +1,6 @@ +binary-without-manpage usr/bin/nugusdk_start_sample +binary-without-manpage usr/bin/nugu_sample +binary-without-manpage usr/bin/nugu_oob_server +binary-without-manpage usr/bin/nugu_simple_asr +binary-without-manpage usr/bin/nugu_simple_text +binary-without-manpage usr/bin/nugu_capability_injection diff --git a/packaging/noble/libnugu-plugins-default.install b/packaging/noble/libnugu-plugins-default.install new file mode 100644 index 000000000..aab2dfd8d --- /dev/null +++ b/packaging/noble/libnugu-plugins-default.install @@ -0,0 +1 @@ +debian/tmp/usr/lib/*/nugu/*.so diff --git a/packaging/noble/libnugu-plugins-default.lintian-overrides b/packaging/noble/libnugu-plugins-default.lintian-overrides new file mode 100644 index 000000000..945211ec5 --- /dev/null +++ b/packaging/noble/libnugu-plugins-default.lintian-overrides @@ -0,0 +1,6 @@ +library-not-linked-against-libc usr/lib/x86_64-linux-gnu/nugu/dummy.so +library-not-linked-against-libc usr/lib/x86_64-linux-gnu/nugu/light.so +library-not-linked-against-libc usr/lib/arm-linux-gnueabihf/nugu/dummy.so +library-not-linked-against-libc usr/lib/arm-linux-gnueabihf/nugu/light.so +library-not-linked-against-libc usr/lib/aarch64-linux-gnu/nugu/dummy.so +library-not-linked-against-libc usr/lib/aarch64-linux-gnu/nugu/light.so diff --git a/packaging/noble/libnugu.install b/packaging/noble/libnugu.install new file mode 100644 index 000000000..46601df8e --- /dev/null +++ b/packaging/noble/libnugu.install @@ -0,0 +1,2 @@ +debian/tmp/usr/lib/*/*.so.* +debian/tmp/usr/share/nugu/model/* diff --git a/packaging/noble/libnugu.lintian-overrides b/packaging/noble/libnugu.lintian-overrides new file mode 100644 index 000000000..0c27bb5db --- /dev/null +++ b/packaging/noble/libnugu.lintian-overrides @@ -0,0 +1,4 @@ +package-name-doesnt-match-sonames libnugu +embedded-library curl [usr/lib/x86_64-linux-gnu/libnugu.so.1.7.6] +embedded-library curl [usr/lib/arm-linux-gnueabihf/libnugu.so.1.7.6] +embedded-library curl [usr/lib/aarch64-linux-gnu/libnugu.so.1.7.6] diff --git a/packaging/noble/rules b/packaging/noble/rules new file mode 100755 index 000000000..137bd10f2 --- /dev/null +++ b/packaging/noble/rules @@ -0,0 +1,26 @@ +#!/usr/bin/make -f +# See debhelper(7) (uncomment to enable) +# output every command that modifies files on the build system. + +export DH_VERBOSE = 1 + +DEB_HOST_MULTIARCH ?= $(shell dpkg-architecture -qDEB_HOST_MULTIARCH) +DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) + +CFLAGS := $(shell dpkg-buildflags --get CFLAGS) +CFLAGS := $(filter-out -O2,$(CFLAGS)) + +%: + dh $@ --buildsystem=cmake + +override_dh_auto_configure: + dh_auto_configure -- \ + -DCMAKE_LIBRARY_ARCHITECTURE=${DEB_HOST_MULTIARCH} \ + -DCMAKE_C_COMPILER=$(DEB_HOST_GNU_TYPE)-gcc \ + -DCMAKE_CXX_COMPILER=$(DEB_HOST_GNU_TYPE)-g++ \ + -DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo \ + -DENABLE_EXAMPLES_OOB_SETUP=OFF \ + -DPACKAGING=1 + +override_dh_strip: + dh_strip --dbg-package=libnugu-dbg diff --git a/packaging/noble/source/format b/packaging/noble/source/format new file mode 100644 index 000000000..d3827e75a --- /dev/null +++ b/packaging/noble/source/format @@ -0,0 +1 @@ +1.0 diff --git a/packaging/noble/source/lintian-overrides b/packaging/noble/source/lintian-overrides new file mode 100644 index 000000000..df0f54300 --- /dev/null +++ b/packaging/noble/source/lintian-overrides @@ -0,0 +1,2 @@ +source-is-missing externals/nghttp2/doc/_themes/sphinx_rtd_theme/static/js/badge_only.js +source-is-missing externals/nghttp2/doc/_themes/sphinx_rtd_theme/static/js/theme.js