Commit b5cdc5d2 authored by Lev Walkin's avatar Lev Walkin

add C++ compile check

parent 5c600f4c
......@@ -46,7 +46,7 @@ typedef struct asn_struct_ctx_s {
#ifdef ASN_DISABLE_OER_SUPPORT
typedef void (oer_type_decoder_f)();
typedef void (oer_type_encoder_f)();
typedef struct{} asn_oer_constraints_t;
typedef void asn_oer_constraints_t;
#else
#include <oer_decoder.h> /* Octet Encoding Rules encoder */
#include <oer_encoder.h> /* Octet Encoding Rules encoder */
......
......@@ -10,6 +10,7 @@ CFLAGS = $(filter-out $(CODE_COVERAGE_CFLAGS), @CFLAGS@)
TESTS_ENVIRONMENT= \
CC="${CC}" \
CXX="${CXX}" \
CFLAGS="${TESTSUITE_CFLAGS} ${CFLAGS}" \
CXXFLAGS="${CXXFLAGS}" \
LDFLAGS="${LDFLAGS}" \
......@@ -42,6 +43,7 @@ TESTS += check-src/check-39.c
TESTS += check-src/check-41.-fwide-types.c
TESTS += check-src/check-41.c
TESTS += check-src/check-42.c
TESTS += check-src/check-42.-fwide-types.cc
TESTS += check-src/check-43.c
TESTS += check-src/check-44.c
TESTS += check-src/check-46.c
......
......@@ -38,7 +38,7 @@ if [ ! "$has_per" ]; then
CODECS_FLAGS="${CODECS_FLAGS} -DASN_DISABLE_PER_SUPPORT"
fi
args=$(echo "$source_short" | sed -e 's/\.c[c]*$//')
args=$(echo "$source_short" | sed -E -e 's/\.c+$//')
OFS=$IFS
IFS="."
......@@ -68,10 +68,11 @@ ${AUTOGENERATED}
COMMON_FLAGS= -I.
CFLAGS = \${COMMON_FLAGS} ${CFLAGS:-} -g -O1
CFLAGS += -DSRCDIR=../${srcdir} ${CODECS_FLAGS}
CXXFLAGS = \${COMMON_FLAGS} ${CXXFLAGS}
CXXFLAGS = \${CFLAGS} ${CXXFLAGS}
LDFLAGS = ${LDFLAGS:-}
CC ?= ${CC}
CXX ?= ${CXX}
all: compiled-module
\$(MAKE) check-executable
......@@ -109,14 +110,16 @@ produce_specific_makefile() {
if [ ${make_type} = "BSD" ]; then
cat <<-OBJECTS > ${make_file}
${AUTOGENERATED}
SRCS!=find . -name \*.c
OBJS=\${SRCS:.c=.o}
SRCS_C!=find . -name \*.c
SRCS_CXX!=find . -name \*.cc
OBJS=\${SRCS_C:.c=.o} ${SRCS_CXX:.cc=.o}
.sinclude <Makefile.targets>
OBJECTS
else
cat <<-OBJECTS > ${make_file}
${AUTOGENERATED}
OBJS=\$(patsubst %.c,%.o,\$(wildcard *.c))
OBJS =\$(patsubst %.c,%.o,\$(wildcard *.c))
OBJS+=\$(patsubst %.cc,%.o,\$(wildcard *.cc))
-include Makefile.targets
OBJECTS
fi
......
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