From: Waldemar Kozaczuk <[email protected]>
Committer: Nadav Har'El <[email protected]>
Branch: master

Fixed compilation errors in modules mostly related to strlcpy

Signed-off-by: Waldemar Kozaczuk <[email protected]>
Message-Id: <[email protected]>

---
diff --git a/modules/cloud-init/Makefile b/modules/cloud-init/Makefile
--- a/modules/cloud-init/Makefile
+++ b/modules/cloud-init/Makefile
@@ -1,9 +1,9 @@
-INCLUDES = -I. -I../../include -I../../arch/$(ARCH) -I../.. \
-        -I../../build/$(mode)/gen/include
+SRC = $(shell readlink -f ../..)
+include $(SRC)/modules/java-base/common.gmk

 autodepend = -MD -MT $@ -MP
 CXXFLAGS  = -g -rdynamic -Wall -std=c++11 -fPIC $(INCLUDES) $(autodepend)
-src = ../..
+src = $(SRC)
 arch = x64

 boost-libs := -lboost_system -lboost_filesystem
diff --git a/modules/golang/Makefile b/modules/golang/Makefile
--- a/modules/golang/Makefile
+++ b/modules/golang/Makefile
@@ -1,5 +1,5 @@
-INCLUDES = -I. -I../../include -I../../arch/$(ARCH) -I../.. \
-        -I../../build/$(mode)/gen/include
+SRC = $(shell readlink -f ../..)
+include $(SRC)/modules/java-base/common.gmk

 autodepend = -MD -MT $@ -MP
 CXXFLAGS  = -g -rdynamic -Wall -std=c++11 -fPIC $(INCLUDES) $(autodepend)
@@ -10,8 +10,6 @@ CPP_FILES := $(TARGET).cc
 OBJ_FILES := $(addprefix obj/,$(CPP_FILES:.cc=.o))
 DEPS := $(OBJ_FILES:.o=.d)

-LIBS = -lpthread
-
 quiet = $(if $V, $1, @echo " $2"; $1)
 very-quiet = $(if $V, $1, @$1)

diff --git a/modules/httpserver-api/Makefile b/modules/httpserver-api/Makefile
--- a/modules/httpserver-api/Makefile
+++ b/modules/httpserver-api/Makefile
@@ -1,5 +1,6 @@
-INCLUDES = -I. -I../../include -I../../arch/$(ARCH) -I../.. \
-       -I../../build/$(mode)/gen/include
+SRC = $(shell readlink -f ../..)
+include $(SRC)/modules/java-base/common.gmk
+INCLUDES += -I. -I $(SRC)/libc/internal

 # compiler flags:
 #  -g    adds debugging information to the executable file
@@ -95,8 +96,8 @@ obj/%.o: %.cc
        $(call quiet, $(CXX) $(CXXFLAGS) -c -MMD  -o $@ $<, CXX $@)

 clean:
-       $(call quiet, $(RM) $(TARGET), CLEAN)
-       $(call very-quiet, $(RM) lib*.so)
+       $(call quiet, $(RM) -f $(TARGET), CLEAN)
+       $(call very-quiet, $(RM) -f lib*.so)
        $(call very-quiet, $(RM) -rf obj)
        $(call very-quiet, $(RM) -rf autogen)
        $(call very-quiet, $(RM) -f *usr*.manifest)
diff --git a/modules/httpserver-api/api/env.cc b/modules/httpserver-api/api/env.cc
--- a/modules/httpserver-api/api/env.cc
+++ b/modules/httpserver-api/api/env.cc
@@ -8,6 +8,7 @@
 #include "env.hh"
 #include "autogen/env.json.hh"
 #include <stdlib.h>
+#include <libc.h>

 namespace httpserver {

diff --git a/modules/java-base/common.gmk b/modules/java-base/common.gmk
--- a/modules/java-base/common.gmk
+++ b/modules/java-base/common.gmk
@@ -13,7 +13,6 @@ autodepend = -MD -MT $@ -MP
COMMON_FLAGS = -g -Wall -fPIC $(INCLUDES) -O2 $(autodepend) -DCONF_debug_memory=0 -D_KERNEL
 CXXFLAGS  = -std=c++11 $(COMMON_FLAGS)
 CFLAGS = -std=gnu99 $(COMMON_FLAGS)
-#CXXFLAGS = -g -Wall -std=c++11 -fPIC $(INCLUDES) -O2 $(autodepend) $(configuration)
 src = $(shell readlink -f ../..)

 RM := /bin/rm

--
You received this message because you are subscribed to the Google Groups "OSv 
Development" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/osv-dev/0000000000005e1c8c058e2b85f5%40google.com.

Reply via email to