2a59fa65f70034341c7f0f475992cd4fcccf0d72
[dragonfly.git] / gnu / lib / gcc47 / libsupc++ / Makefile.src
1 SUPCXX= \
2         array_type_info.cc \
3         atexit_arm.cc \
4         bad_alloc.cc \
5         bad_cast.cc \
6         bad_typeid.cc \
7         class_type_info.cc \
8         del_op.cc \
9         del_opnt.cc \
10         del_opv.cc \
11         del_opvnt.cc \
12         dyncast.cc \
13         eh_alloc.cc \
14         eh_arm.cc \
15         eh_aux_runtime.cc \
16         eh_call.cc \
17         eh_catch.cc \
18         eh_exception.cc \
19         eh_globals.cc \
20         eh_personality.cc \
21         eh_ptr.cc \
22         eh_term_handler.cc \
23         eh_terminate.cc \
24         eh_tm.cc \
25         eh_throw.cc \
26         eh_type.cc \
27         eh_unex_handler.cc \
28         enum_type_info.cc \
29         function_type_info.cc \
30         fundamental_type_info.cc \
31         guard.cc \
32         guard_error.cc \
33         hash_bytes.cc \
34         nested_exception.cc \
35         new_handler.cc \
36         new_op.cc \
37         new_opnt.cc \
38         new_opv.cc \
39         new_opvnt.cc \
40         pbase_type_info.cc \
41         pmem_type_info.cc \
42         pointer_type_info.cc \
43         pure.cc \
44         si_class_type_info.cc \
45         tinfo.cc \
46         tinfo2.cc \
47         vec.cc \
48         vmi_class_type_info.cc \
49         vterminate.cc
50
51 bits/gthr.h: copybits ${GCCDIR}/libgcc/gthr.h
52         sed -e '/^#pragma/b' \
53         -e '/^#/s/\([ABCDEFGHIJKLMNOPQRSTUVWXYZ_][ABCDEFGHIJKLMNOPQRSTUVWXYZ_]*\)/_GLIBCXX_\1/g' \
54         -e 's/_GLIBCXX_SUPPORTS_WEAK/__GXX_WEAK__/g' \
55         -e 's,^#include "\(.*\)",#include <bits/\1>,g' \
56         < ${GCCDIR}/libgcc/gthr.h > ${.TARGET}
57
58 bits/gthr-default.h: copybits ${GCCDIR}/libgcc/gthr-posix.h
59         sed -e 's/\(UNUSED\)/_GLIBCXX_\1/g' \
60             -e 's/\(GCC[ABCDEFGHIJKLMNOPQRSTUVWXYZ_]*_H\)/_GLIBCXX_\1/g' \
61             -e 's/SUPPORTS_WEAK/__GXX_WEAK__/g' \
62             -e 's/\([ABCDEFGHIJKLMNOPQRSTUVWXYZ_]*USE_WEAK\)/_GLIBCXX_\1/g' \
63             < ${GCCDIR}/libgcc/gthr-posix.h > ${.TARGET}
64
65 CXX_CONFIG_H = ${.CURDIR}/../libstdc++/config.h
66 ns_version=0
67 visibility=1
68 externtemplate=1
69 SUBST1='s,define __GLIBCXX__,define __GLIBCXX__ ${GCCSHORTDATE},'
70 SUBST2='s,define _GLIBCXX_INLINE_VERSION, define _GLIBCXX_INLINE_VERSION ${ns_version},'
71 SUBST3='s,define _GLIBCXX_HAVE_ATTRIBUTE_VISIBILITY, define _GLIBCXX_HAVE_ATTRIBUTE_VISIBILITY ${visibility},'
72 SUBST4='s,define _GLIBCXX_EXTERN_TEMPLATE$$, define _GLIBCXX_EXTERN_TEMPLATE ${externtemplate},'
73
74 bits/c++config.h: copybits ${CXX_CONFIG_H}
75         sed -e ${SUBST1} -e ${SUBST2} -e ${SUBST3} -e ${SUBST4} \
76             < ${GCCDIR}/libstdc++-v3/include/bits/c++config > ${.TARGET}
77         sed -e 's/HAVE_/_GLIBCXX_HAVE_/g' \
78             -e 's/PACKAGE/_GLIBCXX_PACKAGE/g' \
79             -e 's/VERSION/_GLIBCXX_VERSION/g' \
80             -e 's/WORDS_/_GLIBCXX_WORDS_/g' \
81             -e 's/ICONV_CONST/_GLIBCXX_ICONV_CONST/g' \
82             -e '/[      ]_GLIBCXX_LONG_DOUBLE_COMPAT[   ]/d' \
83             < ${CXX_CONFIG_H} >> ${.TARGET}
84         echo "" >> ${.TARGET}
85         echo "#endif // _GLIBCXX_CXX_CONFIG_H" >> ${.TARGET}