Previous 199869 Revisions Next

r36785 Sunday 29th March, 2015 at 22:50:56 UTC by Couriersud
linux-gmake, linux-gmake-clang: Only run genie build stage if scripts or
makefile has changed.

The concept may easily be migrated to other builds. I just don't have
the time to test other builds right now.

The downside of the approach is that you have to force a build stage run
by deleting the build/projects folder. This however is a lot less
frequent than normal "make".
[/trunk]makefile

trunk/makefile
r245296r245297
333333PARAMS+= --LDOPTS='$(LDOPTS)'
334334endif
335335
336#-------------------------------------------------
337# All scripts
338#-------------------------------------------------
339
340SCRIPTS = scripts/genie.lua \
341   scripts/src/lib.lua \
342   scripts/src/emu.lua \
343   scripts/src/machine.lua \
344   scripts/src/main.lua \
345   scripts/src/3rdparty.lua \
346   scripts/src/cpu.lua \
347   scripts/src/osd/windows_cfg.lua \
348   scripts/src/osd/sdl_cfg.lua \
349   scripts/src/osd/windows.lua \
350   scripts/src/osd/osdmini_cfg.lua \
351   scripts/src/osd/osdmini.lua \
352   scripts/src/sound.lua \
353   scripts/src/tools.lua \
354   scripts/src/video.lua \
355   scripts/src/bus.lua \
356   scripts/src/netlist.lua \
357   scripts/toolchain.lua \
358   scripts/target/ume/tiny.lua \
359   scripts/target/ume/ume.lua \
360   scripts/target/mess/tiny.lua \
361   scripts/target/mess/mess.lua \
362   scripts/target/ldplayer/ldplayer.lua \
363   scripts/target/mame/mame.lua \
364   scripts/target/mame/tiny.lua
365
366#-------------------------------------------------
367# Dependent stuff
368#-------------------------------------------------
369
336370# extension for executables
337371EXE =
338372
r245296r245297
360394endif
361395
362396GENDIR = build/generated
397PROJECTDIR = build/projects/$(SUBDIR)
363398
364399# all sources are under the src/ directory
365400SRC = src
r245296r245297
412447ifndef COMPILE
413448   $(SILENT) $(GENIE) $(PARAMS) --gcc=mingw64-gcc --gcc_version=$(GCC_VERSION) gmake
414449endif
415   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-mingw64-gcc config=$(CONFIG)64 WINDRES=$(WINDRES)
450   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-mingw64-gcc config=$(CONFIG)64 WINDRES=$(WINDRES)
416451
417452windows: windows_x86
418453
r245296r245297
423458ifndef COMPILE
424459   $(SILENT) $(GENIE) $(PARAMS) --gcc=mingw32-gcc --gcc_version=$(GCC_VERSION) gmake
425460endif
426   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-mingw32-gcc config=$(CONFIG)32 WINDRES=$(WINDRES)
461   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-mingw32-gcc config=$(CONFIG)32 WINDRES=$(WINDRES)
427462
428463windows_x64_clang: generate
429464ifndef CLANG
r245296r245297
432467ifndef COMPILE
433468   $(SILENT) $(GENIE) $(PARAMS) --gcc=mingw-clang --gcc_version=$(CLANG_VERSION) gmake
434469endif
435   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-mingw-clang config=$(CONFIG)64 WINDRES=$(WINDRES)
470   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-mingw-clang config=$(CONFIG)64 WINDRES=$(WINDRES)
436471   
437472windows_x86_clang: generate
438473ifndef CLANG
r245296r245297
441476ifndef COMPILE
442477   $(SILENT) $(GENIE) $(PARAMS) --gcc=mingw-clang --gcc_version=$(CLANG_VERSION) gmake
443478endif
444   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-mingw-clang config=$(CONFIG)32 WINDRES=$(WINDRES)
479   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-mingw-clang config=$(CONFIG)32 WINDRES=$(WINDRES)
445480
446481vs2010: generate
447482   $(SILENT) $(GENIE) $(PARAMS) vs2010
r245296r245297
477512ifndef COMPILE
478513   $(SILENT) $(GENIE) $(PARAMS) --gcc=android-arm --gcc_version=4.8 gmake
479514endif
480   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-android-arm config=$(CONFIG)
515   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-android-arm config=$(CONFIG)
481516
482517android-mips: generate
483518ifndef ANDROID_NDK_MIPS
r245296r245297
489524ifndef COMPILE
490525   $(SILENT) $(GENIE) $(PARAMS) --gcc=android-mips --gcc_version=4.8 gmake
491526endif
492   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-android-mips config=$(CONFIG)
527   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-android-mips config=$(CONFIG)
493528
494529android-x86: generate
495530ifndef ANDROID_NDK_X86
r245296r245297
501536ifndef COMPILE
502537   $(SILENT) $(GENIE) $(PARAMS) --gcc=android-x86 --gcc_version=4.8 gmake
503538endif
504   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-android-x86 config=$(CONFIG)
539   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-android-x86 config=$(CONFIG)
505540
506541asmjs: generate
507542ifndef EMSCRIPTEN
r245296r245297
510545ifndef COMPILE
511546   $(SILENT) $(GENIE) $(PARAMS) --gcc=asmjs --gcc_version=4.8 gmake
512547endif
513   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-asmjs config=$(CONFIG)
548   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-asmjs config=$(CONFIG)
514549
515550
516551nacl: nacl_x86
r245296r245297
522557ifndef COMPILE
523558   $(SILENT) $(GENIE) $(PARAMS) --gcc=nacl --gcc_version=4.8 gmake
524559endif
525   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-nacl config=$(CONFIG)64
560   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-nacl config=$(CONFIG)64
526561
527562nacl_x86: generate
528563ifndef NACL_SDK_ROOT
r245296r245297
531566ifndef COMPILE
532567   $(SILENT) $(GENIE) $(PARAMS) --gcc=nacl --gcc_version=4.8 gmake
533568endif
534   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-nacl config=$(CONFIG)32
569   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-nacl config=$(CONFIG)32
535570
536571nacl-arm: generate
537572ifndef NACL_SDK_ROOT
r245296r245297
540575ifndef COMPILE
541576   $(SILENT) $(GENIE) $(PARAMS) --gcc=nacl-arm --gcc_version=4.8 gmake
542577endif
543   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-nacl-arm config=$(CONFIG)
578   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-nacl-arm config=$(CONFIG)
544579
545580pnacl: generate
546581ifndef NACL_SDK_ROOT
r245296r245297
549584ifndef COMPILE
550585   $(SILENT) $(GENIE) $(PARAMS) --gcc=pnacl --gcc_version=4.8 gmake
551586endif
552   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-pnacl config=$(CONFIG)
587   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-pnacl config=$(CONFIG)
553588
554linux_x64: generate
555ifndef COMPILE
589#-------------------------------------------------
590# linux_gcc
591#-------------------------------------------------
592
593$(PROJECTDIR)/gmake-linux/Makefile: makefile $(SCRIPTS)
556594   $(SILENT) $(GENIE) $(PARAMS) --gcc=linux-gcc --gcc_version=$(GCC_VERSION) gmake
557endif
558   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-linux config=$(CONFIG)64
559595
596linux_x64: generate $(PROJECTDIR)/gmake-linux/Makefile
597   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-linux config=$(CONFIG)64
598
560599linux: linux_x86
561600
562linux_x86: generate
563ifndef COMPILE
564   $(SILENT) $(GENIE) $(PARAMS) --gcc=linux-gcc --gcc_version=$(GCC_VERSION) gmake
565endif
566   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-linux config=$(CONFIG)32
601linux_x86: generate $(PROJECTDIR)/gmake-linux/Makefile
602   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-linux config=$(CONFIG)32
567603
568linux_x64_clang: generate
569ifndef COMPILE
570   $(SILENT) $(GENIE) $(PARAMS) --gcc=linux-clang --gcc_version=$(CLANG_VERSION) gmake
571endif
572   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-linux-clang config=$(CONFIG)64
604#-------------------------------------------------
605# linux_clang
606#-------------------------------------------------
573607
574linux_x86_clang: generate
575ifndef COMPILE
608$(PROJECTDIR)/gmake-linux-clang/Makefile: makefile $(SCRIPTS)
576609   $(SILENT) $(GENIE) $(PARAMS) --gcc=linux-clang --gcc_version=$(CLANG_VERSION) gmake
577endif
578   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-linux-clang config=$(CONFIG)32
579610
611linux_x64_clang: generate $(PROJECTDIR)/gmake-linux-clang/Makefile
612   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-linux-clang config=$(CONFIG)64
613
614linux_x86_clang: generate $(PROJECTDIR)/gmake-linux-clang/Makefile
615   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-linux-clang config=$(CONFIG)32
616
580617macosx_x64: generate
581618ifndef COMPILE
582619   $(SILENT) $(GENIE) $(PARAMS) --gcc=osx --gcc_version=$(GCC_VERSION) gmake
583620endif
584   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-osx config=$(CONFIG)64
621   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-osx config=$(CONFIG)64
585622
586623macosx: macosx_x86
587624
r245296r245297
589626ifndef COMPILE
590627   $(SILENT) $(GENIE) $(PARAMS) --gcc=osx --os_version=$(DARWIN_VERSION) --gcc_version=$(GCC_VERSION) gmake
591628endif
592   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-osx config=$(CONFIG)32
629   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-osx config=$(CONFIG)32
593630
594631macosx_x64_clang: generate
595632ifndef COMPILE
596633   $(SILENT) $(GENIE) $(PARAMS) --gcc=osx-clang --gcc_version=$(CLANG_VERSION) gmake
597634endif
598   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-osx-clang config=$(CONFIG)64
635   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-osx-clang config=$(CONFIG)64
599636
600637macosx_x86_clang: generate
601638ifndef COMPILE
602639   $(SILENT) $(GENIE) $(PARAMS) --gcc=osx-clang --os_version=$(DARWIN_VERSION) --gcc_version=$(CLANG_VERSION) gmake
603640endif
604   $(SILENT) $(MAKE) --no-print-directory -R -C build/projects/$(SUBDIR)/gmake-osx-clang config=$(CONFIG)32
641   $(SILENT) $(MAKE) --no-print-directory -R -C $(PROJECTDIR)/gmake-osx-clang config=$(CONFIG)32
605642
606643$(GENIE):
607644   $(SILENT) $(MAKE) --no-print-directory -R -C 3rdparty/genie/build/gmake.$(GENIEOS) -f genie.make


Previous 199869 Revisions Next


© 1997-2024 The MAME Team