diff options
author | Alexander Leidinger <netchild@FreeBSD.org> | 2003-12-22 15:28:18 +0000 |
---|---|---|
committer | Alexander Leidinger <netchild@FreeBSD.org> | 2003-12-22 15:28:18 +0000 |
commit | 0af58e872570afe3007395d19419fc422f6cd94f (patch) | |
tree | bdc337bac0d350da7a8785893c05738c472bdf22 /devel/stlport | |
parent | ecaff98d5a28070162a378ac663e802d23740fdb (diff) | |
download | ports-0af58e872570afe3007395d19419fc422f6cd94f.tar.gz ports-0af58e872570afe3007395d19419fc422f6cd94f.zip |
Notes
Diffstat (limited to 'devel/stlport')
-rw-r--r-- | devel/stlport/Makefile | 20 | ||||
-rw-r--r-- | devel/stlport/files/patch-src::gcc-freebsd.mak | 12 | ||||
-rw-r--r-- | devel/stlport/files/patch-test::eh::gcc-freebsd.mak | 6 | ||||
-rw-r--r-- | devel/stlport/files/src::icc-freebsd.mak | 20 | ||||
-rw-r--r-- | devel/stlport/files/stlport::stl_icc.h | 42 | ||||
-rw-r--r-- | devel/stlport/files/test::eh::icc-freebsd.mak | 14 |
6 files changed, 76 insertions, 38 deletions
diff --git a/devel/stlport/Makefile b/devel/stlport/Makefile index 5dd7c2f5c875..ae8bfcfb0075 100644 --- a/devel/stlport/Makefile +++ b/devel/stlport/Makefile @@ -8,7 +8,7 @@ PORTNAME= stlport PORTVERSION= 4.5.3 -PORTREVISION= 1 +PORTREVISION?= 1 CATEGORIES= devel MASTER_SITES= http://www.stlport.com/archive/ PKGNAMESUFFIX= -${COMPILER} @@ -28,9 +28,10 @@ PATCH_WRKSRC= ${WRKDIR}/STLport-${PORTVERSION:S/.b/b/} USE_GMAKE= yes COMPILER?= gcc MAKEFILE= ${COMPILER}-freebsd.mak +MAKE_ENV+= CC=${CC} CXX=${CXX} MAKE_ARGS+= INSTALLDIR=${PREFIX} PTHREAD_CFLAGS=${PTHREAD_CFLAGS} \ PTHREAD_LIBS=${PTHREAD_LIBS} -PLIST_SUB= COMPILER=${COMPILER} +PLIST_SUB+= COMPILER=${COMPILER} INSTALL_TARGET= install_unix INSTALLS_SHLIB= yes @@ -40,8 +41,13 @@ BROKEN= "Not supported on systems prior to FreeBSD 4.4" .endif .if ${COMPILER} == icc -CC= icc -CXX= icpc +CC= icc +CXX= icpc +CFLAGS= -O -ip -axiMKW +CXXFLAGS= ${CFLAGS} +.else +CFLAGS= +CXXFLAGS= .endif .if ${COMPILER} == gcc && ${OSVERSION} < 460000 @@ -73,9 +79,7 @@ post-build: test .endif test: do-build - cd ${WRKSRC}/../test/eh && ${SETENV} CC=${CC} CXX=${CXX} \ - ${GMAKE} -f ${MAKEFILE} PTHREAD_CFLAGS=${PTHREAD_CFLAGS} \ - PTHREAD_LIBS=${PTHREAD_LIBS} PTHREAD_CFLAGS=${PTHREAD_CFLAGS} \ - PTHREAD_LIBS=${PTHREAD_LIBS} CC=${CC} CXX=${CXX} + @cd ${WRKSRC}/../test/eh && ${SETENV} ${MAKE_ENV} \ + ${GMAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} check_d .include <bsd.port.post.mk> diff --git a/devel/stlport/files/patch-src::gcc-freebsd.mak b/devel/stlport/files/patch-src::gcc-freebsd.mak index faf6f4d0be3e..d55cc5682a96 100644 --- a/devel/stlport/files/patch-src::gcc-freebsd.mak +++ b/devel/stlport/files/patch-src::gcc-freebsd.mak @@ -6,8 +6,8 @@ # -CC = gcc -pthread -CXX = c++ -pthread -fexceptions -+CC+= ${PTHREAD_CFLAGS} -D_REENTRANT -+CXX+= ${PTHREAD_CFLAGS} -D_REENTRANT -fexceptions ++CC+= $(PTHREAD_CFLAGS) -D_REENTRANT ++CXX+= $(PTHREAD_CFLAGS) -D_REENTRANT -fexceptions # # Basename for libraries @@ -16,18 +16,18 @@ LINK=ar cr # 2.95 flag -DYN_LINK=c++ -pthread -fexceptions -shared -o -+DYN_LINK=$(CXX) ${PTHREAD_LIBS} -shared -o ++DYN_LINK=$(CXX) $(PTHREAD_LIBS) -shared -o OBJEXT=o DYNEXT=so @@ -41,8 +41,8 @@ - CXXFLAGS_COMMON = -I${STLPORT_DIR} ${WARNING_FLAGS} + CXXFLAGS_COMMON = -I$(STLPORT_DIR) $(WARNING_FLAGS) -CXXFLAGS_RELEASE_static = $(CXXFLAGS_COMMON) -O2 -CXXFLAGS_RELEASE_dynamic = $(CXXFLAGS_COMMON) -O2 -fPIC -+CXXFLAGS_RELEASE_static = $(CXXFLAGS_COMMON) ${CXXFLAGS} -+CXXFLAGS_RELEASE_dynamic = $(CXXFLAGS_COMMON) ${CXXFLAGS} -fPIC ++CXXFLAGS_RELEASE_static = $(CXXFLAGS_COMMON) $(CXXFLAGS) ++CXXFLAGS_RELEASE_dynamic = $(CXXFLAGS_COMMON) $(CXXFLAGS) -fPIC CXXFLAGS_DEBUG_static = $(CXXFLAGS_COMMON) -O -g CXXFLAGS_DEBUG_dynamic = $(CXXFLAGS_COMMON) -O -g -fPIC diff --git a/devel/stlport/files/patch-test::eh::gcc-freebsd.mak b/devel/stlport/files/patch-test::eh::gcc-freebsd.mak index 9672b4131b60..ca089998af55 100644 --- a/devel/stlport/files/patch-test::eh::gcc-freebsd.mak +++ b/devel/stlport/files/patch-test::eh::gcc-freebsd.mak @@ -11,12 +11,12 @@ # also, test_slist won't compile with -O3/-O2 when targeting PPC. It fails # in the assembler with 'invalid relocation type' -CXXFLAGS = -Wall -g -O ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -DEH_VECTOR_OPERATOR_NEW -+CXXFLAGS= $(PTHREAD_CFLAGS) -D_REENTRANT -Wall -g -O ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -DEH_VECTOR_OPERATOR_NEW -DEH_DELETE_HAS_THROW_SPEC ++CXXFLAGS += $(PTHREAD_CFLAGS) -D_REENTRANT -fexceptions -Wall $(STL_INCL) -I. $(CXX_EXTRA_FLAGS) -DEH_VECTOR_OPERATOR_NEW -DEH_DELETE_HAS_THROW_SPEC -D_CXXFLAGS = -Wall -g -O ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -DEH_VECTOR_OPERATOR_NEW -D_STLP_DEBUG -D_STLP_USE_STATIC_LIB -NOSGI_CXXFLAGS = -Wall -g -O2 ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -D_STLP_NO_OWN_IOSTREAMS -D_STLP_DEBUG_UNINITIALIZED -DEH_VECTOR_OPERATOR_NEW -+D_CXXFLAGS = $(PTHREAD_CFLAGS) -D_REENTRANT -Wall -g -O ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -DEH_VECTOR_OPERATOR_NEW -DEH_DELETE_HAS_THROW_SPEC -D_STLP_DEBUG -D_STLP_USE_STATIC_LIB -+NOSGI_CXXFLAGS = $(PTHREAD_CFLAGS) -D_REENTRANT -Wall -g -O2 ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -D_STLP_NO_OWN_IOSTREAMS -D_STLP_DEBUG_UNINITIALIZED -DEH_VECTOR_OPERATOR_NEW -DEH_DELETE_HAS_THROW_SPEC ++D_CXXFLAGS = $(CXXFLAGS) -g -D_STLP_DEBUG ++NOSGI_CXXFLAGS = $(CXXFLAGS) -D_STLP_NO_OWN_IOSTREAMS -D_STLP_DEBUG_UNINITIALIZED check: $(TEST) diff --git a/devel/stlport/files/src::icc-freebsd.mak b/devel/stlport/files/src::icc-freebsd.mak index 619af0e3ee03..6300ce325340 100644 --- a/devel/stlport/files/src::icc-freebsd.mak +++ b/devel/stlport/files/src::icc-freebsd.mak @@ -1,12 +1,14 @@ # -# Note : this makefile is for Intel(R) C++ Compiler Version 6.0 ! +# Note : This makefile is for Intel(R) C++ Compiler # # # compiler # -CC= icc -CXX= icpc +#CC= icc +#CXX= icpc +#CFLAGS= -O -ip -axiMKW +#CXXFLAGS= -O -ip -axiMKW # # Basename for libraries @@ -18,7 +20,9 @@ LIB_BASENAME = libstlport_icc # # LINK=ar cr -DYN_LINK=$(CXX) -Qoption,ld,-BOOTSTRAPSTLPORT -mt -shared -o +# Using icc here is a hack while icpc on FreeBSD is set up to automatically +# link against libstlport_icc. +DYN_LINK=$(CC) -mt -shared -o OBJEXT=o DYNEXT=so @@ -38,13 +42,13 @@ include common_macros.mak WARNING_FLAGS= -w1 -CXXFLAGS_COMMON = -I${STLPORT_DIR} ${WARNING_FLAGS} ${PTHREAD_CFLAGS} -D_REENTRANT -mt +CXXFLAGS_COMMON = -I$(STLPORT_DIR) $(WARNING_FLAGS) $(PTHREAD_CFLAGS) -D_REENTRANT -CXXFLAGS_RELEASE_static = $(CXXFLAGS_COMMON) -O -ip -axiMKW -CXXFLAGS_RELEASE_dynamic = $(CXXFLAGS_COMMON) -O -ip -axiMKW -KPIC +CXXFLAGS_RELEASE_static = $(CXXFLAGS_COMMON) $(CXXFLAGS) +CXXFLAGS_RELEASE_dynamic = $(CXXFLAGS_COMMON) $(CXXFLAGS) -KPIC CXXFLAGS_DEBUG_static = $(CXXFLAGS_COMMON) -O -g -CXXFLAGS_DEBUG_dynamic = $(CXXFLAGS_COMMON) -O -g -KPIC +CXXFLAGS_DEBUG_dynamic = $(CXXFLAGS_COMMON) -O -KPIC CXXFLAGS_STLDEBUG_static = $(CXXFLAGS_DEBUG_static) -D_STLP_DEBUG CXXFLAGS_STLDEBUG_dynamic = $(CXXFLAGS_DEBUG_dynamic) -D_STLP_DEBUG diff --git a/devel/stlport/files/stlport::stl_icc.h b/devel/stlport/files/stlport::stl_icc.h index 01d85c66a4ea..574af8a500f5 100644 --- a/devel/stlport/files/stlport::stl_icc.h +++ b/devel/stlport/files/stlport::stl_icc.h @@ -1,8 +1,38 @@ -/* - * STLport configuration file - * It is internal STLport header - DO NOT include it directly - */ +// STLport configuration file +// It is internal STLport header - DO NOT include it directly +// A list of Intel compiler for Linux portion of STLport settings. -#define _STLP_NO_CSTD_FUNCTION_IMPORTS +# define _STLP_LONG_LONG long long -#define _STLP_LONG_LONG long long +// Edit relative path below (or put full path) to get native +// compiler headers included. Default is "../include". +// C headers may reside in different directory, so separate macro is provided. +# if (__INTEL_COMPILER >= 800) + +# define _STLP_NATIVE_INCLUDE_PATH ../include/c++ +# define _STLP_NATIVE_C_INCLUDE_PATH ../include +//# define _STLP_NATIVE_CPP_C_INCLUDE_PATH ../include + +# ifndef __GNUC__ +// If GCC compatability is disabled (-no-gcc is specified) STD needs to be redefined. +# define _STLP_REDEFINE_STD 1 +# endif /* __GNUC__ */ + +//#define _STLP_HAS_NO_NEW_C_HEADERS 1 + +# endif /* __INTEL_COMPILER >= 800 */ + +#ifndef __FreeBSD__ // FreeBSD system headers use unsupported GCC extensions. +# ifndef __GNUC__ +# define __GNUC__ 3 +# endif +#endif + +# define _STLP_NO_NATIVE_WIDE_FUNCTIONS 1 + +#ifdef __FreeBSD__ +# include <osreldate.h> +# define _STLP_HAS_NATIVE_FLOAT_ABS +# define _STLP_NO_CSTD_FUNCTION_IMPORTS +# define _STLP_NO_LONG_DOUBLE +#endif diff --git a/devel/stlport/files/test::eh::icc-freebsd.mak b/devel/stlport/files/test::eh::icc-freebsd.mak index 9494baef0b30..49469197653d 100644 --- a/devel/stlport/files/test::eh::icc-freebsd.mak +++ b/devel/stlport/files/test::eh::icc-freebsd.mak @@ -16,7 +16,7 @@ test_deque.cpp test_set.cpp test_map.cpp \ test_hash_map.cpp test_hash_set.cpp test_rope.cpp \ test_string.cpp test_bitset.cpp test_valarray.cpp -LIST=${AUX_LIST} ${TEST_LIST} +LIST=$(AUX_LIST) $(TEST_LIST) OBJECTS = $(LIST:%.cpp=obj/%.o) $(STAT_MODULE) D_OBJECTS = $(LIST:%.cpp=d_obj/%.o) $(STAT_MODULE) @@ -29,12 +29,12 @@ D_TEST_EXE = ./eh_test_d TEST = ./eh_test.out D_TEST = ./eh_test_d.out -CXXFLAGS= $(PTHREAD_CFLAGS) -D_REENTRANT -mt -w1 -g -O ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -DEH_VECTOR_OPERATOR_NEW -DEH_DELETE_HAS_THROW_SPEC -D_CXXFLAGS = $(PTHREAD_CFLAGS) -D_REENTRANT -mt -w1 -g -O ${STL_INCL} -I. ${CXX_EXTRA_FLAGS} -DEH_VECTOR_OPERATOR_NEW -DEH_DELETE_HAS_THROW_SPEC -D_STLP_DEBUG -D_STLP_USE_STATIC_LIB +CXXFLAGS += $(PTHREAD_CFLAGS) -D_REENTRANT -w1 $(STL_INCL) -I. $(CXX_EXTRA_FLAGS) -DEH_VECTOR_OPERATOR_NEW -DEH_DELETE_HAS_THROW_SPEC +D_CXXFLAGS = $(CXXFLAGS) -g -D_STLP_DEBUG check: $(TEST) -LIBS = -lm +LIBS = -lm -mt D_LIBSTLPORT = -L../../lib -lstlport_icc_stldebug LIBSTLPORT = -L../../lib -lstlport_icc @@ -52,10 +52,10 @@ $(D_OBJDIR): $(TEST_EXE) : $(OBJDIR) $(OBJECTS) - $(CXX) $(CXXFLAGS) $(OBJECTS) $(LIBSTLPORT) $(LIBS) -o $(TEST_EXE) + $(CC) $(CXXFLAGS) $(OBJECTS) $(LIBSTLPORT) $(LIBS) -o $(TEST_EXE) $(D_TEST_EXE) : $(D_OBJDIR) $(D_OBJECTS) - $(CXX) $(D_CXXFLAGS) $(D_OBJECTS) $(D_LIBSTLPORT) $(LIBS) -o $(D_TEST_EXE) + $(CC) $(D_CXXFLAGS) $(D_OBJECTS) $(D_LIBSTLPORT) $(LIBS) -o $(D_TEST_EXE) $(TEST) : $(TEST_EXE) @@ -73,4 +73,4 @@ obj/%.o : %.cpp $(CXX) $(CXXFLAGS) $< -c -o $@ clean: - rm -rf ${TEST_EXE} *.o */*.o *.core + -rm -rf $(TEST_EXE) *.o */*.o *.core |