I created the attached patch, which fixes the basic issue.

Note that I sent the fix uptream to Amaury Darsch and he said he'd
incorporate it.

Unfortunately, that patch is not enough to make it build in Debian.
Various patches under debian/patches/ modify the gcc-4 define file and
that has to be applied to the new gcc-5 file, too.  I didn't have the
energy to look into that...

-- 
Martin Michlmayr
Linux for HP Helion OpenStack, Hewlett-Packard
--- afnix-2.2.0~/cnf/bin/afnix-vcomp	2015-06-24 18:07:27.704828795 +0000
+++ afnix-2.2.0/cnf/bin/afnix-vcomp	2015-06-24 18:07:59.068829444 +0000
@@ -69,6 +69,7 @@
 	2.*) ccvers=2 ;;
 	3.*) ccvers=3 ;;
 	4.*) ccvers=4 ;;
+	5.*) ccvers=5 ;;
 	esac
     fi
     # check for g++
@@ -79,6 +80,7 @@
 	2.*) ccvers=2 ;;
 	3.*) ccvers=3 ;;
 	4.*) ccvers=4 ;;
+	5.*) ccvers=5 ;;
 	esac
     fi
 }
--- /dev/null	2015-01-14 06:03:17.000000000 +0000
+++ afnix-2.2.0/cnf/mak/afnix-gcc-5.mak	2015-06-24 18:28:08.364854471 +0000
@@ -0,0 +1,209 @@
+# ----------------------------------------------------------------------------
+# - afnix-gcc5                                                               -
+# - afnix compiler configuration - gcc configuration                         -
+# ----------------------------------------------------------------------------
+# - This program is  free software;  you can  redistribute it and/or  modify -
+# - it provided that this copyright notice is kept intact.                   -
+# -                                                                          -
+# - This  program  is  distributed in the hope  that it  will be useful, but -
+# - without  any   warranty;  without  even   the   implied    warranty   of -
+# - merchantability  or fitness for a particular purpose. In not event shall -
+# - the copyright holder be  liable for  any direct, indirect, incidental or -
+# - special damages arising in any way out of the use of this software.      -
+# ----------------------------------------------------------------------------
+# - author (c) 1999-2015 amaury   darsch                                     -
+# - author (c) 2011-2013 pino     toscano                      hurd platform -
+# ---------------------------------------------------------------------------
+
+# ----------------------------------------------------------------------------
+# - compiler and linker section                                              -
+# ----------------------------------------------------------------------------
+
+CC              = g++
+LD              = g++
+LK		= g++
+AR              = ar
+RANLIB		= ranlib
+STDEVFLAGS      =
+STDCCFLAGS      = -Wall -Werror -fno-builtin
+STACCFLAGS	=
+DYNCCFLAGS	= -fPIC
+PLTCCFLAGS      = 
+DEBUGFLAGS      = -g
+OPTCCFLAGS      = -O2
+PFLCCFLAGS      = -g -pg
+COVCCFLAGS      = -g -fprofile-arcs -ftest-coverage
+CPPCCFLAGS      = -nostdinc -nostdinc++
+CXXCCFLAGS      = 
+STDDEFINES      =
+DBGDEFINES      = -DAFNIX_DEBUG
+OPTDEFINES      =
+PFLDEFINES	= -DAFNIX_DEBUG -DAFNIX_PROFILED
+STDINCLUDE      =
+AFXCPPTYPE	= GNU
+AFXCPPVERS	= 5
+
+# ----------------------------------------------------------------------------
+# - compiler dependant libraries                                             -
+# ----------------------------------------------------------------------------
+
+# adjust for linux platform
+ifeq ($(PLATNAME),linux)
+PLTCCFLAGS      = -MMD -pthread
+ifeq ($(OPENMP),yes)
+PLTCCFLAGS     += -fopenmp
+endif
+endif
+
+# adjust for solaris platform
+ifeq ($(PLATNAME),solaris)
+PLTDEFINES	= -MMD -D_REENTRANT
+endif
+
+# adjust for freebsd platform
+ifeq ($(PLATNAME),freebsd)
+PLTDEFINES	= -MMD -D_REENTRANT
+endif
+
+# adjust for gnu/freebsd platform
+ifeq ($(PLATNAME),gnukbsd)
+PLTDEFINES	= -MMD -D_REENTRANT
+ifeq ($(OPENMP),yes)
+PLTCCFLAGS     += -fopenmp
+endif
+endif
+
+# adjust for gnu platform
+ifeq ($(PLATNAME),gnu)
+PLTDEFINES	= -MMD -D_REENTRANT
+ifeq ($(OPENMP),yes)
+PLTCCFLAGS     += -fopenmp
+endif
+endif
+
+# adjust for darwin platform
+ifeq ($(PLATNAME),darwin)
+PLTDEFINES	= -D_REENTRANT
+PLTSDKROOT	= $(SDKDIR)
+PLTSDKARCH	= -arch ppc -arch ppc64 -arch i686
+PLTCCFLAGS      = -isysroot ${PLTSDKROOT} $(PLTSDKARCH)
+PLTLDFLAGS	= $(PLTCCFLAGS)
+PLTLKFLAGS	= $(PLTCCFLAGS)
+PLTEVFLAGS	= MACOSX_DEPLOYMENT_TARGET=10.5
+endif
+
+# ----------------------------------------------------------------------------
+# - platform dependant linking flags                                         -
+# ----------------------------------------------------------------------------
+
+# adjust for linux platform
+ifeq ($(PLATNAME),linux)
+ARFLAGS		= rc
+LDFLAGS		= -shared -pthread
+ifeq ($(LKMODE),soname)
+LDFLAGS	       += -Wl,-soname,$(SOMAJ)
+endif
+ifeq ($(OPENMP),yes)
+LDFLAGS        += -fopenmp
+endif
+AFXCPPLIBS	=
+endif
+
+# adjust for solaris platform
+ifeq ($(PLATNAME),solaris)
+ARFLAGS		= rc
+LDFLAGS		= -shared
+ifeq ($(LKMODE),soname)
+LDFLAGS	       += -Wl,-h,$(SOMAJ)
+endif
+AFXCPPLIBS	=
+endif
+
+# adjust for freebsd platform
+ifeq ($(PLATNAME),freebsd)
+ARFLAGS		= rc
+LDFLAGS		= -shared
+ifeq ($(LKMODE),soname)
+LDFLAGS	       += -Wl,-soname,$(SOMAJ)
+endif
+AFXCPPLIBS	=
+endif
+
+# adjust for gnu/freebsd platform
+ifeq ($(PLATNAME),gnukbsd)
+ARFLAGS		= rc
+LDFLAGS		= -shared
+ifeq ($(LKMODE),soname)
+LDFLAGS	       += -Wl,-soname,$(SOMAJ)
+endif
+AFXCPPLIBS	=
+endif
+
+# adjust for gnu platform
+ifeq ($(PLATNAME),gnu)
+ARFLAGS		= rc
+LDFLAGS		= -shared
+ifeq ($(LKMODE),soname)
+LDFLAGS	       += -Wl,-soname,$(SOMAJ)
+endif
+AFXCPPLIBS	=
+endif
+
+# adjust for darwin platform
+ifeq ($(PLATNAME),darwin)
+ARFLAGS		= -rc
+LDFLAGS		= -dynamiclib $(PLTLDFLAGS)
+ifeq ($(LKMODE),dylib)
+LDFLAGS	       += -compatibility_version $(MAJOR).$(MINOR)
+LDFLAGS        += -current_version $(MAJOR).$(MINOR).$(PATCH)
+else
+$(error, "undefined darwin linking mode")
+endif
+AFXCPPLIBS	=
+endif
+
+# ----------------------------------------------------------------------------
+# - platform dependant final executable flags                                -
+# ----------------------------------------------------------------------------
+
+LKFLAGS		=
+
+# adjust linker flags for linux
+ifeq ($(PLATNAME),linux)
+LKFLAGS      	= -pthread
+endif
+
+# adjust linker flags for freebsd
+ifeq ($(PLATNAME),freebsd)
+LKFLAGS      	= -pthread
+endif
+
+# adjust linker flags for darwin
+ifeq ($(PLATNAME),darwin)
+LKFLAGS      	= $(PLTLKFLAGS)
+endif
+
+# ----------------------------------------------------------------------------
+# - target dependant final executable flags                                  -
+# ----------------------------------------------------------------------------
+
+# adjust extra flag for profiled code
+ifeq ($(CCMODE),profiled)
+LKFLAGS	       += -pg
+endif
+
+# adjust platform flag for static or dynamic
+ifeq ($(LKTYPE),dynamic)
+PLTCCFLAGS     += $(DYNCCFLAGS)
+endif
+ifeq ($(LKTYPE),static)
+PLTCCFLAGS     += $(STACCFLAGS)
+endif
+
+# adjust intel processor
+ifeq ($(PROCNAME)-$(PROCTYPE),ia32-586)
+OPTCCFLAGS     += -march=i586
+endif
+ifeq ($(PROCNAME)-$(PROCTYPE),ia32-686)
+OPTCCFLAGS     += -march=i686
+endif

Reply via email to