diff --git a/.settings/language.settings.xml b/.settings/language.settings.xml index 200d3ff..5fd04a6 100644 --- a/.settings/language.settings.xml +++ b/.settings/language.settings.xml @@ -5,11 +5,7 @@ -<<<<<<< HEAD - -======= - ->>>>>>> branch 'master' of http://Git.BrainChurts.com:8080/git/MrOlsen/UbixOS.git + diff --git a/src/share/mk/bsd.buildinstall.mk b/src/share/mk/bsd.buildinstall.mk deleted file mode 100644 index 87c65b3..0000000 --- a/src/share/mk/bsd.buildinstall.mk +++ /dev/null @@ -1,29 +0,0 @@ -# $NetBSD: bsd.buildinstall.mk,v 1.1 2012/11/15 23:51:53 joerg Exp $ - -# -# build_install logic for src/Makefile -# Used by src/lib/Makefile and src/tools/Makefile. -# -# Compute a list of subdirectories delimited by .WAIT. -# Run "make dependall && make install" for all subdirectories in a group -# concurrently, but wait after each group. -# -SUBDIR_GROUPS= 1 -CUR_GROUP:= 1 -.for dir in ${SUBDIR} -. if ${dir} == ".WAIT" -CUR_GROUP:= ${CUR_GROUP}1 -SUBDIR_GROUPS:= ${SUBDIR_GROUPS} ${CUR_GROUP} -. else -SUBDIR_GROUP.${CUR_GROUP}+= ${dir} -.endif - -.endfor - -build_install: -.for group in ${SUBDIR_GROUPS} -. if !empty(SUBDIR_GROUP.${group}) - ${MAKEDIRTARGET} . ${SUBDIR_GROUP.${group}:C/^/dependall-/} - ${MAKEDIRTARGET} . ${SUBDIR_GROUP.${group}:C/^/install-/} -. endif -.endfor diff --git a/src/share/mk/bsd.clang-analyze.mk b/src/share/mk/bsd.clang-analyze.mk deleted file mode 100644 index 81912be..0000000 --- a/src/share/mk/bsd.clang-analyze.mk +++ /dev/null @@ -1,40 +0,0 @@ -# $NetBSD: bsd.clang-analyze.mk,v 1.3 2012/04/04 10:37:18 joerg Exp $ - -.ifndef CLANG_ANALYZE_SRCS - -CLANG_ANALYZE_FLAGS+= --analyze - -CLANG_ANALYZE_CHECKERS+= core deadcode security unix - -.for checker in ${CLANG_ANALYZE_CHECKERS} -CLANG_ANALYZE_FLAGS+= -Xanalyzer -analyzer-checker=${checker} -.endfor - -.SUFFIXES: .c .cc .cpp .cxx .C .clang-analyzer - -CLANG_ANALYZE_CFLAGS= ${CFLAGS:N-Wa,--fatal-warnings} -CLANG_ANALYZE_CXXFLAGS= ${CXXFLAGS:N-Wa,--fatal-warnings} - -.c.clang-analyzer: - ${TOOL_CC.clang} ${CLANG_ANALYZE_FLAGS} \ - ${CLANG_ANALYZE_CFLAGS} ${CPPFLAGS} \ - ${COPTS.${.IMPSRC:T}} ${CPUFLAGS.${.IMPSRC:T}} \ - ${CPPFLAGS.${.IMPSRC:T}} ${.IMPSRC} -.cc.clang-analyzer .cpp.clang-analyzer .cxx.clang-analyzer .C.clang-analyzer: - ${TOOL_CXX.clang} ${CLANG_ANALYZE_FLAGS} \ - ${CLANG_ANALYZE_CXXFLAGS} ${CPPFLAGS} \ - ${COPTS.${.IMPSRC:T}} ${CPUFLAGS.${.IMPSRC:T}} \ - ${CPPFLAGS.${.IMPSRC:T}} ${.IMPSRC} - -CLANG_ANALYZE_SRCS= \ - ${SRCS:M*.[cC]} ${SRCS:M*.cc} \ - ${SRCS:M*.cpp} ${SRCS:M*.cxx} \ - ${DPSRCS:M*.[cC]} ${DPSRCS:M*.cc} \ - ${DPSRCS:M*.cpp} ${DPSRCS:M*.cxx} -.if !empty(CLANG_ANALYZE_SRCS) -CLANG_ANALYZE_OUTPUT= ${CLANG_ANALYZE_SRCS:R:S,$,.clang-analyzer,} -.endif - -analyze: ${CLANG_ANALYZE_OUTPUT} - -.endif diff --git a/src/share/mk/bsd.clean.mk b/src/share/mk/bsd.clean.mk deleted file mode 100644 index 61b34b6..0000000 --- a/src/share/mk/bsd.clean.mk +++ /dev/null @@ -1,91 +0,0 @@ -# $NetBSD: bsd.clean.mk,v 1.8 2012/11/19 16:04:54 apb Exp $ - -# -# -# Public targets: -# -# clean: Delete files listed in ${CLEANFILES}. -# cleandir: Delete files listed in ${CLEANFILES} and ${CLEANDIRFILES}. -# -# Public variables: -# -# CLEANFILES Files to remove for both the clean and cleandir targets. -# -# CLEANDIRFILES Files to remove for the cleandir target, but not for -# the clean target. -# -# MKCLEANSRC Whether or not to clean the source directory -# in addition to the object directory. Defaults to "yes". -# -# MKCLEANVERIFY Whether or not to verify that the file deletion worked. -# Defaults to "yes". -# -# The files listed in CLEANFILES and CLEANDIRFILES must not be -# directories, because the potential risk from running "rm -rf" commands -# in bsd.clean.mk is considered too great. If you want to recursively -# delete a directory as part of "make clean" or "make cleandir" then you -# need to provide your own target. - -.if !defined(_BSD_CLEAN_MK_) -_BSD_CLEAN_MK_=1 - -.include - -MKCLEANSRC?= yes -MKCLEANVERIFY?= yes - -clean: .PHONY __doclean -__doclean: .PHONY .MADE __cleanuse CLEANFILES -cleandir: .PHONY clean __docleandir -__docleandir: .PHONY .MADE __cleanuse CLEANDIRFILES - -# __cleanuse is invoked with ${.ALLSRC} as the name of a variable -# (such as CLEANFILES or CLEANDIRFILES), or possibly a list of -# variable names. ${.ALLSRC:@v@${${v}}@} will be the list of -# files to delete. (We pass the variable name, e.g. CLEANFILES, -# instead of the file names, e.g. ${CLEANFILES}, because we don't -# want make to replace any of the file names with the result of -# searching .PATH.) -# -# If the list of files is empty, then the commands -# reduce to "true", with an "@" prefix to prevent echoing. -# -# The use of :M* is needed to handle the case that CLEANFILES -# or CLEANDIRFILES is not completely empty but contains spaces. -# This can easily happen when CLEANFILES or CLEANDIRFILES is set -# from other variables that happen to be empty.) -# -# The use of :Q is needed to handle the case that CLEANFILES -# or CLEANDIRFILES contains quoted strings, such as -# CLEANFILES = "filename with spaces". -# -__cleanuse: .USE -.if 0 # print "# clean CLEANFILES" for debugging - ${"${.ALLSRC:@v@${${v}:M*}@:Q}" == "":?@true:${_MKMSG} \ - "clean" ${.ALLSRC} } -.endif -.for _d in ${"${.OBJDIR}" == "${.CURDIR}" || "${MKCLEANSRC}" == "no" \ - :? ${.OBJDIR} \ - : ${.OBJDIR} ${.CURDIR} } - ${"${.ALLSRC:@v@${${v}:M*}@:Q}" == "":?@true: \ - (cd ${_d} && rm -f ${.ALLSRC:@v@${${v}}@} || true) } -.if "${MKCLEANVERIFY}" == "yes" - @${"${.ALLSRC:@v@${${v}:M*}@:Q}" == "":?true: \ - bad="\$(cd ${_d} && ls -1d ${.ALLSRC:@v@${${v}}@} 2>/dev/null)"; \ - if test -n "\$bad"; then \ - echo "Failed to remove the following files from ${_d}:" ; \ - echo "\$bad" | while read file ; do \ - echo " \$file" ; \ - done ; \ - false ; \ - fi } -.endif -.endfor - -# Don't automatically load ".depend" files during "make clean" -# or "make cleandir". -.if make(clean) || make(cleandir) -.MAKE.DEPENDFILE := .depend.no-such-file -.endif - -.endif # !defined(_BSD_CLEAN_MK) diff --git a/src/share/mk/ubix.buildinstall.mk b/src/share/mk/ubix.buildinstall.mk new file mode 100644 index 0000000..87c65b3 --- /dev/null +++ b/src/share/mk/ubix.buildinstall.mk @@ -0,0 +1,29 @@ +# $NetBSD: bsd.buildinstall.mk,v 1.1 2012/11/15 23:51:53 joerg Exp $ + +# +# build_install logic for src/Makefile +# Used by src/lib/Makefile and src/tools/Makefile. +# +# Compute a list of subdirectories delimited by .WAIT. +# Run "make dependall && make install" for all subdirectories in a group +# concurrently, but wait after each group. +# +SUBDIR_GROUPS= 1 +CUR_GROUP:= 1 +.for dir in ${SUBDIR} +. if ${dir} == ".WAIT" +CUR_GROUP:= ${CUR_GROUP}1 +SUBDIR_GROUPS:= ${SUBDIR_GROUPS} ${CUR_GROUP} +. else +SUBDIR_GROUP.${CUR_GROUP}+= ${dir} +.endif + +.endfor + +build_install: +.for group in ${SUBDIR_GROUPS} +. if !empty(SUBDIR_GROUP.${group}) + ${MAKEDIRTARGET} . ${SUBDIR_GROUP.${group}:C/^/dependall-/} + ${MAKEDIRTARGET} . ${SUBDIR_GROUP.${group}:C/^/install-/} +. endif +.endfor diff --git a/src/share/mk/ubix.clang-analyze.mk b/src/share/mk/ubix.clang-analyze.mk new file mode 100644 index 0000000..81912be --- /dev/null +++ b/src/share/mk/ubix.clang-analyze.mk @@ -0,0 +1,40 @@ +# $NetBSD: bsd.clang-analyze.mk,v 1.3 2012/04/04 10:37:18 joerg Exp $ + +.ifndef CLANG_ANALYZE_SRCS + +CLANG_ANALYZE_FLAGS+= --analyze + +CLANG_ANALYZE_CHECKERS+= core deadcode security unix + +.for checker in ${CLANG_ANALYZE_CHECKERS} +CLANG_ANALYZE_FLAGS+= -Xanalyzer -analyzer-checker=${checker} +.endfor + +.SUFFIXES: .c .cc .cpp .cxx .C .clang-analyzer + +CLANG_ANALYZE_CFLAGS= ${CFLAGS:N-Wa,--fatal-warnings} +CLANG_ANALYZE_CXXFLAGS= ${CXXFLAGS:N-Wa,--fatal-warnings} + +.c.clang-analyzer: + ${TOOL_CC.clang} ${CLANG_ANALYZE_FLAGS} \ + ${CLANG_ANALYZE_CFLAGS} ${CPPFLAGS} \ + ${COPTS.${.IMPSRC:T}} ${CPUFLAGS.${.IMPSRC:T}} \ + ${CPPFLAGS.${.IMPSRC:T}} ${.IMPSRC} +.cc.clang-analyzer .cpp.clang-analyzer .cxx.clang-analyzer .C.clang-analyzer: + ${TOOL_CXX.clang} ${CLANG_ANALYZE_FLAGS} \ + ${CLANG_ANALYZE_CXXFLAGS} ${CPPFLAGS} \ + ${COPTS.${.IMPSRC:T}} ${CPUFLAGS.${.IMPSRC:T}} \ + ${CPPFLAGS.${.IMPSRC:T}} ${.IMPSRC} + +CLANG_ANALYZE_SRCS= \ + ${SRCS:M*.[cC]} ${SRCS:M*.cc} \ + ${SRCS:M*.cpp} ${SRCS:M*.cxx} \ + ${DPSRCS:M*.[cC]} ${DPSRCS:M*.cc} \ + ${DPSRCS:M*.cpp} ${DPSRCS:M*.cxx} +.if !empty(CLANG_ANALYZE_SRCS) +CLANG_ANALYZE_OUTPUT= ${CLANG_ANALYZE_SRCS:R:S,$,.clang-analyzer,} +.endif + +analyze: ${CLANG_ANALYZE_OUTPUT} + +.endif diff --git a/src/share/mk/ubix.clean.mk b/src/share/mk/ubix.clean.mk new file mode 100644 index 0000000..61b34b6 --- /dev/null +++ b/src/share/mk/ubix.clean.mk @@ -0,0 +1,91 @@ +# $NetBSD: bsd.clean.mk,v 1.8 2012/11/19 16:04:54 apb Exp $ + +# +# +# Public targets: +# +# clean: Delete files listed in ${CLEANFILES}. +# cleandir: Delete files listed in ${CLEANFILES} and ${CLEANDIRFILES}. +# +# Public variables: +# +# CLEANFILES Files to remove for both the clean and cleandir targets. +# +# CLEANDIRFILES Files to remove for the cleandir target, but not for +# the clean target. +# +# MKCLEANSRC Whether or not to clean the source directory +# in addition to the object directory. Defaults to "yes". +# +# MKCLEANVERIFY Whether or not to verify that the file deletion worked. +# Defaults to "yes". +# +# The files listed in CLEANFILES and CLEANDIRFILES must not be +# directories, because the potential risk from running "rm -rf" commands +# in bsd.clean.mk is considered too great. If you want to recursively +# delete a directory as part of "make clean" or "make cleandir" then you +# need to provide your own target. + +.if !defined(_BSD_CLEAN_MK_) +_BSD_CLEAN_MK_=1 + +.include + +MKCLEANSRC?= yes +MKCLEANVERIFY?= yes + +clean: .PHONY __doclean +__doclean: .PHONY .MADE __cleanuse CLEANFILES +cleandir: .PHONY clean __docleandir +__docleandir: .PHONY .MADE __cleanuse CLEANDIRFILES + +# __cleanuse is invoked with ${.ALLSRC} as the name of a variable +# (such as CLEANFILES or CLEANDIRFILES), or possibly a list of +# variable names. ${.ALLSRC:@v@${${v}}@} will be the list of +# files to delete. (We pass the variable name, e.g. CLEANFILES, +# instead of the file names, e.g. ${CLEANFILES}, because we don't +# want make to replace any of the file names with the result of +# searching .PATH.) +# +# If the list of files is empty, then the commands +# reduce to "true", with an "@" prefix to prevent echoing. +# +# The use of :M* is needed to handle the case that CLEANFILES +# or CLEANDIRFILES is not completely empty but contains spaces. +# This can easily happen when CLEANFILES or CLEANDIRFILES is set +# from other variables that happen to be empty.) +# +# The use of :Q is needed to handle the case that CLEANFILES +# or CLEANDIRFILES contains quoted strings, such as +# CLEANFILES = "filename with spaces". +# +__cleanuse: .USE +.if 0 # print "# clean CLEANFILES" for debugging + ${"${.ALLSRC:@v@${${v}:M*}@:Q}" == "":?@true:${_MKMSG} \ + "clean" ${.ALLSRC} } +.endif +.for _d in ${"${.OBJDIR}" == "${.CURDIR}" || "${MKCLEANSRC}" == "no" \ + :? ${.OBJDIR} \ + : ${.OBJDIR} ${.CURDIR} } + ${"${.ALLSRC:@v@${${v}:M*}@:Q}" == "":?@true: \ + (cd ${_d} && rm -f ${.ALLSRC:@v@${${v}}@} || true) } +.if "${MKCLEANVERIFY}" == "yes" + @${"${.ALLSRC:@v@${${v}:M*}@:Q}" == "":?true: \ + bad="\$(cd ${_d} && ls -1d ${.ALLSRC:@v@${${v}}@} 2>/dev/null)"; \ + if test -n "\$bad"; then \ + echo "Failed to remove the following files from ${_d}:" ; \ + echo "\$bad" | while read file ; do \ + echo " \$file" ; \ + done ; \ + false ; \ + fi } +.endif +.endfor + +# Don't automatically load ".depend" files during "make clean" +# or "make cleandir". +.if make(clean) || make(cleandir) +.MAKE.DEPENDFILE := .depend.no-such-file +.endif + +.endif # !defined(_BSD_CLEAN_MK)