⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 makefile

📁 picoos源码。The RTOS and the TCP/IP stack will be built automatically.
💻
字号:
#  Copyright (c) 2004-2005, Dennis Kuschel / Swen Moczarski
#  All rights reserved. 
#
#  Redistribution and use in source and binary forms, with or without
#  modification, are permitted provided that the following conditions
#  are met:
#
#   1. Redistributions of source code must retain the above copyright
#      notice, this list of conditions and the following disclaimer.
#   2. 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.
#   3. The name of the author may not be used to endorse or promote
#      products derived from this software without specific prior written
#      permission. 
#
#  THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``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 AUTHOR 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.


#  This file is originally from the pico]OS realtime operating system
#  (http://picoos.sourceforge.net).
#
#  $Id: makefile,v 1.1 2005/02/07 22:56:52 dkuschel Exp $


# --------------------------------------------------------------------------

include lwip_cfg.mak

# Set root path and include base make file
RELROOT = ../../../picoos/

# Get pico]OS path from environment (if it is set)
ifneq '$(strip $(PICOOS))' ''
RELROOT := $(PICOOS)/
endif

-include ../findpico.mak
include $(RELROOT)make/common.mak

# Set target file name (name of generated library)
TARGET = lwip


# --------------------------------------------------------------------------

# Check lwIP version
ifeq '$(strip $(wildcard $(LWIP)/*))' ''
$(error Wrong lwIP version set in lwip_cfg.mak: $(LWIP). \
  Maybe the directory is missing or has a different name)
endif

# --------------------------------------------------------------------------

# Set lwip core source files
FILES_CORE = \
    $(LWIP)/src/core/mem.c      \
    $(LWIP)/src/core/memp.c     \
    $(LWIP)/src/core/netif.c    \
    $(LWIP)/src/core/pbuf.c     \
    $(LWIP)/src/core/raw.c      \
    $(LWIP)/src/core/stats.c    \
    $(LWIP)/src/core/sys.c      \
    $(LWIP)/src/core/tcp.c      \
    $(LWIP)/src/core/tcp_in.c   \
    $(LWIP)/src/core/tcp_out.c  \
    $(LWIP)/src/core/udp.c 

#FILES_CORE += $(LWIP)/src/core/dhcp.c

ifeq '$(IPVER)' 'ipv4'
FILES_CORE += \
    $(LWIP)/src/core/inet.c              \
    $(LWIP)/src/core/$(IPVER)/icmp.c     \
    $(LWIP)/src/core/$(IPVER)/ip.c       \
    $(LWIP)/src/core/$(IPVER)/ip_addr.c  \
    $(LWIP)/src/core/$(IPVER)/ip_frag.c
else
FILES_CORE += \
    $(LWIP)/src/core/inet6.c             \
    $(LWIP)/src/core/$(IPVER)/icmp6.c    \
    $(LWIP)/src/core/$(IPVER)/ip6.c      \
    $(LWIP)/src/core/$(IPVER)/ip6_addr.c
endif


# Set socket API files
FILES_API = \
    $(LWIP)/src/api/api_lib.c   \
    $(LWIP)/src/api/api_msg.c   \
    $(LWIP)/src/api/err.c       \
    $(LWIP)/src/api/sockets.c   \
    $(LWIP)/src/api/tcpip.c


# Set ethernet netif files
FILES_NETIF_ETH = \
    $(LWIP)/src/netif/etharp.c  \
    $(LWIP)/src/netif/loopif.c

# Set PPP netif files
FILES_NETIF_PPP = \
    $(LWIP)/src/netif/ppp/auth.c   \
    $(LWIP)/src/netif/ppp/chap.c   \
    $(LWIP)/src/netif/ppp/chpms.c  \
    $(LWIP)/src/netif/ppp/fsm.c    \
    $(LWIP)/src/netif/ppp/ipcp.c   \
    $(LWIP)/src/netif/ppp/lcp.c    \
    $(LWIP)/src/netif/ppp/magic.c  \
    $(LWIP)/src/netif/ppp/md5.c    \
    $(LWIP)/src/netif/ppp/pap.c    \
    $(LWIP)/src/netif/ppp/ppp.c    \
    $(LWIP)/src/netif/ppp/randm.c  \
    $(LWIP)/src/netif/ppp/vj.c

# Set netif files
#FILES_NETIF = $(FILES_NETIF_ETH) $(FILES_NETIF_PPP)
FILES_NETIF = $(FILES_NETIF_ETH)

# Set port source files
FILES_PORT = \
    $(LWIPPORT)/sys_arch.c


# Set header files
FILES_HEADER = \
	$(wildcard $(LWIPPORT)/include/arch/*.h)              \
	$(wildcard $(LWIPPORT)/include/netif/*.h)             \
	$(wildcard $(LWIPPORT)/include/$(LWIPARCH)/*.h)       \
	$(wildcard $(LWIPPORT)/include/$(LWIPARCH)/arch/*.h)  \
	$(wildcard $(LWIP)/src/include/lwip/*.h)              \
	$(wildcard $(LWIP)/src/include/netif/*.h)             \
	$(wildcard $(LWIP)/src/include/netif/ppp/*.h)         \
	$(wildcard $(LWIP)/src/include/$(IPVER)/lwip/*.h)


# ---------------------------------------------------------------------------

# Build sources list
SRC_TXT = $(FILES_CORE) $(FILES_API) $(FILES_NETIF) $(FILES_PORT)

# Set dependencies
SRC_HDR = $(FILES_HEADER)

# Set the output directory for the generated binaries
ifeq '$(strip $(DIR_OUTPUT))' ''
DIR_OUTPUT = $(CURRENTDIR)/bin
endif

# Set config directory (that one with opt.h / poscfg.h / noscfg.h)
#ifeq '$(strip $(DIR_CONFIG))' ''
#DIR_CONFIG = $(CURRENTDIR)/config
#$(warning DIR_CONFIG not set. Setting now: $(DIR_CONFIG))
#endif


# ---------------------------------------------------------------------------

# Build the library
include $(MAKE_LIB)

# ---------------------------------------------------------------------------

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -