Commit e9ec1714 authored by Alessandro Rubini's avatar Alessandro Rubini

userspace: moved libs and wr_mon from ../on-switch-tests

parent 0b80f0f7
......@@ -13,8 +13,9 @@ WR_INSTALL_ROOT ?= $(WRS_OUTPUT_DIR)/images/wr
WRDEV_DIR ?= $(WRS_BASE_DIR)/..
# subdirectories we want to compile
SUBDIRS = libswitchhw wrsw_hal wrsw_rtud spll_dbg_proxy
# SUBDIRS += wrsw_rtud wr_mon rtu_stat
SUBDIRS = libswitchhw libwripc libptpnetif
SUBDIRS += wrsw_hal wrsw_rtud spll_dbg_proxy
SUBDIRS += wr_mon #rtu_stat
# all variables are exported
export
......
CC = $(CROSS_COMPILE)gcc
AR = $(CROSS_COMPILE)ar
CFLAGS = -I. -O2 -I../include -I../wrsw_hal -I../libwripc -DDEBUG
OBJS = hal_client.o netif_test.o ptpd_netif.o
LIB = libptpnetif.a
all: $(LIB)
$(LIB): $(OBJS)
$(AR) rc $@ $^
install: all
install -d $(WR_INSTALL_ROOT)/lib
install $(LIB) $(WR_INSTALL_ROOT)/lib
clean:
rm -f $(LIB) $(OBJS)
......@@ -4,7 +4,7 @@
#define __PTPD_NETIF_H
#include <stdio.h>
//#include <inttypes.h>
#include <stdint.h>
#define PTPD_SOCK_RAW_ETHERNET 1
#define PTPD_SOCK_UDP 2
......
CC = $(CROSS_COMPILE)gcc
AR = $(CROSS_COMPILE)ar
CFLAGS = -I. -O2 -I../include
OBJS = helper_arm.o wr_ipc.o
LIB = libwripc.a
all: $(LIB)
$(LIB): $(OBJS)
$(AR) rc $@ $^
install: all
install -d $(WR_INSTALL_ROOT)/lib
install $(LIB) $(WR_INSTALL_ROOT)/lib
clean:
rm -f $(LIB) $(OBJS)
#include <stdio.h>
#include <stdlib.h>
#include <stdint.h>
#include <string.h>
#include <unistd.h>
#include <fcntl.h>
......
......@@ -12,14 +12,21 @@ OBJDUMP = $(CROSS_COMPILE)objdump
MON_OBJS = wr_mon.o term.o
CFLAGS += -O2 -DDEBUG -I$(LINUX)/include
CFLAGS += -O2 -DDEBUG -I$(LINUX)/include -I../include \
-I../libptpnetif -I../wrsw_hal -I../libwripc
ALL = wr_mon
LDFLAGS = -L$(WR_INSTALL_ROOT)/lib -lptpnetif -lwripc
all: $(ALL)
BINARY = wr_mon
all: $(BINARY)
wr_mon: $(MON_OBJS)
${CC} $^ $(LDFLAGS) -o $@
clean:
rm -f $(ALL) *.o *~
\ No newline at end of file
rm -f $(BINARY) *.o *~
install:
install -d $(WR_INSTALL_ROOT)/bin
install $(BINARY) $(WR_INSTALL_ROOT)/bin
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment