61 |
haskell_disable_feature() |
haskell_disable_feature() |
62 |
{ |
{ |
63 |
local feature="$1" |
local feature="$1" |
64 |
haskell_feature_is_supported || die "haskell feature '${feature}' not supported!" |
haskell_feature_is_supported "${feature}" || die "haskell feature '${feature}' not supported!" |
65 |
|
echo -e "${COLBLUE}--- ${COLRED}disabled haskell feature '${feature}'${COLDEFAULT}" |
66 |
export HASKELL_FEATURES="${HASKELL_FEATURES/${feature}/}" |
export HASKELL_FEATURES="${HASKELL_FEATURES/${feature}/}" |
67 |
} |
} |
68 |
|
|
69 |
haskell_enable_feature() |
haskell_enable_feature() |
70 |
{ |
{ |
71 |
local feature="$1" |
local feature="$1" |
72 |
haskell_feature_is_supported || die "haskell feature '${feature}' not supported!" |
haskell_feature_is_supported "${feature}" || die "haskell feature '${feature}' not supported!" |
73 |
|
echo -e "${COLBLUE}+++ ${COLGREEN}enabled haskell feature '${feature}'${COLDEFAULT}" |
74 |
export HASKELL_FEATURES+=" ${feature}" |
export HASKELL_FEATURES+=" ${feature}" |
75 |
} |
} |
76 |
|
|
130 |
|| die |
|| die |
131 |
} |
} |
132 |
|
|
133 |
|
haskell_src_build() |
134 |
|
{ |
135 |
|
runhaskell $(haskell_ghc_setup_script) build || die |
136 |
|
} |
137 |
|
|
138 |
haskell_src_compile() |
haskell_src_compile() |
139 |
{ |
{ |
140 |
cd ${SRCDIR} |
cd ${SRCDIR} |
141 |
haskell_src_configure || die |
haskell_src_configure || die |
142 |
runhaskell $(haskell_ghc_setup_script) build || die |
haskell_src_build || die |
143 |
} |
} |
144 |
|
|
145 |
haskell_src_install() |
haskell_src_install() |
148 |
runhaskell $(haskell_ghc_setup_script) copy --destdir=${BINDIR} || die |
runhaskell $(haskell_ghc_setup_script) copy --destdir=${BINDIR} || die |
149 |
|
|
150 |
# create register scripts |
# create register scripts |
151 |
haskell_feature register && haskell_install_register || die |
if haskell_feature register |
152 |
|
then |
153 |
|
haskell_install_register || die |
154 |
|
fi |
155 |
|
|
156 |
# install docs |
# install docs |
157 |
local i |
local i |