From d73e6412b7d8453b25c91f324c81d88f8abbcd51 Mon Sep 17 00:00:00 2001 From: dongjiuzhu1 Date: Sat, 29 Jul 2023 10:06:57 +0800 Subject: [PATCH] apps/gpsutils: move gpsutils to nuttx/libs/libc/gpsutils Signed-off-by: dongjiuzhu1 --- CMakeLists.txt | 1 - examples/gps/CMakeLists.txt | 4 +-- examples/gps/Makefile | 2 +- examples/gps/gps_main.c | 2 +- gpsutils/.gitignore | 1 - gpsutils/CMakeLists.txt | 21 --------------- gpsutils/Make.defs | 21 --------------- gpsutils/Makefile | 23 ---------------- gpsutils/README.md | 10 ------- gpsutils/minmea/.gitignore | 2 -- gpsutils/minmea/Kconfig | 17 ------------ gpsutils/minmea/Make.defs | 24 ----------------- gpsutils/minmea/Makefile | 52 ------------------------------------- 13 files changed, 3 insertions(+), 177 deletions(-) delete mode 100644 gpsutils/.gitignore delete mode 100644 gpsutils/CMakeLists.txt delete mode 100644 gpsutils/Make.defs delete mode 100644 gpsutils/Makefile delete mode 100644 gpsutils/README.md delete mode 100644 gpsutils/minmea/.gitignore delete mode 100644 gpsutils/minmea/Kconfig delete mode 100644 gpsutils/minmea/Make.defs delete mode 100644 gpsutils/minmea/Makefile diff --git a/CMakeLists.txt b/CMakeLists.txt index e605de9d8..383820fd6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -45,7 +45,6 @@ add_subdirectory(canutils) add_subdirectory(crypto) add_subdirectory(fsutils) add_subdirectory(games) -add_subdirectory(gpsutils) add_subdirectory(graphics) add_subdirectory(industry) add_subdirectory(interpreters) diff --git a/examples/gps/CMakeLists.txt b/examples/gps/CMakeLists.txt index 42c294dad..26103014f 100644 --- a/examples/gps/CMakeLists.txt +++ b/examples/gps/CMakeLists.txt @@ -29,7 +29,5 @@ if(CONFIG_EXAMPLES_GPS) MODULE ${CONFIG_EXAMPLES_GPS} SRCS - gps_main.c - INCLUDE_DIRECTORIES - ${NUTTX_APPS_DIR}/gpsutils/minmea) + gps_main.c) endif() diff --git a/examples/gps/Makefile b/examples/gps/Makefile index e39d4be8e..efac4f0ba 100644 --- a/examples/gps/Makefile +++ b/examples/gps/Makefile @@ -28,7 +28,7 @@ STACKSIZE = $(CONFIG_EXAMPLES_GPS_STACKSIZE) MODULE = $(CONFIG_EXAMPLES_GPS) # GPS Example -CFLAGS += -I$(APPDIR)$(DELIM)gpsutils$(DELIM)minmea + MAINSRC = gps_main.c include $(APPDIR)/Application.mk diff --git a/examples/gps/gps_main.c b/examples/gps/gps_main.c index e55a60e2d..ef9a886b0 100644 --- a/examples/gps/gps_main.c +++ b/examples/gps/gps_main.c @@ -30,7 +30,7 @@ #include #include -#include "minmea/minmea.h" +#include /**************************************************************************** * Pre-processor Definitions diff --git a/gpsutils/.gitignore b/gpsutils/.gitignore deleted file mode 100644 index 9e1d2593e..000000000 --- a/gpsutils/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/Kconfig diff --git a/gpsutils/CMakeLists.txt b/gpsutils/CMakeLists.txt deleted file mode 100644 index 9c321c3d2..000000000 --- a/gpsutils/CMakeLists.txt +++ /dev/null @@ -1,21 +0,0 @@ -# ############################################################################## -# apps/gpsutils/CMakeLists.txt -# -# Licensed to the Apache Software Foundation (ASF) under one or more contributor -# license agreements. See the NOTICE file distributed with this work for -# additional information regarding copyright ownership. The ASF licenses this -# file to you 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. -# -# ############################################################################## - -nuttx_generate_kconfig(MENUDESC "GPS Utilities") diff --git a/gpsutils/Make.defs b/gpsutils/Make.defs deleted file mode 100644 index 2cc53fa1f..000000000 --- a/gpsutils/Make.defs +++ /dev/null @@ -1,21 +0,0 @@ -############################################################################ -# apps/gpsutils/Make.defs -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. The -# ASF licenses this file to you 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. -# -############################################################################ - -include $(wildcard $(APPDIR)/gpsutils/*/Make.defs) diff --git a/gpsutils/Makefile b/gpsutils/Makefile deleted file mode 100644 index 63dbee918..000000000 --- a/gpsutils/Makefile +++ /dev/null @@ -1,23 +0,0 @@ -############################################################################ -# apps/gpsutils/Makefile -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. The -# ASF licenses this file to you 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. -# -############################################################################ - -MENUDESC = "GPS Utilities" - -include $(APPDIR)/Directory.mk diff --git a/gpsutils/README.md b/gpsutils/README.md deleted file mode 100644 index e05d9a1ea..000000000 --- a/gpsutils/README.md +++ /dev/null @@ -1,10 +0,0 @@ -# `gpsutils` GPS Utilities - -The `gpsutils` directory is used to include libraries from external projects -that are not part of NuttX Applications, but are useful for NuttX developers and -users. - -## `minmea` GPS NMEA 0183 parser - -MINMEA is a NMEA parser developed by Kosma Moczek. Kosma is also a NuttX -contributor. diff --git a/gpsutils/minmea/.gitignore b/gpsutils/minmea/.gitignore deleted file mode 100644 index 89885ca8a..000000000 --- a/gpsutils/minmea/.gitignore +++ /dev/null @@ -1,2 +0,0 @@ -/minmea -/*.zip diff --git a/gpsutils/minmea/Kconfig b/gpsutils/minmea/Kconfig deleted file mode 100644 index c762f8ebd..000000000 --- a/gpsutils/minmea/Kconfig +++ /dev/null @@ -1,17 +0,0 @@ -# -# For a description of the syntax of this configuration file, -# see the file kconfig-language.txt in the NuttX tools repository. -# - -config GPSUTILS_MINMEA_LIB - bool "MINMEA NMEA Library" - default n - ---help--- - Enable support for the MINMEA NMEA library. - - NOTE: This library depends on having some version of math.h - at include/nuttx. There are some different ways to accomplish - this. See the discussion in the top-level nuttx/README.txt file. - -if GPSUTILS_MINMEA_LIB -endif diff --git a/gpsutils/minmea/Make.defs b/gpsutils/minmea/Make.defs deleted file mode 100644 index 849301868..000000000 --- a/gpsutils/minmea/Make.defs +++ /dev/null @@ -1,24 +0,0 @@ -############################################################################ -# apps/gpsutils/minmea/Make.defs -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. The -# ASF licenses this file to you 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. -# -############################################################################ - -ifneq ($(CONFIG_GPSUTILS_MINMEA_LIB),) -CONFIGURED_APPS += $(APPDIR)/gpsutils/minmea -CFLAGS += ${INCDIR_PREFIX}$(APPDIR)/gpsutils/minmea -endif diff --git a/gpsutils/minmea/Makefile b/gpsutils/minmea/Makefile deleted file mode 100644 index 002950138..000000000 --- a/gpsutils/minmea/Makefile +++ /dev/null @@ -1,52 +0,0 @@ -############################################################################ -# apps/gpsutils/minmea/Makefile -# -# Licensed to the Apache Software Foundation (ASF) under one or more -# contributor license agreements. See the NOTICE file distributed with -# this work for additional information regarding copyright ownership. The -# ASF licenses this file to you 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. -# -############################################################################ - -include $(APPDIR)/Make.defs - -MINMEA_URL ?= "https://github.com/kosma/minmea/archive" -MINMEA_VERSION ?= db46128e73cee26d6a6eb0482dcba544ee1ea9f5 - -MINMEA_UNPACKNAME = minmea - -$(MINMEA_UNPACKNAME): - @echo "Downloading: $(MINMEA_UNPACKNAME)" - $(Q) curl -O -L $(MINMEA_URL)/$(MINMEA_VERSION).zip - $(Q) mkdir $(MINMEA_UNPACKNAME) - $(Q) unzip -o -j $(MINMEA_VERSION).zip -d $(MINMEA_UNPACKNAME) - $(call DELFILE, $(MINMEA_VERSION).zip) - -# Files - -CSRCS = minmea/minmea.c -CFLAGS += -std=c99 - - -clean:: - $(call DELFILE, $(OBJS)) - -# Download and unpack tarball if no git repo found -ifeq ($(wildcard $(MINMEA_UNPACKNAME)/.git),) -context:: $(MINMEA_UNPACKNAME) - -distclean:: - $(call DELDIR, $(MINMEA_UNPACKNAME)) -endif - -include $(APPDIR)/Application.mk