Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
GHC
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Iterations
Merge Requests
0
Merge Requests
0
Requirements
Requirements
List
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Operations
Operations
Incidents
Environments
Packages & Registries
Packages & Registries
Package Registry
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issue
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
jberryman
GHC
Commits
81e5f8ff
Commit
81e5f8ff
authored
May 16, 2009
by
Ian Lynagh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bootstrapping fixes
parent
fc15f6e8
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
39 additions
and
9 deletions
+39
-9
Makefile
Makefile
+2
-2
ghc.mk
ghc.mk
+14
-3
ghc/ghc.mk
ghc/ghc.mk
+13
-3
rts/ghc.mk
rts/ghc.mk
+3
-0
rules/build-prog.mk
rules/build-prog.mk
+6
-0
rules/hs-suffix-rules-srcdir.mk
rules/hs-suffix-rules-srcdir.mk
+1
-1
No files found.
Makefile
View file @
81e5f8ff
...
...
@@ -48,7 +48,7 @@ $(PACKAGE_MK):
sh boot-pkgs
# No need to update makefiles for these targets:
REALGOALS
=
$(
filter-out
framework-pkg clean clean_% distclean maintainer-clean show,
$(MAKECMDGOALS)
)
REALGOALS
=
$(
filter-out
bootstrapping-files
framework-pkg clean clean_% distclean maintainer-clean show,
$(MAKECMDGOALS)
)
# NB. not the same as saying '%: ...', which doesn't do the right thing:
# it does nothing if we specify a target that already exists.
...
...
@@ -77,7 +77,7 @@ clean distclean maintainer-clean:
$(filter clean_%, $(MAKECMDGOALS))
:
clean_% :
$(MAKE)
-r
--no-print-directory
-f
ghc.mk
$@
show
:
$(PACKAGE_MK)
bootstrapping-files
show
:
$(PACKAGE_MK)
$(MAKE)
-r
--no-print-directory
-f
ghc.mk
$@
ifeq
"$(darwin_TARGET_OS)" "1"
...
...
ghc.mk
View file @
81e5f8ff
...
...
@@ -172,6 +172,10 @@ ifneq "$(findstring clean,$(MAKECMDGOALS))" ""
NO_INCLUDE_DEPS
=
YES
NO_INCLUDE_PKGDATA
=
YES
endif
ifneq
"$(findstring bootstrapping-files,$(MAKECMDGOALS))" ""
NO_INCLUDE_DEPS
=
YES
NO_INCLUDE_PKGDATA
=
YES
endif
ifeq
"$(findstring show,$(MAKECMDGOALS))" "show"
NO_INCLUDE_DEPS
=
YES
# We want package-data.mk for show
...
...
@@ -347,7 +351,8 @@ ifeq "$(BuildSharedLibs)" "YES"
OTHER_LIBS
+=
libffi/libHSffi
$(dyn_libsuf)
endif
ifeq
"$(HaveLibGmp)" "NO"
OTHER_LIBS
+=
gmp/libgmp.a
GMP_LIB
=
gmp/libgmp.a
OTHER_LIBS
+=
$(GMP_LIB)
endif
# We cannot run ghc-cabal to configure a package until we have
...
...
@@ -554,7 +559,7 @@ $(foreach pkg,$(PACKAGES) $(PACKAGES_STAGE2),$(eval libraries/$(pkg)_dist-instal
# XXX Hack; remove this
$(foreach
pkg,$(PACKAGES_STAGE2),$(eval
libraries/
$(pkg)_dist-install_HC_OPTS
+=
-Wwarn
))
# XXX we configure packages with the bootsrapping compiler (for
# XXX we configure packages with the boots
t
rapping compiler (for
# dependency reasons, see the phase ordering), which doesn't
# necessarily support all the extensions we need, and Cabal filters
# out the ones it thinks aren't supported.
...
...
@@ -865,7 +870,7 @@ publish-sdist :
endif
ifeq
"$(GhcUnregisterised)" "YES"
SRC_CC_OPTS
+=
-DNO_REGS
-DUSE_MINIINTERPRETER
SRC_CC_OPTS
+=
-DNO_REGS
-DUSE_MINIINTERPRETER
-D__GLASGOW_HASKELL__
=
$(ProjectVersionInt)
endif
# -----------------------------------------------------------------------------
...
...
@@ -918,3 +923,9 @@ maintainer-clean : distclean
.PHONY
:
all_libraries
.PHONY
:
bootstrapping-files
bootstrapping-files
:
$(GMP_LIB)
bootstrapping-files
:
includes/ghcautoconf.h
bootstrapping-files
:
includes/DerivedConstants.h
bootstrapping-files
:
includes/GHCConstants.h
ghc/ghc.mk
View file @
81e5f8ff
...
...
@@ -120,9 +120,15 @@ $(INPLACE_LIB)/extra-gcc-opts : extra-gcc-opts
$(CP)
$<
$@
# The GHC programs need to depend on all the helper programs they might call
$(GHC_STAGE1)
:
$(INPLACE_LIB)/extra-gcc-opts $(MANGLER) $(SPLIT)
$(GHC_STAGE2)
:
$(INPLACE_LIB)/extra-gcc-opts $(MANGLER) $(SPLIT)
$(GHC_STAGE3)
:
$(INPLACE_LIB)/extra-gcc-opts $(MANGLER) $(SPLIT)
ifeq
"$(GhcUnregisterised)" "NO"
$(GHC_STAGE1)
:
$(MANGLER) $(SPLIT)
$(GHC_STAGE2)
:
$(MANGLER) $(SPLIT)
$(GHC_STAGE3)
:
$(MANGLER) $(SPLIT)
endif
$(GHC_STAGE1)
:
$(INPLACE_LIB)/extra-gcc-opts
$(GHC_STAGE2)
:
$(INPLACE_LIB)/extra-gcc-opts
$(GHC_STAGE3)
:
$(INPLACE_LIB)/extra-gcc-opts
ifeq
"$(Windows)" "YES"
$(GHC_STAGE1)
:
$(TOUCHY) $(INPLACE)/stamp-mingw $(INPLACE_LIB)/perl.exe
...
...
@@ -130,6 +136,10 @@ $(GHC_STAGE2) : $(TOUCHY) $(INPLACE)/stamp-mingw $(INPLACE_LIB)/perl.exe
$(GHC_STAGE3)
:
$(TOUCHY) $(INPLACE)/stamp-mingw $(INPLACE_LIB)/perl.exe
endif
ifeq
"$(BootingFromHc)" "YES"
ghc_stage2_OTHER_OBJS
+=
$(compiler_stage2_v_LIB)
$(ALL_LIBS)
$(ALL_LIBS)
$(ALL_LIBS)
$(ALL_RTS_LIBS)
-lgmp
$(libffi_STATIC_LIB)
-lm
-lutil
-lrt
endif
endif
INSTALL_LIBS
+=
extra-gcc-opts
...
...
rts/ghc.mk
View file @
81e5f8ff
...
...
@@ -43,6 +43,8 @@ EXCLUDED_SRCS += $(wildcard rts/Vis*.c)
rts_C_SRCS
=
$(
filter-out
$(EXCLUDED_SRCS)
,
$(
wildcard
rts/
*
.c
$(
foreach
dir
,
$(ALL_DIRS)
,rts/
$(dir)
/
*
.c
)))
rts_CMM_SRCS
=
$(
wildcard
rts/
*
.cmm
)
# Don't compile .S files when bootstrapping a new arch
ifeq
"$(TARGETPLATFORM)" "$(HOSTPLATFORM)"
ifneq
"$(findstring $(TargetArch_CPP), powerpc powerpc64)" ""
rts_S_SRCS
+=
rts/AdjustorAsm.S
else
...
...
@@ -50,6 +52,7 @@ ifneq "$(findstring $(TargetOS_CPP), darwin)" ""
rts_S_SRCS
+=
rts/AdjustorAsm.S
endif
endif
endif
ifeq
"$(GhcUnregisterised)" "YES"
GENAPPLY_OPTS
=
-u
...
...
rules/build-prog.mk
View file @
81e5f8ff
...
...
@@ -97,9 +97,15 @@ $$(foreach dir,$$($1_$2_HS_SRC_DIRS),\
$(call
c-objs,$1,$2,v)
$(call
hs-objs,$1,$2,v)
ifeq
"$$(BootingFromHc)" "NO"
$1/$2/build/tmp/$$($1_$2_PROG)
:
$$($1_$2_v_HS_OBJS) $$($1_$2_v_C_OBJS) $$($1_$2_v_S_OBJS) $$($1_$2_OTHER_OBJS)
$
$(MKDIRHIER)
$
$(
dir
$$
@
)
$$
(
$1_$2_HC
)
-o
$$
@
$$
(
$1_$2_v_ALL_HC_OPTS
)
$
$(LD_OPTS)
$$
(
$1_$2_v_HS_OBJS
)
$$
(
$1_$2_v_C_OBJS
)
$$
(
$1_$2_v_S_OBJS
)
$$
(
$1_$2_OTHER_OBJS
)
else
$1/$2/build/tmp/$$($1_$2_PROG)
:
$$($1_$2_v_HS_OBJS) $$($1_$2_v_C_OBJS) $$($1_$2_v_S_OBJS) $$($1_$2_OTHER_OBJS)
$
$(MKDIRHIER)
$
$(
dir
$$
@
)
$
$(CC)
-o
$$
@
$$
(
$1_$2_v_ALL_CC_OPTS
)
$
$(LD_OPTS)
$$
(
$1_$2_v_HS_OBJS
)
$$
(
$1_$2_v_C_OBJS
)
$$
(
$1_$2_v_S_OBJS
)
$$
(
$1_$2_OTHER_OBJS
)
endif
# Note [lib-depends] if this program is built with stage1 or greater, we
# need to depend on the libraries too. NB. since $(ALL_STAGE1_LIBS) and
...
...
rules/hs-suffix-rules-srcdir.mk
View file @
81e5f8ff
...
...
@@ -54,7 +54,7 @@ endif
# XXX: for some reason these get used in preference to the direct
# .hs->.o rule, I don't know why --SDM
$1/$2/build/%.$$($3_osuf)
:
$1/$4/%.hc includes/ghcautoconf.h includes/ghcplatform.h
$1/$2/build/%.$$($3_osuf)
:
$1/$4/%.hc includes/ghcautoconf.h includes/ghcplatform.h
$$(MKDIRHIER)
$
$(MKDIRHIER)
$
$(
dir
$$
@
)
$
$(CC)
$$
(
$1_$2_$3_ALL_CC_OPTS
)
-Iincludes
-x
c
-c
$$
<
-o
$$
@
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment