Changeset 573
- Timestamp:
- May 19, 2015, 3:52:07 PM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
soft/giet_vm/Makefile
r571 r573 162 162 DISK_IMAGE := hdd/virt_hdd.dmg 163 163 164 all: map.bin \ 164 all: $(DISK_IMAGE) \ 165 map.bin \ 165 166 hard_config.h \ 166 167 giet_vsegs.ld \ … … 178 179 build/classif/classif.elf \ 179 180 build/coproc/coproc.elf \ 180 $(DISK_IMAGE) 181 182 ### Copy always all files into disk image 183 mcopy -o -i $(DISK_IMAGE) build/kernel/kernel.elf ::/build/kernel 184 mcopy -o -i $(DISK_IMAGE) build/display/display.elf ::/build/display 185 mcopy -o -i $(DISK_IMAGE) build/hello/hello.elf ::/build/hello 186 mcopy -o -i $(DISK_IMAGE) build/pgcd/pgcd.elf ::/build/pgcd 187 mcopy -o -i $(DISK_IMAGE) build/router/router.elf ::/build/router 188 mcopy -o -i $(DISK_IMAGE) build/dhrystone/dhrystone.elf ::/build/dhrystone 189 mcopy -o -i $(DISK_IMAGE) build/gameoflife/gameoflife.elf ::/build/gameoflife 190 mcopy -o -i $(DISK_IMAGE) build/sort/sort.elf ::/build/sort 191 mcopy -o -i $(DISK_IMAGE) build/transpose/transpose.elf ::/build/transpose 192 mcopy -o -i $(DISK_IMAGE) build/convol/convol.elf ::/build/convol 193 mcopy -o -i $(DISK_IMAGE) build/classif/classif.elf ::/build/classif 194 mcopy -o -i $(DISK_IMAGE) build/coproc/coproc.elf ::/build/coproc 181 182 mdir -/ -b -i $(DISK_IMAGE) ::/ 183 184 ### copy the files generated by the virtual prototype on 185 ### the virtual disk "home" directory to the giet_vm home directory 186 extract: 187 mcopy -o -i $(DISK_IMAGE) ::/home . 188 189 ### Disk image generation (no files in this step) 190 ### This requires the generic LINUX/MacOS script "create_dmg" script 191 ### written by C.Fuguet. (should be installed in GIET-VM root directory). 192 ### create the three build / misc / home directories 193 ### store the images files into misc 194 $(DISK_IMAGE): 195 ./create_dmg create $(basename $(DISK_IMAGE)) 196 dd if=$(DISK_IMAGE) of=temp.dmg count=65536 197 mv temp.dmg $(DISK_IMAGE) 198 mmd -o -i $(DISK_IMAGE) ::/build 199 mmd -o -i $(DISK_IMAGE) ::/misc 200 mmd -o -i $(DISK_IMAGE) ::/home 195 201 mcopy -o -i $(DISK_IMAGE) applications/transpose/images.raw ::/misc 196 202 mcopy -o -i $(DISK_IMAGE) applications/convol/philips_image.raw ::/misc 197 203 mcopy -o -i $(DISK_IMAGE) applications/display/lena.raw ::/misc 198 mcopy -o -i $(DISK_IMAGE) map.bin ::/199 ### Copy bootloader into sector 2 of disk image200 dd if=build/boot/boot.elf of=$(DISK_IMAGE) seek=2 conv=notrunc201 ### Checking root directory202 mdir -/ -b -i $(DISK_IMAGE) ::/203 204 ### Disk image generation (no files in this step)205 ### This requires the generic LINUX/MacOS script "create_dmg" script206 ### written by C.Fuguet. (should be installed in GIET-VM root directory).207 $(DISK_IMAGE):208 ./create_dmg create $(basename $(DISK_IMAGE))209 mmd -o -i $(DISK_IMAGE) ::/build210 mmd -o -i $(DISK_IMAGE) ::/build/kernel211 mmd -o -i $(DISK_IMAGE) ::/build/display212 mmd -o -i $(DISK_IMAGE) ::/build/hello213 mmd -o -i $(DISK_IMAGE) ::/build/pgcd214 mmd -o -i $(DISK_IMAGE) ::/build/router215 mmd -o -i $(DISK_IMAGE) ::/build/dhrystone216 mmd -o -i $(DISK_IMAGE) ::/build/gameoflife217 mmd -o -i $(DISK_IMAGE) ::/build/sort218 mmd -o -i $(DISK_IMAGE) ::/build/transpose219 mmd -o -i $(DISK_IMAGE) ::/build/convol220 mmd -o -i $(DISK_IMAGE) ::/build/classif221 mmd -o -i $(DISK_IMAGE) ::/build/coproc222 mmd -o -i $(DISK_IMAGE) ::/misc223 dd if=$(DISK_IMAGE) of=temp.dmg count=65536224 mv temp.dmg $(DISK_IMAGE)225 204 226 205 ### mapping generation: map.bin / map.xml / hard_config.h / giet_vsegs.ld … … 236 215 --$(APP) \ 237 216 --xml=. 217 mcopy -o -i $(DISK_IMAGE) map.bin ::/ 238 218 239 219 ### drivers compilation … … 385 365 ######################## 386 366 ### boot compilation 367 ### Copy bootloader into sector 2 of disk image 387 368 build/boot: 388 369 mkdir $@ … … 393 374 $(LD) -o $@ -T giet_boot/boot.ld $(BOOT_OBJS) -Lbuild/drivers -ldrivers 394 375 $(DU) -D $@ > $@.txt 376 dd if=$@ of=$(DISK_IMAGE) seek=2 conv=notrunc 395 377 396 378 build/boot/boot.o: giet_boot/boot.c \ … … 412 394 build/drivers/libdrivers.a 413 395 $(LD) -o $@ -T giet_kernel/kernel.ld $(KERNEL_OBJS) -Lbuild/drivers -ldrivers 414 $(DU) -D $@ > $@.txt 396 $(DU) -D $@ > $@.txt 397 mmd -o -i $(DISK_IMAGE) ::/build/kernel || true 398 mcopy -o -i $(DISK_IMAGE) $@ ::/build/kernel 415 399 416 400 build/kernel/%.o: giet_kernel/%.c \ … … 473 457 $(LD) -o $@ -T applications/display/display.ld $(DISPLAY_OBJS) 474 458 $(DU) -D $@ > $@.txt 459 mmd -o -i $(DISK_IMAGE) ::/build/display || true 460 mcopy -o -i $(DISK_IMAGE) $@ ::/build/display 475 461 476 462 build/display/main.o: applications/display/main.c … … 482 468 $(LD) -o $@ -T applications/router/router.ld $(ROUTER_OBJS) 483 469 $(DU) -D $@ > $@.txt 470 mmd -o -i $(DISK_IMAGE) ::/build/router || true 471 mcopy -o -i $(DISK_IMAGE) $@ ::/build/router 484 472 485 473 build/router/main.o: applications/router/main.c … … 491 479 $(LD) -o $@ -T applications/hello/hello.ld $(HELLO_OBJS) 492 480 $(DU) -D $@ > $@.txt 481 mmd -o -i $(DISK_IMAGE) ::/build/hello || true 482 mcopy -o -i $(DISK_IMAGE) $@ ::/build/hello 493 483 494 484 build/hello/main.o: applications/hello/main.c … … 500 490 $(LD) -o $@ -T applications/pgcd/pgcd.ld $(PGCD_OBJS) 501 491 $(DU) -D $@ > $@.txt 492 mmd -o -i $(DISK_IMAGE) ::/build/pgcd || true 493 mcopy -o -i $(DISK_IMAGE) $@ ::/build/pgcd 502 494 503 495 build/pgcd/main.o: applications/pgcd/main.c … … 509 501 $(LD) -o $@ -T applications/gameoflife/gameoflife.ld $(GAMEOFLIFE_OBJS) 510 502 $(DU) -D $@ > $@.txt 503 mmd -o -i $(DISK_IMAGE) ::/build/gameoflife || true 504 mcopy -o -i $(DISK_IMAGE) $@ ::/build/gameoflife 511 505 512 506 build/gameoflife/main.o: applications/gameoflife/main.c … … 518 512 $(LD) -o $@ -T applications/dhrystone/dhrystone.ld $(DHRYSTONE_OBJS) 519 513 $(DU) -D $@ > $@.txt 514 mmd -o -i $(DISK_IMAGE) ::/build/dhrystone || true 515 mcopy -o -i $(DISK_IMAGE) $@ ::/build/dhrystone 520 516 521 517 build/dhrystone/dhry_1.o: applications/dhrystone/dhry_1.c … … 530 526 $(LD) -o $@ -T applications/sort/sort.ld $(SORT_OBJS) 531 527 $(DU) -D $@ > $@.txt 528 mmd -o -i $(DISK_IMAGE) ::/build/sort || true 529 mcopy -o -i $(DISK_IMAGE) $@ ::/build/sort 532 530 533 531 build/sort/main.o: applications/sort/main.c … … 539 537 $(LD) -o $@ -T applications/transpose/transpose.ld $(TRANSPOSE_OBJS) 540 538 $(DU) -D $@ > $@.txt 539 mmd -o -i $(DISK_IMAGE) ::/build/transpose || true 540 mcopy -o -i $(DISK_IMAGE) $@ ::/build/transpose 541 541 542 542 build/transpose/main.o: applications/transpose/main.c … … 548 548 $(LD) -o $@ -T applications/convol/convol.ld $(CONVOL_OBJS) 549 549 $(DU) -D $@ > $@.txt 550 mmd -o -i $(DISK_IMAGE) ::/build/convol || true 551 mcopy -o -i $(DISK_IMAGE) $@ ::/build/convol 550 552 551 553 build/convol/main.o: applications/convol/main.c … … 557 559 $(LD) -o $@ -T applications/classif/classif.ld $(CLASSIF_OBJS) 558 560 $(DU) -D $@ > $@.txt 561 mmd -o -i $(DISK_IMAGE) ::/build/classif || true 562 mcopy -o -i $(DISK_IMAGE) $@ ::/build/classif 559 563 560 564 build/classif/main.o: applications/classif/main.c … … 566 570 $(LD) -o $@ -T applications/coproc/coproc.ld $(COPROC_OBJS) 567 571 $(DU) -D $@ > $@.txt 572 mmd -o -i $(DISK_IMAGE) ::/build/coproc || true 573 mcopy -o -i $(DISK_IMAGE) $@ ::/build/coproc 568 574 569 575 build/coproc/main.o: applications/coproc/main.c … … 593 599 rm -rf build/classif/* 594 600 rm -rf build/coproc/* 595 rm -rf $(DISK_IMAGE)
Note: See TracChangeset
for help on using the changeset viewer.