modify makefile eventually
This commit is contained in:
parent
aabb860bb2
commit
18537fc922
|
@ -129,6 +129,8 @@ clean:
|
|||
@rm -rf services/tools/mkfs/mkfs
|
||||
@rm -rf services/app/fs.img
|
||||
@rm -rf services/app/user.map
|
||||
@rm -rf services/net/net_server/user.map
|
||||
@rm -rf services/net/net_server/bin
|
||||
|
||||
distclean:
|
||||
@echo Clean all configuration
|
||||
|
|
|
@ -26,7 +26,7 @@ INC_DIR = -I$(KERNEL_ROOT)/services/shell/letter-shell \
|
|||
-I$(KERNEL_ROOT)/services/app
|
||||
|
||||
ifeq ($(BOARD), imx6q-sabrelite)
|
||||
all: init test_fs simple_client simple_server shell fs_server test_irq_hdlr test_irq_block test_irq_send eth_driver epit_server readme.txt | bin
|
||||
all: init test_fs simple_client simple_server shell fs_server test_irq_hdlr test_irq_block test_irq_send eth_driver epit_server readme.txt lwip | bin
|
||||
else
|
||||
all: init test_fs simple_client simple_server shell fs_server test_irq_hdlr readme.txt | bin
|
||||
endif
|
||||
|
|
|
@ -55,11 +55,9 @@ libipc = $(KERNEL_ROOT)/services/app/libipc.o
|
|||
|
||||
lwip: COMPILER lwip_server.o | bin
|
||||
@${ld} ${user_ldflags} -e main -o $@ ${api} ${core} ${ipv4} ${netif} lwip_service.o lwip_server.o \
|
||||
${board_specs} ${libserial} ${printf} ${libmem} ${usyscall} ${arch_usyscall} ${arch_usyscall} \
|
||||
${session} ${libipc}
|
||||
@${objdump} -S $@ > $@.asm
|
||||
${board_specs} ${libserial} ${printf} ${libmem} ${usyscall} ${arch_usyscall} ${session} ${libipc}
|
||||
@mv *.o bin
|
||||
@mv *.asm bin
|
||||
@mv $@ $(KERNEL_ROOT)/services/app
|
||||
|
||||
bin:
|
||||
@mkdir -p bin
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
#include "lwip/init.h"
|
||||
#include "lwip/ip4_addr.h"
|
||||
#include "lwip/netif.h"
|
||||
#include "netif/ethernet.h"
|
||||
|
||||
static struct netif gnetif;
|
||||
|
||||
|
@ -30,8 +31,14 @@ int IPC_DO_SERVE_FUNC(Ipc_LWIP_init)(char* ip, char* mask, char* gw){
|
|||
|
||||
lwip_init();
|
||||
|
||||
// netif_add(&gnetif, &net_ipaddr, &net_netmask, &net_gw, NULL,
|
||||
// ðernetif_init, ðernet_input);
|
||||
#ifndef NETIF_ENET_INIT_FUNC
|
||||
printf("Not Netif driver for Eport 0\n");
|
||||
return 0;
|
||||
#endif
|
||||
|
||||
#ifdef NETIF_ENET_INIT_FUNC
|
||||
netif_add(&gnetif, &net_ipaddr, &net_netmask, &net_gw, NULL,
|
||||
NETIF_ENET_INIT_FUNC, ðernet_input);
|
||||
|
||||
/* Registers the default network interface */
|
||||
netif_set_default(&gnetif);
|
||||
|
@ -47,6 +54,7 @@ int IPC_DO_SERVE_FUNC(Ipc_LWIP_init)(char* ip, char* mask, char* gw){
|
|||
netif_set_down(&gnetif);
|
||||
}
|
||||
return 0;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue