You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2020/11/17 12:43:53 UTC

[GitHub] [incubator-nuttx-apps] xiaoxiang781216 commented on a change in pull request #482: netutils/netcat: Add netcat tool

xiaoxiang781216 commented on a change in pull request #482:
URL: https://github.com/apache/incubator-nuttx-apps/pull/482#discussion_r525122085



##########
File path: netutils/netcat/Kconfig
##########
@@ -0,0 +1,52 @@
+#############################################################################
+#
+# netutils/netcat/Kconfig
+# netcat networking application
+#
+# 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.
+#
+#############################################################################
+
+# For a description of the syntax of this configuration file,
+# see the file kconfig-language.txt in the NuttX tools repository.
+#
+
+config NETUTILS_NETCAT
+	bool "NetCat tool"
+	default n
+	select NET
+	select NET_TCP

Review comment:
       should we change to depends on NET_TCP? since all other place use depend not select.

##########
File path: netutils/netcat/Kconfig
##########
@@ -0,0 +1,52 @@
+#############################################################################
+#
+# netutils/netcat/Kconfig
+# netcat networking application
+#
+# 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.
+#
+#############################################################################
+
+# For a description of the syntax of this configuration file,
+# see the file kconfig-language.txt in the NuttX tools repository.
+#
+
+config NETUTILS_NETCAT
+	bool "NetCat tool"

Review comment:
       change to tristate so we can build netcat as elf binary

##########
File path: netutils/netcat/Makefile
##########
@@ -0,0 +1,38 @@
+#############################################################################
+#
+# netutils/netcat/Makefile
+# Netcat networking application
+#
+# 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
+-include $(SDKDIR)/Make.defs

Review comment:
       remove

##########
File path: netutils/netcat/Make.defs
##########
@@ -0,0 +1,25 @@
+#############################################################################
+#
+# netutils/netcat/Make.defs
+# netcat sample networking application
+#
+# 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.
+#
+#############################################################################
+
+ifeq ($(CONFIG_NETUTILS_NETCAT),y)
+CONFIGURED_APPS += netutils/netcat

Review comment:
       $(APPDIR)/netutils/netcat

##########
File path: netutils/netcat/Make.defs
##########
@@ -0,0 +1,25 @@
+#############################################################################
+#
+# netutils/netcat/Make.defs
+# netcat sample networking application
+#
+# 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.
+#
+#############################################################################
+
+ifeq ($(CONFIG_NETUTILS_NETCAT),y)

Review comment:
       change to ifneq ($(CONFIG_NETUTILS_NETCAT),)

##########
File path: netutils/netcat/Makefile
##########
@@ -0,0 +1,38 @@
+#############################################################################
+#
+# netutils/netcat/Makefile
+# Netcat networking application
+#
+# 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
+-include $(SDKDIR)/Make.defs
+
+# built-in application info
+
+PROGNAME = $(CONFIG_NETUTILS_NETCAT_PROGNAME)
+PRIORITY = $(CONFIG_NETUTILS_NETCAT_PRIORITY)
+STACKSIZE = $(CONFIG_NETUTILS_NETCAT_STACKSIZE)
+
+# Example
+
+ASRCS =
+CSRCS =

Review comment:
       remove ASRCS and CSRCS

##########
File path: netutils/netcat/Makefile
##########
@@ -0,0 +1,38 @@
+#############################################################################
+#
+# netutils/netcat/Makefile
+# Netcat networking application
+#
+# 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
+-include $(SDKDIR)/Make.defs
+
+# built-in application info
+
+PROGNAME = $(CONFIG_NETUTILS_NETCAT_PROGNAME)
+PRIORITY = $(CONFIG_NETUTILS_NETCAT_PRIORITY)
+STACKSIZE = $(CONFIG_NETUTILS_NETCAT_STACKSIZE)
+

Review comment:
       add MODULE = $(CONFIG_NETUTILS_NETCAT)




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org