summaryrefslogtreecommitdiff
path: root/rules/build-prog.mk
Commit message (Collapse)AuthorAgeFilesLines
* Don't link base/rts/... into C wrapper programsIan Lynagh2013-05-161-2/+2
|
* Make dynamic GHC no Windows installable tooIan Lynagh2013-05-161-11/+32
| | | | | We need different paths in the wrapper, as teh installed tree is a different shape to the build tree.
* Define the right RTS config in the Windows dyn wrapper programsIan Lynagh2013-05-141-0/+17
| | | | | | This is particularly important as without it validate fails, as it tries to pass RTS options to haddock, and with the default RTS config those options aren't permitted.
* More work towards dynamic programs on WindowsIan Lynagh2013-05-121-1/+20
| | | | | | | | | | | | | | | | | | | Dynamic GHC is now working in-place, but pathologically slow due to the DLL split. (GHC assumes that all intra-package calls are in the same DLL, but that isn't true when we split the GHC package into 2 DLLs. That means that GHC's startup time is around 22 seconds, as it is doing run-time linking). Also, ghci isn't actually working yet: $ inplace/bin/ghc-stage2 --interactive GHCi, version 7.7.20130512: http://www.haskell.org/ghc/ :? for help Loading package ghc-prim ... <command line>: can't load .so/.DLL for: HSghc-prim-0.3.1.0.dll (addDLL: could not load DLL) ghc-stage2.exe: HSghc-prim-0.3.1.0: The specified module could not be found.
* Fix "make 2" in ghc/Ian Lynagh2013-04-211-3/+12
| | | | The ghc-stage1_INPLACE variable wasn't being defined
* Use different exeext variables for each stage; fixes #7709Ian Lynagh2013-04-201-1/+1
| | | | | Currently they are all set to the same value, but when cross-compiling they could be set to different values.
* Follow build system changes in integer-gmpIan Lynagh2013-04-201-2/+4
| | | | Also a couple of other fixes and sanity checks along the way.
* Remove some commented out build system codeIan Lynagh2013-03-191-11/+0
|
* Partial support for dynamic ghc on WindowsIan Lynagh2013-03-161-1/+9
|
* By default, use the dynamic way for programs in the GHC treeIan Lynagh2013-03-151-2/+2
| | | | | In particular, this means that GHCi will use DLLs, rather than loading object files itself.
* Automatically add the $(exeext) to program namesIan Lynagh2013-03-031-8/+12
| | | | | | | We now define _PROGNAME, and _PROG is automatically defined with $(exeext). This will shortly automatically use the right exeext depending on what stage it is being compiled with (exeext may be different for different stages when cross-compiling).
* Define $(prog)_INPLACE variables automatically, and start using themIan Lynagh2013-03-031-5/+11
|
* Rename $(Windows) to $(Windows_Host)Ian Lynagh2013-03-011-2/+2
|
* Make the build system use -dynamic-too if both way v and dyn are being builtIan Lynagh2013-02-221-0/+2
|
* Separate the non-way-specific hs-suffix rulesIan Lynagh2013-02-211-0/+2
| | | | This means we don't define them multiple times
* Split non-way-specific variables off from distdir-way-opts into distdir-optsIan Lynagh2013-02-211-0/+1
| | | | | The hsc2hs, alex and happy options variables are now also non-way-specific, as the files are shared between all ways.
* Rename hs-suffix-rules to hs-suffix-way-rulesIan Lynagh2013-02-211-1/+1
|
* Finish removing BootingFromHcIan Lynagh2013-02-171-3/+0
|
* Build the stage0 ghc-pkg with CabalIan Lynagh2013-02-161-3/+3
| | | | | | | This solves the problem of how to define MIN_VERSION_base for the binary package. Also fixed a couple of build system bugs along the way.
* Add a dependency of program modules on GHC.TopHandlerIan Lynagh2013-02-051-0/+8
| | | | | | | | | | | If you were unlucky, the build could fail, e.g.: utils\mkUserGuidePart\Main.hs:1:1: Failed to load interface for `GHC.TopHandler' There are files missing in the `base' package, try running 'ghc-pkg check'. Use -v to see a list of the files searched for. utils/mkUserGuidePart/ghc.mk:18: recipe for target `utils/mkUserGuidePart/dist/build/Main.o' failed
* Small build system refactoringIan Lynagh2013-01-111-2/+0
| | | | hs-suffix-rules now calls hs-suffix-rules-srcdir, saving some duplication
* Give dynamic libraries, as well as programs, RPATHsIan Lynagh2012-11-081-13/+12
| | | | Based on a patch from markwright in #3072.
* When DYNAMIC_BY_DEFAULT, make inplace wrappers for everythingIan Lynagh2012-10-221-0/+2
| | | | | | Even though e.g. inplace/bin/hpc doesn't normally need a shell wrapper, it does when we are using dynlibs, as we need to set the LD_LIBRARY_PATH so that it can find its libraries.
* Fix copy/paste-oIan Lynagh2012-10-141-1/+1
|
* Get dynamic-by-default mostly working on OS XIan Lynagh2012-10-141-0/+15
|
* Move the RPATH computation into the build rulesIan Lynagh2012-10-141-1/+1
| | | | It doesn't really belong in package-data.mk
* Actually build things the dynamic wayIan Lynagh2012-10-041-16/+25
| | | | | Things went back to being statically linked again once I added an explicit -static flag to the vanilla way.
* Build the dynamic way by default on Linux/amd64Ian Lynagh2012-10-031-6/+34
| | | | | | | | | | | | | This required various build system changes to get the build to go through. In the inplace shell wrappers, we set LD_LIBRARY_PATH to allow programs to find their libraries. In the future, we might change the inplace tree to be the same shape as an installed tree instead. However, this would mean changing the way we do installation, as currently we use cabal's installation methods to install the libraries, but that only works if the libraries are under libraries/foo/dist-install/build/..., rather than in inplace/lib/...
* Refactor the shell-wrapper-creation logicIan Lynagh2012-10-011-1/+1
|
* Put libexec binaries in lib/bin/ rather than just lib/Ian Lynagh2012-10-011-1/+1
| | | | | | | Some binaries are installed in lib/, so if we wanted them to have a shell wrapper then under the old scheme both the binary and the wrapper would be installed under lib/. Now the binary is put under lib/bin/, leaving lib/ for the wrapper.
* Tweak the build system handling of shell wrappersIan Lynagh2012-09-271-3/+5
| | | | | | | Rather than having a separate foo_INSTALL_SHELL_WRAPPER variable, we just use foo_INSTALL && foo_SHELL_WRAPPER
* Remove a stray " in the build systemIan Lynagh2012-09-271-1/+1
|
* A build-system tweak for more readable build output.Iavor S. Diatchki2012-04-271-2/+2
| | | | | | | | | | | This change reduces the (default) verbosity of the build system. This makes it easier to spot warnings in the output and, also, it makes it easier to estimate how far along are we in the build process by just glancing at the output. To get the traditional fully verbose output, set V=1, like this: make V=1
* Remove some unnecessary touch'sIan Lynagh2011-12-031-2/+1
| | | | | They made a dependency cycle in the rules used to build the touch program on Windows.
* Use touchy rather than touch when building on WindowsIan Lynagh2011-12-021-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With Windows 7 in a vitrual box VM on OS X, some very odd things happen with dates and time stamps when SSHing into cygwin. e.g. here the "Change" time is in the past: $ date; touch foo; stat foo Fri Dec 2 16:58:07 GMTST 2011 File: `foo' Size: 0 Blocks: 0 IO Block: 65536 regular empty file Device: 540aba0bh/1409989131d Inode: 562949953592977 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ ian) Gid: ( 513/ None) Access: 2011-12-02 16:58:07.414457900 +0000 Modify: 2011-12-02 16:58:07.414457900 +0000 Change: 2011-12-02 16:58:03.495141800 +0000 Birth: 2011-12-02 16:57:57.731469900 +0000 And if we copy such a file, then the copy is older (as determined by the "Modify" time) than the original: $ date; touch foo; stat foo; cp foo bar; stat bar Fri Dec 2 16:59:10 GMTST 2011 File: `foo' Size: 0 Blocks: 0 IO Block: 65536 regular empty file Device: 540aba0bh/1409989131d Inode: 1407374883725128 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ ian) Gid: ( 513/ None) Access: 2011-12-02 16:59:10.118457900 +0000 Modify: 2011-12-02 16:59:10.118457900 +0000 Change: 2011-12-02 16:59:06.189477700 +0000 Birth: 2011-12-02 16:57:57.731469900 +0000 File: `bar' Size: 0 Blocks: 0 IO Block: 65536 regular empty file Device: 540aba0bh/1409989131d Inode: 281474976882512 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ ian) Gid: ( 513/ None) Access: 2011-12-02 16:59:06.394555800 +0000 Modify: 2011-12-02 16:59:06.394555800 +0000 Change: 2011-12-02 16:59:06.395532400 +0000 Birth: 2011-12-02 16:58:40.921899600 +0000 This means that make thinks that things are out of date when it shouldn't, so reinvokes itself repeatedly until the MAKE_RESTARTS infinite-recursion test triggers. The touchy program, like most other programs, creates files with both Modify and Change in the past, which is still a little odd, but is consistent, so doesn't break make.
* Time handling overhaulSimon Marlow2011-11-251-0/+4
| | | | | | | | | | | | | | | | | | | | | Terminology cleanup: the type "Ticks" has been renamed "Time", which is an StgWord64 in units of TIME_RESOLUTION (currently nanoseconds). The terminology "tick" is now used consistently to mean the interval between timer signals. The ticker now always ticks in realtime (actually CLOCK_MONOTONIC if we have it). Before it used CPU time in the non-threaded RTS and realtime in the threaded RTS, but I've discovered that the CPU timer has terrible resolution (at least on Linux) and isn't much use for profiling. So now we always use realtime. This should also fix The default tick interval is now 10ms, except when profiling where we drop it to 1ms. This gives more accurate profiles without affecting runtime too much (<1%). Lots of cleanups - the resolution of Time is now in one place only (Rts.h) rather than having calculations that depend on the resolution scattered all over the RTS. I hope I found them all.
* Make stage-specific CC variablesIan Lynagh2011-04-231-1/+1
| | | | | This allows different gcc's to be used when building different stages, which we need to do when cross-compiling.
* Refactor how dependencies are included; fixes #5109Ian Lynagh2011-04-141-15/+1
| | | | This avoids duplicating some logic around the build system.
* Call the final build system phase "final" rather than ""Ian Lynagh2011-02-071-2/+2
|
* Add build system profiling to build systemIan Lynagh2011-01-231-0/+2
|
* Simplify the build system, and remove 2 phasesIan Lynagh2011-01-221-62/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | From http://hackage.haskell.org/trac/ghc/wiki/Building/Architecture/Idiom/PhaseOrdering Phase 0: Includes: package-data.mk files for things built by the bootstrapping compiler. Builds: the dependency files for hsc2hs and genprimopcode. We need to do this now, as hsc2hs needs to be buildable in phase 1's includes (so that we can make the hpc library's .hs source files, which in turn is necessary for making its dependency files), and genprimopcode needs to be buildable in phase 1's includes (so that we can make the primop-*.hs-incl files, which are sources for the stage1 compiler library, and thus necessary for making its dependency files). Phase 1: Includes: dependency files for things built by the bootstrapping compiler. Builds: package-data.mk files for everything else. Note that this requires configuring the packages, which means telling cabal which ghc to use, and thus the stage1 compiler gets built during this phase. Phase "": Includes: dependency files for everything else. Builds: Everything else.
* Move some make variables aroundIan Lynagh2011-01-191-2/+2
|
* Fix deps on the ghc packageIan Lynagh2011-01-171-5/+8
| | | | | The standard libraries/$depname scheme doesn't apply, so we need to handle it specially.
* Handle dependencies of programs on libraries correctlyIan Lynagh2011-01-161-0/+8
|
* Build system improvementsIan Lynagh2011-01-151-41/+80
| | | | | | | | | We no longer use dummy-ghc; instead we don't configure most packages until the stage1 compiler is available. We also now use Cabal for building the ghc-bin package. There are a couple more sanity checks too.
* Don't link the GHC RTS into our C-only programsIan Lynagh2010-12-101-1/+8
|
* Link even programs containing no Haskell modules with GHCIan Lynagh2010-12-061-3/+0
| | | | | | I don't remember why we made it use gcc instead, but going back to using ghc doesn't seem to break anything, and should fix the build on OS X 10.6.
* Fix a makefile include ordering sanity checkIan Lynagh2010-11-211-2/+6
|
* Handle EXTRA_LIBRARIES when building programsIan Lynagh2010-09-301-2/+2
| | | | And set hp2ps's EXTRA_LIBRARIES. Based on a patch from Sergei Trofimovich.
* add a simple trace facility to the build systemSimon Marlow2010-09-211-0/+1
| | | | | | | | | saying make TRACE=1 prints most of the macro calls and their arguments. It's easy to trace new macros; see rules/trace.mk.