@@ -1,3 +1,4 @@
1+cabal-version: 2.2
12name: streamly
23version: 0.6.1
34synopsis: Beautiful Streaming, Concurrent and Reactive Composition
@@ -86,7 +87,7 @@ description:
8687
8788homepage: https://github.com/composewell/streamly
8889bug-reports: https://github.com/composewell/streamly/issues
89−license: BSD3
90+license: BSD-3-Clause
9091license-file: LICENSE
9192tested-with: GHC==7.10.3
9293 , GHC==8.0.2
@@ -98,7 +99,6 @@ copyright: 2017 Harendra Kumar
9899category: Control, Concurrency, Streaming, Reactivity
99100stability: Experimental
100101build-type: Configure
101−cabal-version: >= 1.10
102102
103103extra-source-files:
104104 Changelog.md
@@ -171,11 +171,81 @@ flag examples-sdl
171171 manual: True
172172 default: False
173173
174+-------------------------------------------------------------------------------
175+-- Common stanzas
176+-------------------------------------------------------------------------------
177+
178+common compile-options
179+ default-language: Haskell2010
180+ if flag(streamk)
181+ cpp-options: -DUSE_STREAMK_ONLY
182+
183+ if flag(no-fusion)
184+ cpp-options: -DDISABLE_FUSION
185+
186+ if flag(dev)
187+ cpp-options: -DDEVBUILD
188+
189+ ghc-options: -Wall
190+
191+ if flag(has-llvm)
192+ ghc-options: -fllvm
193+
194+ if flag(dev)
195+ ghc-options: -Wmissed-specialisations
196+ -Wall-missed-specialisations
197+ -fno-ignore-asserts
198+ if impl(ghc >= 8.0)
199+ ghc-options: -Wcompat
200+ -Wunrecognised-warning-flags
201+ -Widentities
202+ -Wincomplete-record-updates
203+ -Wincomplete-uni-patterns
204+ -Wredundant-constraints
205+ -Wnoncanonical-monad-instances
206+ -Wnoncanonical-monadfail-instances
207+
208+common optimization-options
209+ ghc-options: -O2
210+ -fspec-constr-recursive=10
211+ -fmax-worker-args=16
212+
213+common threading-options
214+ ghc-options: -threaded
215+ -with-rtsopts=-N
216+
217+-- We need optimization options here to optimize internal (non-inlined)
218+-- versions of functions. Also, we have some benchmarking inspection tests
219+-- part of the library when built with --benchmarks flag. Thos tests fail
220+-- if we do not use optimization options here. It was observed that due to
221+-- -O2 here some concurrent/nested benchmarks improved and others regressed.
222+-- We can investigate a bit more here why the regression occurred.
223+common lib-options
224+ import: compile-options, optimization-options
225+
226+-- Compilation for coverage builds on CI machines takes too long without -O0
227+-- XXX we should use coverage flag for that, -O0 may take too long to run tests
228+-- in general.
229+common test-options
230+ import: compile-options, threading-options
231+ ghc-options: -O0
232+ -fno-ignore-asserts
233+
234+-- Used by maxrate test, benchmarks and executables
235+common exe-options
236+ import: compile-options, optimization-options, threading-options
237+
238+-- Some benchmarks are threaded some are not
239+common bench-options
240+ import: compile-options, optimization-options
241+ ghc-options: -with-rtsopts "-T"
242+
174243-------------------------------------------------------------------------------
175244-- Library
176245-------------------------------------------------------------------------------
177246
178247library
248+ import: lib-options
179249 js-sources: jsbits/clock.js
180250 include-dirs: src/Streamly/Time
181251 , src/Streamly/Streams
@@ -260,42 +330,6 @@ library
260330 , Streamly.Benchmark.FileIO.Array
261331 , Streamly.Benchmark.FileIO.Stream
262332
263− default-language: Haskell2010
264− -- We need optimization options here to optimize internal (non-inlined)
265− -- versions of functions. Also, we have some benchmarking inspection tests
266− -- part of the library when built with --benchmarks flag. Thos tests fail
267− -- if we do not use optimization options here. It was observed that due to
268− -- -O2 here some concurrent/nested benchmarks improved and others regressed.
269− -- We can investigate a bit more here why the regression occurred.
270− ghc-options: -Wall
271− -O2
272− -fspec-constr-recursive=10
273− -fmax-worker-args=16
274−
275− if flag(has-llvm)
276− ghc-options: -fllvm
277−
278− if flag(streamk)
279− cpp-options: -DUSE_STREAMK_ONLY
280−
281− if flag(no-fusion)
282− cpp-options: -DDISABLE_FUSION
283−
284− if flag(dev)
285− cpp-options: -DDEVBUILD
286− ghc-options: -Wmissed-specialisations
287− -Wall-missed-specialisations
288− -fno-ignore-asserts
289− if impl(ghc >= 8.0)
290− ghc-options: -Wcompat
291− -Wunrecognised-warning-flags
292− -Widentities
293− -Wincomplete-record-updates
294− -Wincomplete-uni-patterns
295− -Wredundant-constraints
296− -Wnoncanonical-monad-instances
297− -Wnoncanonical-monadfail-instances
298−
299333 build-depends: base >= 4.8 && < 5
300334 , ghc-prim >= 0.2 && < 0.6
301335 , deepseq >= 1.4.1 && < 1.5
@@ -328,27 +362,12 @@ library
328362-- Test suites
329363-------------------------------------------------------------------------------
330364
331−-- Compilation for coverage builds on CI machines takes too long without -O0
332−
333365test-suite test
366+ import: test-options
334367 type: exitcode-stdio-1.0
335368 main-is: Main.hs
336369 js-sources: jsbits/clock.js
337370 hs-source-dirs: test
338− ghc-options: -O0 -Wall -threaded -with-rtsopts=-N -fno-ignore-asserts
339− if flag(dev)
340− cpp-options: -DDEVBUILD
341− ghc-options: -Wmissed-specialisations
342− -Wall-missed-specialisations
343− if impl(ghc >= 8.0)
344− ghc-options: -Wcompat
345− -Wunrecognised-warning-flags
346− -Widentities
347− -Wincomplete-record-updates
348− -Wincomplete-uni-patterns
349− -Wredundant-constraints
350− -Wnoncanonical-monad-instances
351− -Wnoncanonical-monadfail-instances
352371 build-depends:
353372 streamly
354373 , base >= 4.8 && < 5
@@ -360,23 +379,10 @@ test-suite test
360379 default-language: Haskell2010
361380
362381test-suite pure-streams-base
382+ import: test-options
363383 type: exitcode-stdio-1.0
364384 main-is: PureStreams.hs
365385 hs-source-dirs: test
366− ghc-options: -Wall -threaded -with-rtsopts=-N -fno-ignore-asserts
367− if flag(dev)
368− cpp-options: -DDEVBUILD
369− ghc-options: -Wmissed-specialisations
370− -Wall-missed-specialisations
371− if impl(ghc >= 8.0)
372− ghc-options: -Wcompat
373− -Wunrecognised-warning-flags
374− -Widentities
375− -Wincomplete-record-updates
376− -Wincomplete-uni-patterns
377− -Wredundant-constraints
378− -Wnoncanonical-monad-instances
379− -Wnoncanonical-monadfail-instances
380386 build-depends:
381387 streamly
382388 , base >= 4.8 && < 5
@@ -385,23 +391,10 @@ test-suite pure-streams-base
385391
386392-- test-suite pure-streams-streamly
387393-- type: exitcode-stdio-1.0
394+-- import: test-options
388395-- main-is: PureStreams.hs
389396-- hs-source-dirs: test
390397-- cpp-options: -DUSE_STREAMLY_LIST
391−-- ghc-options: -O0 -Wall -threaded -with-rtsopts=-N -fno-ignore-asserts
392−-- if flag(dev)
393−-- cpp-options: -DDEVBUILD
394−-- ghc-options: -Wmissed-specialisations
395−-- -Wall-missed-specialisations
396−-- if impl(ghc >= 8.0)
397−-- ghc-options: -Wcompat
398−-- -Wunrecognised-warning-flags
399−-- -Widentities
400−-- -Wincomplete-record-updates
401−-- -Wincomplete-uni-patterns
402−-- -Wredundant-constraints
403−-- -Wnoncanonical-monad-instances
404−-- -Wnoncanonical-monadfail-instances
405398-- build-depends:
406399-- streamly
407400-- , base >= 4.8 && < 5
@@ -409,24 +402,11 @@ test-suite pure-streams-base
409402-- default-language: Haskell2010
410403
411404test-suite properties
405+ import: test-options
412406 type: exitcode-stdio-1.0
413407 main-is: Prop.hs
414408 js-sources: jsbits/clock.js
415409 hs-source-dirs: test
416− ghc-options: -fno-ignore-asserts -Wall -O0 -threaded -with-rtsopts=-N
417− if flag(dev)
418− cpp-options: -DDEVBUILD
419− ghc-options: -Wmissed-specialisations
420− -Wall-missed-specialisations
421− if impl(ghc >= 8.0)
422− ghc-options: -Wcompat
423− -Wunrecognised-warning-flags
424− -Widentities
425− -Wincomplete-record-updates
426− -Wincomplete-uni-patterns
427− -Wredundant-constraints
428− -Wnoncanonical-monad-instances
429− -Wnoncanonical-monadfail-instances
430410 build-depends:
431411 streamly
432412 , base >= 4.8 && < 5
@@ -438,24 +418,11 @@ test-suite properties
438418 default-language: Haskell2010
439419
440420test-suite array-test
421+ import: test-options
441422 type: exitcode-stdio-1.0
442423 main-is: Arrays.hs
443424 js-sources: jsbits/clock.js
444425 hs-source-dirs: test
445− ghc-options: -fno-ignore-asserts -Wall -O0 -threaded -with-rtsopts=-N
446− if flag(dev)
447− cpp-options: -DDEVBUILD
448− ghc-options: -Wmissed-specialisations
449− -Wall-missed-specialisations
450− if impl(ghc >= 8.0)
451− ghc-options: -Wcompat
452− -Wunrecognised-warning-flags
453− -Widentities
454− -Wincomplete-record-updates
455− -Wincomplete-uni-patterns
456− -Wredundant-constraints
457− -Wnoncanonical-monad-instances
458− -Wnoncanonical-monadfail-instances
459426 build-depends:
460427 streamly
461428 , base >= 4.8 && < 5
@@ -467,24 +434,11 @@ test-suite array-test
467434 default-language: Haskell2010
468435
469436test-suite string-test
437+ import: test-options
470438 type: exitcode-stdio-1.0
471439 main-is: String.hs
472440 js-sources: jsbits/clock.js
473441 hs-source-dirs: test
474− ghc-options: -fno-ignore-asserts -Wall -O0 -threaded -with-rtsopts=-N
475− if flag(dev)
476− cpp-options: -DDEVBUILD
477− ghc-options: -Wmissed-specialisations
478− -Wall-missed-specialisations
479− if impl(ghc >= 8.0)
480− ghc-options: -Wcompat
481− -Wunrecognised-warning-flags
482− -Widentities
483− -Wincomplete-record-updates
484− -Wincomplete-uni-patterns
485− -Wredundant-constraints
486− -Wnoncanonical-monad-instances
487− -Wnoncanonical-monadfail-instances
488442 build-depends:
489443 streamly
490444 , base >= 4.8 && < 5
@@ -496,12 +450,12 @@ test-suite string-test
496450 default-language: Haskell2010
497451
498452test-suite maxrate
453+ import: exe-options
499454 type: exitcode-stdio-1.0
500455 default-language: Haskell2010
501456 main-is: MaxRate.hs
502457 js-sources: jsbits/clock.js
503458 hs-source-dirs: test
504− ghc-options: -fno-ignore-asserts -O2 -Wall -threaded -with-rtsopts=-N
505459 if flag(dev)
506460 buildable: True
507461 build-Depends:
@@ -514,43 +468,43 @@ test-suite maxrate
514468 buildable: False
515469
516470test-suite loops
471+ import: test-options
517472 type: exitcode-stdio-1.0
518473 default-language: Haskell2010
519474 main-is: loops.hs
520475 hs-source-dirs: test
521− ghc-options: -fno-ignore-asserts -O2 -Wall -threaded -with-rtsopts=-N
522476 build-Depends:
523477 streamly
524478 , base >= 4.8 && < 5
525479
526480test-suite nested-loops
481+ import: test-options
527482 type: exitcode-stdio-1.0
528483 default-language: Haskell2010
529484 main-is: nested-loops.hs
530485 hs-source-dirs: test
531− ghc-options: -fno-ignore-asserts -O2 -Wall -threaded -with-rtsopts=-N
532486 build-Depends:
533487 streamly
534488 , base >= 4.8 && < 5
535489 , random >= 1.0.0 && < 2
536490
537491test-suite parallel-loops
492+ import: test-options
538493 type: exitcode-stdio-1.0
539494 default-language: Haskell2010
540495 main-is: parallel-loops.hs
541496 hs-source-dirs: test
542− ghc-options: -fno-ignore-asserts -O2 -Wall -threaded -with-rtsopts=-N
543497 build-Depends:
544498 streamly
545499 , base >= 4.8 && < 5
546500 , random >= 1.0.0 && < 2
547501
548502test-suite inspection
503+ import: test-options
549504 type: exitcode-stdio-1.0
550505 default-language: Haskell2010
551506 main-is: inspection.hs
552507 hs-source-dirs: test
553− ghc-options: -fno-ignore-asserts -O2 -Wall -threaded -with-rtsopts=-N
554508 build-Depends:
555509 streamly
556510 , base >= 4.8 && < 5
@@ -566,33 +520,11 @@ test-suite inspection
566520-------------------------------------------------------------------------------
567521
568522benchmark linear
523+ import: bench-options
569524 type: exitcode-stdio-1.0
570525 hs-source-dirs: benchmark
571526 main-is: Linear.hs
572527 other-modules: LinearOps
573− default-language: Haskell2010
574− ghc-options: -O2
575− -fspec-constr-recursive=10
576− -fmax-worker-args=16
577− -Wall
578− -with-rtsopts "-T"
579−
580− if flag(has-llvm)
581− ghc-options: -fllvm
582−
583− if flag(dev)
584− ghc-options: -Wmissed-specialisations
585− -Wall-missed-specialisations
586− -fno-ignore-asserts
587− if impl(ghc >= 8.0)
588− ghc-options: -Wcompat
589− -Wunrecognised-warning-flags
590− -Widentities
591− -Wincomplete-record-updates
592− -Wincomplete-uni-patterns
593− -Wredundant-constraints
594− -Wnoncanonical-monad-instances
595− -Wnoncanonical-monadfail-instances
596528 build-depends:
597529 streamly
598530 , base >= 4.8 && < 5
@@ -604,34 +536,12 @@ benchmark linear
604536 transformers >= 0.4 && < 0.6
605537
606538benchmark linear-async
539+ import: bench-options
540+ cpp-options: -DLINEAR_ASYNC
607541 type: exitcode-stdio-1.0
608542 hs-source-dirs: benchmark
609543 main-is: LinearAsync.hs
610544 other-modules: LinearOps
611− default-language: Haskell2010
612− ghc-options: -O2
613− -fspec-constr-recursive=10
614− -fmax-worker-args=16
615− -Wall
616− -with-rtsopts "-T"
617−
618− if flag(has-llvm)
619− ghc-options: -fllvm
620−
621− cpp-options: -DLINEAR_ASYNC
622− if flag(dev)
623− ghc-options: -Wmissed-specialisations
624− -Wall-missed-specialisations
625− -fno-ignore-asserts
626− if impl(ghc >= 8.0)
627− ghc-options: -Wcompat
628− -Wunrecognised-warning-flags
629− -Widentities
630− -Wincomplete-record-updates
631− -Wincomplete-uni-patterns
632− -Wredundant-constraints
633− -Wnoncanonical-monad-instances
634− -Wnoncanonical-monadfail-instances
635545 build-depends:
636546 streamly
637547 , base >= 4.8 && < 5
@@ -643,33 +553,11 @@ benchmark linear-async
643553 transformers >= 0.4 && < 0.6
644554
645555benchmark linear-rate
556+ import: bench-options
646557 type: exitcode-stdio-1.0
647558 hs-source-dirs: benchmark
648559 main-is: LinearRate.hs
649560 other-modules: LinearOps
650− default-language: Haskell2010
651− ghc-options: -O2
652− -fspec-constr-recursive=10
653− -fmax-worker-args=16
654− -Wall
655− -with-rtsopts "-T"
656−
657− if flag(has-llvm)
658− ghc-options: -fllvm
659−
660− if flag(dev)
661− ghc-options: -Wmissed-specialisations
662− -Wall-missed-specialisations
663− -fno-ignore-asserts
664− if impl(ghc >= 8.0)
665− ghc-options: -Wcompat
666− -Wunrecognised-warning-flags
667− -Widentities
668− -Wincomplete-record-updates
669− -Wincomplete-uni-patterns
670− -Wredundant-constraints
671− -Wnoncanonical-monad-instances
672− -Wnoncanonical-monadfail-instances
673561 build-depends:
674562 streamly
675563 , base >= 4.8 && < 5
@@ -681,34 +569,11 @@ benchmark linear-rate
681569 transformers >= 0.4 && < 0.6
682570
683571benchmark nested
572+ import: bench-options
684573 type: exitcode-stdio-1.0
685574 hs-source-dirs: benchmark
686575 main-is: Nested.hs
687576 other-modules: NestedOps
688− default-language: Haskell2010
689− ghc-options: -O2
690− -fspec-constr-recursive=10
691− -fmax-worker-args=16
692− -Wall
693− -with-rtsopts "-T"
694−
695− if flag(has-llvm)
696− ghc-options: -fllvm
697−
698− if flag(dev)
699− cpp-options: -DDEVBUILD
700− ghc-options: -Wmissed-specialisations
701− -Wall-missed-specialisations
702− -fno-ignore-asserts
703− if impl(ghc >= 8.0)
704− ghc-options: -Wcompat
705− -Wunrecognised-warning-flags
706− -Widentities
707− -Wincomplete-record-updates
708− -Wincomplete-uni-patterns
709− -Wredundant-constraints
710− -Wnoncanonical-monad-instances
711− -Wnoncanonical-monadfail-instances
712577 build-depends:
713578 streamly
714579 , base >= 4.8 && < 5
@@ -720,34 +585,11 @@ benchmark nested
720585 transformers >= 0.4 && < 0.6
721586
722587benchmark array
588+ import: bench-options
723589 type: exitcode-stdio-1.0
724590 hs-source-dirs: benchmark
725591 main-is: Array.hs
726592 other-modules: ArrayOps
727− default-language: Haskell2010
728− ghc-options: -O2
729− -fspec-constr-recursive=10
730− -fmax-worker-args=16
731− -Wall
732− -with-rtsopts "-T"
733−
734− if flag(has-llvm)
735− ghc-options: -fllvm
736−
737− if flag(dev)
738− cpp-options: -DDEVBUILD
739− ghc-options: -Wmissed-specialisations
740− -Wall-missed-specialisations
741− -fno-ignore-asserts
742− if impl(ghc >= 8.0)
743− ghc-options: -Wcompat
744− -Wunrecognised-warning-flags
745− -Widentities
746− -Wincomplete-record-updates
747− -Wincomplete-uni-patterns
748− -Wredundant-constraints
749− -Wnoncanonical-monad-instances
750− -Wnoncanonical-monadfail-instances
751593 build-depends:
752594 streamly
753595 , base >= 4.8 && < 5
@@ -759,33 +601,10 @@ benchmark array
759601 transformers >= 0.4 && < 0.6
760602
761603benchmark fileio
604+ import: bench-options
762605 type: exitcode-stdio-1.0
763606 hs-source-dirs: benchmark
764607 main-is: FileIO.hs
765− default-language: Haskell2010
766− ghc-options: -O2
767− -fspec-constr-recursive=10
768− -fmax-worker-args=16
769− -Wall
770− -with-rtsopts "-T"
771−
772− if flag(has-llvm)
773− ghc-options: -fllvm
774−
775− if flag(dev)
776− cpp-options: -DDEVBUILD
777− ghc-options: -Wmissed-specialisations
778− -Wall-missed-specialisations
779− -fno-ignore-asserts
780− if impl(ghc >= 8.0)
781− ghc-options: -Wcompat
782− -Wunrecognised-warning-flags
783− -Widentities
784− -Wincomplete-record-updates
785− -Wincomplete-uni-patterns
786− -Wredundant-constraints
787− -Wnoncanonical-monad-instances
788− -Wnoncanonical-monadfail-instances
789608 if flag(benchmark)
790609 buildable: True
791610 build-depends:
@@ -799,33 +618,10 @@ benchmark fileio
799618 buildable: False
800619
801620benchmark concurrent
621+ import: bench-options
802622 type: exitcode-stdio-1.0
803623 hs-source-dirs: benchmark
804624 main-is: Concurrent.hs
805− default-language: Haskell2010
806− ghc-options: -O2
807− -fspec-constr-recursive=10
808− -fmax-worker-args=16
809− -Wall
810− -with-rtsopts "-T"
811−
812− if flag(has-llvm)
813− ghc-options: -fllvm
814−
815− if flag(dev)
816− cpp-options: -DDEVBUILD
817− ghc-options: -Wmissed-specialisations
818− -Wall-missed-specialisations
819− -fno-ignore-asserts
820− if impl(ghc >= 8.0)
821− ghc-options: -Wcompat
822− -Wunrecognised-warning-flags
823− -Widentities
824− -Wincomplete-record-updates
825− -Wincomplete-uni-patterns
826− -Wredundant-constraints
827− -Wnoncanonical-monad-instances
828− -Wnoncanonical-monadfail-instances
829625 if flag(dev)
830626 buildable: True
831627 build-depends:
@@ -843,6 +639,7 @@ benchmark concurrent
843639-- way to use unexposed modules from the library.
844640
845641benchmark base
642+ import: bench-options
846643 type: exitcode-stdio-1.0
847644 include-dirs: src/Streamly/Time
848645 , src/Streamly/Streams
@@ -866,30 +663,6 @@ benchmark base
866663 , StreamDOps
867664 , StreamKOps
868665
869− default-language: Haskell2010
870− ghc-options: -O2
871− -fspec-constr-recursive=10
872− -fmax-worker-args=16
873− -Wall
874− -with-rtsopts "-T"
875−
876− if flag(has-llvm)
877− ghc-options: -fllvm
878−
879− if flag(dev)
880− ghc-options: -Wmissed-specialisations
881− -Wall-missed-specialisations
882− -fno-ignore-asserts
883− if impl(ghc >= 8.0)
884− ghc-options: -Wcompat
885− -Wunrecognised-warning-flags
886− -Widentities
887− -Wincomplete-record-updates
888− -Wincomplete-uni-patterns
889− -Wredundant-constraints
890− -Wnoncanonical-monad-instances
891− -Wnoncanonical-monadfail-instances
892−
893666 if flag(dev)
894667 buildable: True
895668 build-depends:
@@ -919,6 +692,7 @@ benchmark base
919692 buildable: False
920693
921694executable nano-bench
695+ import: bench-options
922696 hs-source-dirs: benchmark, src
923697 include-dirs: src/Streamly/Time
924698 , src/Streamly/Streams
@@ -936,16 +710,6 @@ executable nano-bench
936710 , Streamly.Streams.StreamD.Type
937711 , Streamly.FileSystem.IOVec
938712 , Streamly.Streams.StreamD
939− default-language: Haskell2010
940− ghc-options: -O2
941− -fspec-constr-recursive=10
942− -fmax-worker-args=16
943− -Wall
944− -with-rtsopts "-T"
945−
946− if flag(has-llvm)
947− ghc-options: -fllvm
948−
949713 if flag(dev)
950714 buildable: True
951715 build-depends:
@@ -970,18 +734,10 @@ executable nano-bench
970734 buildable: False
971735
972736executable adaptive
737+ import: bench-options
973738 hs-source-dirs: benchmark
974739 main-is: Adaptive.hs
975740 default-language: Haskell2010
976− ghc-options: -O2
977− -fspec-constr-recursive=10
978− -fmax-worker-args=16
979− -Wall
980− -with-rtsopts "-T"
981−
982− if flag(has-llvm)
983− ghc-options: -fllvm
984−
985741 if flag(dev)
986742 buildable: True
987743 build-depends:
@@ -994,6 +750,7 @@ executable adaptive
994750
995751executable chart
996752 default-language: Haskell2010
753+ ghc-options: -Wall
997754 hs-source-dirs: benchmark
998755 main-is: Chart.hs
999756 if flag(dev) && !flag(no-charts) && !impl(ghcjs)
@@ -1011,14 +768,9 @@ executable chart
1011768-------------------------------------------------------------------------------
1012769
1013770executable SearchQuery
1014− default-language: Haskell2010
771+ import: exe-options
1015772 main-is: SearchQuery.hs
1016773 hs-source-dirs: examples
1017− ghc-options: -O2
1018− -fspec-constr-recursive=10
1019− -fmax-worker-args=16
1020− -Wall
1021− -with-rtsopts "-T"
1022774 if (flag(examples) || flag(examples-sdl)) && !impl(ghcjs)
1023775 buildable: True
1024776 build-Depends:
@@ -1029,14 +781,9 @@ executable SearchQuery
1029781 buildable: False
1030782
1031783executable ListDir
1032− default-language: Haskell2010
784+ import: exe-options
1033785 main-is: ListDir.hs
1034786 hs-source-dirs: examples
1035− ghc-options: -O2
1036− -fspec-constr-recursive=10
1037− -fmax-worker-args=16
1038− -Wall
1039− -with-rtsopts "-T"
1040787 if flag(examples) || flag(examples-sdl)
1041788 buildable: True
1042789 build-Depends:
@@ -1050,14 +797,9 @@ executable ListDir
1050797 buildable: False
1051798
1052799executable MergeSort
1053− default-language: Haskell2010
800+ import: exe-options
1054801 main-is: MergeSort.hs
1055802 hs-source-dirs: examples
1056− ghc-options: -O2
1057− -fspec-constr-recursive=10
1058− -fmax-worker-args=16
1059− -Wall
1060− -with-rtsopts "-T"
1061803 if flag(examples) || flag(examples-sdl)
1062804 buildable: True
1063805 build-Depends:
@@ -1068,14 +810,9 @@ executable MergeSort
1068810 buildable: False
1069811
1070812executable AcidRain
1071− default-language: Haskell2010
813+ import: exe-options
1072814 main-is: AcidRain.hs
1073815 hs-source-dirs: examples
1074− ghc-options: -O2
1075− -fspec-constr-recursive=10
1076− -fmax-worker-args=16
1077− -Wall
1078− -with-rtsopts "-T"
1079816 if flag(examples) || flag(examples-sdl)
1080817 buildable: True
1081818 build-Depends:
@@ -1090,14 +827,9 @@ executable AcidRain
1090827 buildable: False
1091828
1092829executable CirclingSquare
1093− default-language: Haskell2010
830+ import: exe-options
1094831 main-is: CirclingSquare.hs
1095832 hs-source-dirs: examples
1096− ghc-options: -O2
1097− -fspec-constr-recursive=10
1098− -fmax-worker-args=16
1099− -Wall
1100− -with-rtsopts "-T"
1101833 if flag(examples-sdl)
1102834 buildable: True
1103835 build-Depends:
@@ -1108,10 +840,9 @@ executable CirclingSquare
1108840 buildable: False
1109841
1110842executable ControlFlow
1111− default-language: Haskell2010
843+ import: exe-options
1112844 main-is: ControlFlow.hs
1113845 hs-source-dirs: examples
1114− ghc-options: -Wall
1115846 if flag(examples) || flag(examples-sdl)
1116847 buildable: True
1117848 build-Depends:
@@ -1127,14 +858,9 @@ executable ControlFlow
1127858 buildable: False
1128859
1129860executable HandleIO
1130− default-language: Haskell2010
861+ import: exe-options
1131862 main-is: HandleIO.hs
1132863 hs-source-dirs: examples
1133− ghc-options: -O2
1134− -fspec-constr-recursive=10
1135− -fmax-worker-args=16
1136− -Wall
1137− -with-rtsopts "-T"
1138864 if flag(examples) || flag(examples-sdl)
1139865 buildable: True
1140866 build-Depends:
@@ -1144,14 +870,9 @@ executable HandleIO
1144870 buildable: False
1145871
1146872executable FileIOExamples
1147− default-language: Haskell2010
873+ import: exe-options
1148874 main-is: FileIOExamples.hs
1149875 hs-source-dirs: examples
1150− ghc-options: -O2
1151− -fspec-constr-recursive=10
1152− -fmax-worker-args=16
1153− -Wall
1154− -with-rtsopts "-T"
1155876 if flag(examples) || flag(examples-sdl)
1156877 buildable: False
1157878 build-Depends:
@@ -1161,14 +882,9 @@ executable FileIOExamples
1161882 buildable: False
1162883
1163884executable EchoServer
1164− default-language: Haskell2010
885+ import: exe-options
1165886 main-is: EchoServer.hs
1166887 hs-source-dirs: examples
1167− ghc-options: -O2
1168− -fspec-constr-recursive=10
1169− -fmax-worker-args=16
1170− -Wall
1171− -with-rtsopts "-T"
1172888 if (flag(examples) || flag(examples-sdl)) && !impl(ghcjs)
1173889 buildable: True
1174890 build-Depends:
@@ -1178,14 +894,9 @@ executable EchoServer
1178894 buildable: False
1179895
1180896executable FileSinkServer
1181− default-language: Haskell2010
897+ import: exe-options
1182898 main-is: FileSinkServer.hs
1183899 hs-source-dirs: examples
1184− ghc-options: -O2
1185− -fspec-constr-recursive=10
1186− -fmax-worker-args=16
1187− -Wall
1188− -with-rtsopts "-T"
1189900 if (flag(examples) || flag(examples-sdl)) && !impl(ghcjs)
1190901 buildable: True
1191902 build-Depends:
@@ -1195,14 +906,9 @@ executable FileSinkServer
1195906 buildable: False
1196907
1197908executable FromFileClient
1198− default-language: Haskell2010
909+ import: exe-options
1199910 main-is: FromFileClient.hs
1200911 hs-source-dirs: examples
1201− ghc-options: -O2
1202− -fspec-constr-recursive=10
1203− -fmax-worker-args=16
1204− -Wall
1205− -with-rtsopts "-T"
1206912 if (flag(examples) || flag(examples-sdl)) && !impl(ghcjs)
1207913 buildable: True
1208914 build-Depends: