Commit Graph

823 Commits

Author SHA1 Message Date
Vladimir 'phcoder' Serbinenko f1632d4dd0 Fix compilation on cygwin.
* conf/Makefile.common (STRIPFLAGS_KERNEL): Add -F elf32-i386 and
	-R .drectve on cygwin.
	* conf/i386-pc-cygwin-img-ld.sc: Merge rdata and pdata into data.
	* configure.ac: Use $(top_builddir) in TARGET_OBJ2ELF.
	(COND_CYGWIN): New condition.
	* grub-core/Makefile.am (%.mod): Set TARGET_OBJ2ELF.
	* grub-core/genmod.sh.in: Use ${TARGET_OBJ2ELF} and
	not @TARGET_OBJ2ELF@.
	* util/grub-pe2elf.c (write_symbol_table): Use pe_symtab->type and not
	type to determine whether aux is to be used.
2011-01-13 22:23:49 +01:00
Colin Watson 24ec575b72 * conf/Makefile.common (CFLAGS_GNULIB): Add -Wno-unused-parameter.
(-Wunused implies -Wunused-parameter, but not vice versa).
2010-11-16 15:54:18 +00:00
Vladimir 'phcoder' Serbinenko 03f80960cf Don't add -lgcc on i386 and x86_64.
* configure.ac (LIBS): Don't add -lgcc on i386 and x86_64.
	* conf/Makefile.common (LDADD_KERNEL): Likewise.
	* grub-core/Makefile.core.def (kernel): Use LDADD_KERNEL.
2010-11-14 23:36:20 +01:00
Robert Millan d2bf06bf34 2010-11-07 Robert Millan <rmh@gnu.org>
On mips-yeeloong, build with -march=loongson2f when this flag is
	available (GCC >= 4.4).
	* conf/Makefile.common [COND_mips_yeeloong] (CFLAGS_PLATFORM): Remove
	`-march=mips3'.
	* configure.ac: For mips-yeeloong, add -march=loongson2f if available,
	or otherwise add -march=mips3.
2010-11-07 16:29:10 +01:00
Robert Millan 4f9b406ae3 2010-11-07 Robert Millan <rmh@gnu.org>
* conf/mips-qemu-mips.rmk: Remove stale file from previous
	transition.
2010-11-07 15:10:09 +01:00
BVK Chaitanya 4b2047e265 netbsd fixes 2010-10-19 10:44:57 +05:30
Colin Watson e1fd193905 Re-enable grub-extras.
* autogen.sh: Create symlinks to ${GRUB_CONTRIB} if necessary to
avoid confusing Automake.  Run autogen only twice, once for the top
level and once for grub-core.  Add Makefile.util.def and
Makefile.core.def from extra modules to the appropriate autogen
invocations.  If Makefile.common exists in an extra module, include
it in both Makefile.util.am and grub-core/Makefile.core.am;
similarly, include any Makefile.util.common file in Makefile.util.am
and any Makefile.core.common file in grub-core/Makefile.core.am.
* conf/Makefile.common ($(top_srcdir)/grub-core/Makefile.core.am):
Depend on $(top_srcdir)/grub-core/Makefile.gcry.def.
($(top_srcdir)/grub-core/Makefile.gcry.def): Remove.
* grub-core/Makefile.am: Remove inclusion of Makefile.gcry.am.
* gentpl.py (gvar_add): Turn GVARS into a set.
(global_variable_initializers): Sort global variables on output.
(vars_init): New function.
(first_time): Likewise.
(library): Ensure that non-global variable initialisations are
emitted before the first time we emit code for a library block.
Append to variables rather than setting them.  Only emit
noinst_LIBRARIES, BUILT_SOURCES, and CLEANFILES the first time for
each conditional path.
(program): installdir() emits an Autogen macro, so must be passed to
var_add rather than gvar_add.
(data): Likewise.
(script): Likewise.
(rules): New function, centralising handling for different target
types.  Set up Guile association lists for first_time and vars_init,
and send most output to a diversion so that variable initialisations
can be emitted first.
(module_rules): Use new rules function.
(kernel_rules): Likewise.
(image_rules): Likewise.
(library_rules): Likewise.
(program_rules): Likewise.
(script_rules): Likewise.
(data_rules): Likewise.
* configure.ac: Add AC_PROG_LN_S, for the benefit of ntldr-img.
* .bzrignore: Add contrib and grub-core/contrib.  Remove
grub-core/Makefile.gcry.am.
2010-09-24 09:48:27 +01:00
Colin Watson 8d5e2af3fc * conf/Makefile.common (CPPFLAGS_GNULIB): Add
$(top_srcdir)/grub-core/gnulib as well as
$(top_builddir)/grub-core/gnulib.
Reported by: KESHAV P.R.
2010-09-21 13:37:50 +01:00
Yves Blusseau b830cd16a1 * conf/Makefile.common (CPPFLAGS_GNULIB): Replace $(top_srcdir) with
$(top_builddir).
2010-09-21 12:02:59 +02:00
Yves Blusseau 15c6926126 Use gnulib-tool to create gnulib source files.
* Add gnulib files generated by gnulib-tool in build-aux, m4 and
    grub-core/gnulib directories
    * .bzignore: Add **/.deps and autogenerated gnulib files
    * configure.ac: Assign auxiliary directory to build-aux, add invocation
    of gnulib macros, add grub-core/gnulib/Makefile
    * Makefile.am: Add gnulib directory in SUBDIRS (removing unnecessary .),
    include m4 directory to aclocal.
    * Makefile.util.def: Remove direct compilation of gnulib source files
    and use the new grub-core/gnulib/libgnu.a.
    * build-aux/config.rpath: move config.rpath from top directory to
    build-aux
    * conf/Makefile.common: Remove the macro _GL_UNUSED already defined
    in gnulib headers
    * conf/Makefile.extra-dist: Add m4/gnulib-cache.m4
    * grub-core/Makefile.core.def: Remove unnecessary extra_dist
    * grub-core/lib/posix_wrap/localcharset.h (locale_charset): Update
    header.
    * grub-core/lib/posix_wrap/langinfo.h (nl_langinfo): Return static
    string.
2010-09-20 12:35:33 +02:00
BVK Chaitanya b524259bec merge with mainline 2010-09-19 18:54:45 +05:30
Vladimir 'phcoder' Serbinenko 050abaeaa8 Fix emu on mipsel.
* conf/Makefile.common (CFLAGS_PLATFORM): Add -mflush-func
	=grub_cpu_flush_cache on all mips and not only yeeloong.
	* configure.ac (COND_mips): New conditional.
	* grub-core/Makefile.am (KERNEL_HEADER_FILES): Add libgcc on all
	platforms.
	* grub-core/kern/emu/cache.S (__mips__): Use _flush_cache.
	* grub-core/kern/emu/full.c (grub_arch_dl_init_linker)
	[GRUB_LINKER_HAVE_INIT]: New function.
	(grub_emu_post_init): Likewise.
	* grub-core/kern/emu/lite.c (grub_emu_post_init): Likewise.
	* grub-core/kern/emu/main.c: Use grub_emu_post_init.
	* include/grub/cache.h (_mips): Include mips/cache.h.
	* include/grub/disk.h [GRUB_UTIL || GRUB_MACHINE_EMU]: Add missing
	LVM and RAID prototypes.
	* include/grub/emu/misc.h (grub_emu_post_init): New proto.
	* include/grub/mips/time.h (grub_cpu_idle) [GRUB_MACHINE_EMU]: New
	function.
2010-09-11 16:58:06 +02:00
BVK Chaitanya 6556eba9c6 Add missing files into "make dist" tarball for other platforms.
* gentpl.py (script): Use dist_noinst_DATA instead of EXTRA_DIST.
	* conf/Makefile.common (dist_noinst_DATA): New variable.
	* conf/Makefile.extra-dist: Added missing make dist files.
	* grub-core/Makefile.core.def: Likewise.
2010-09-03 21:23:00 +05:30
BVK Chaitanya ebd65b82dc remove leading / in dprintf output 2010-08-30 09:37:35 +05:30
BVK Chaitanya 6568636e31 use preprocessing-marker technique for creating list files 2010-08-29 21:22:41 +05:30
BVK Chaitanya 466b9c3567 distcheck fixes 2010-08-29 16:58:43 +05:30
BVK Chaitanya ea943e89a3 distcheck fixes 2010-08-29 12:35:52 +05:30
BVK Chaitanya 0d4552faca remove def-* and und-* list files 2010-08-29 11:17:30 +05:30
BVK Chaitanya a0bf9fc930 remove per module lst files for creating fs.lst, command.lst, etc. 2010-08-29 10:38:46 +05:30
BVK Chaitanya f7711f5ef1 final touches 2010-08-23 13:23:56 +05:30
BVK Chaitanya d84666e6bb merge with mainline 2010-08-22 21:00:22 +05:30
BVK Chaitanya bdf0d62321 review comments 2010-08-21 09:48:27 +05:30
Vladimir 'phcoder' Serbinenko d6f66ca2a0 Export serial-related functions from kernel 2010-08-20 21:31:33 +02:00
Vladimir 'phcoder' Serbinenko 41e46ae648 Enable usbserial on yeeloong 2010-08-20 21:26:04 +02:00
BVK Chaitanya 2bd591d03e add USE_ASCII_FAILBACK define 2010-08-21 00:50:12 +05:30
Vladimir 'phcoder' Serbinenko 8161b08687 Merge mainline into usb 2010-08-20 20:12:26 +02:00
BVK Chaitanya a71e471975 fix distcheck from source tree 2010-08-20 21:01:13 +05:30
BVK Chaitanya 34cf2b8aea fix distcheck 2010-08-20 18:47:22 +05:30
BVK Chaitanya 3d9d354297 generate gcry rules from import_gcry 2010-08-20 18:21:31 +05:30
BVK Chaitanya 02a6605e7e minor fixes 2010-08-20 11:10:42 +05:30
BVK Chaitanya a5a3bccd54 added conf/Makefile.common and conf/Makefile.extra-dist 2010-08-20 10:14:29 +05:30
Vladimir 'phcoder' Serbinenko b4ece5e11e Implement sendkey support.
* commands/i386/pc/sendkey.c: New file.
	* conf/i386-pc.rmk (pkglib_MODULES): Add sendkey.mod.
	(sendkey_mod_SOURCES): New variable.
	(sendkey_mod_CFLAGS): Likewise.
	(sendkey_mod_LDFLAGS): Likewise.
2010-08-19 21:03:14 +02:00
BVK Chaitanya 16c7cb32c8 merge with mainline 2010-08-19 16:54:00 +05:30
BVK Chaitanya 6304d29255 working copy, wo nested packaging 2010-08-17 19:03:22 +05:30
Vladimir 'phcoder' Serbinenko fafc23e90a merge mainline into usb 2010-08-01 21:23:18 +02:00
Vladimir 'phcoder' Serbinenko aa86530e38 enable usbserial on grub-emu 2010-07-18 19:11:09 +02:00
Vladimir 'phcoder' Serbinenko a531fd134d Split common usbserial function. PL2303 skeleton 2010-07-18 19:10:57 +02:00
Vladimir 'phcoder' Serbinenko dd20a7868b Rename usbserial to usbserial_ftdi 2010-07-18 16:31:42 +02:00
Vladimir 'phcoder' Serbinenko 34364df689 usbserial basic support. Works in qemu 2010-07-18 12:53:35 +02:00
Vladimir 'phcoder' Serbinenko 75eb7d1116 Restructure serial in order to prepare for usbserial. As a byproduct simultaneous serial consoles are possible 2010-07-18 01:37:19 +02:00
BVK Chaitanya 05df19acd5 merge with mainline 2010-07-12 17:03:01 +05:30
Colin Watson 0b0f9620f2 * conf/common.rmk (grub_probe_SOURCES): Add disk/raid5_recover.c
and disk/raid6_recover.c.
* conf/i386-pc.rmk (grub_setup_SOURCES): Likewise.
* conf/sparc64-ieee1275.rmk (grub_setup_SOURCES): Likewise.
2010-07-06 19:27:55 +01:00
Vladimir 'phcoder' Serbinenko e8d0a8f85c Merge mainline into bidi 2010-07-02 19:35:07 +02:00
Vladimir 'phcoder' Serbinenko b7e79e8a6a Merge mainline into yeeloongfw 2010-06-30 02:30:05 +02:00
Vladimir 'phcoder' Serbinenko 412e09f355 XEN with Linux grub-mkconfig support.
* conf/common.rmk (grub-mkconfig_SCRIPTS) [linux]: Add 20_linux_xen.
	* util/grub-mkconfig.in: Export GRUB_CMDLINE_XEN and
	GRUB_CMDLINE_XEN_DEFAULT.
	* util/grub.d/20_linux_xen.in: New file.
2010-06-28 02:39:49 +02:00
Vladimir 'phcoder' Serbinenko 53f3ef38c5 Initialise VGA video on qemu ourselves.
* boot/i386/qemu/boot.S: Don't call 0xc000.
	* conf/i386-qemu.rmk (kern/i386/qemu/init.c_DEPENDENCIES): New variable.
	(kernel_img_SOURCES): Add kern/i386/qemu/init.c and bus/pci.c.
	(kernel_img_HEADERS): Add pci.h.
	* conf/i386.rmk (pkglib_MODULES) [qemu]: Remove pci.mod.
	* configure.ac: Force unifont on qemu and yeeloong.
	* include/grub/i386/qemu/kernel.h (grub_qemu_init_cirrus): New proto.
	(grub_vga_palette_write): Use correct register.
	* kern/i386/coreboot/init.c (grub_machine_init) [GRUB_MACHINE_QEMU]:
	Call grub_qemu_init_cirrus.
	* kern/i386/qemu/init.c: New file.
	* term/i386/pc/vga_text.c (inc_y): Never read outside the screen.

	* commands/videotest.c (grub_cmd_videotest): Handle double buffering.
2010-06-28 02:33:32 +02:00
BVK Chaitanya 14d3f08e70 Fix parallel build.
* conf/common.rmk: Add grub_script.tab.h as a grub-script-check
	dependency.
	* script/parser.y: #include grub_script.tab.h header.
2010-06-21 20:34:30 +05:30
Vladimir 'phcoder' Serbinenko 8e50ec9f05 Merge mainline into cirrus 2010-06-21 02:15:49 +02:00
Vladimir 'phcoder' Serbinenko 4d88b9aec7 Init cirrus ourselves instead of calling videobios 2010-06-21 01:02:48 +02:00
Vladimir 'phcoder' Serbinenko 05e5187978 Cirrus 5446 and Bochs video cards support.
* conf/i386.rmk (pkglib_MODULES): Add video_cirrus.mod and
	video_bochs.mod
	(video_cirrus_mod_SOURCES): New variable.
	(video_cirrus_mod_CFLAGS): Likewise.
	(video_cirrus_mod_LDFLAGS): Likewise.
	(video_bochs_mod_SOURCES): Likewise.
	(video_bochs_mod_CFLAGS): Likewise.
	(video_bochs_mod_LDFLAGS): Likewise.
	* include/grub/vga.h: New file.
	* include/grub/video_fb.h (grub_video_fb_doublebuf_blit_init): Removed.
	(grub_video_fb_set_page_t): New type.
	(grub_video_fb_setup): New prototype.
	(grub_video_fb_swap_buffers): Likewise.
	(grub_video_fb_get_info_and_fini): Likewise.
	* term/i386/pc/vga_text.c (CRTC_ADDR_PORT): Moved to include/grub/vga.h.
	(CRTC_DATA_PORT): Likewise.
	(CRTC_CURSOR): Likewise.
	(CRTC_CURSOR_ADDR_HIGH): Likewise.
	(CRTC_CURSOR_ADDR_LOW): Likewise.
	(CRTC_CURSOR_DISABLE): Likewise.
	(update_cursor): Use grub_vga_cr_write.
	(grub_vga_text_setcursor): Likewise.
	* video/bochs.c: New file.
	* video/fb/video_fb.c (render_target): Moved into framebuffer variable.
	(palette): Likewise.
	(palette_size): Likewise.
	(framebuffer): New variable.
	(grub_video_fb_init): Use 'framebuffer'.
	(grub_video_fb_fini): Likewise.
	(grub_video_fb_get_info): Likewise.
	(grub_video_fb_get_palette): Likewise.
	(grub_video_fb_set_palette): Likewise.
	(grub_video_fb_set_viewport): Likewise.
	(grub_video_fb_get_viewport): Likewise.
	(grub_video_fb_map_color): Likewise.
	(grub_video_fb_map_rgb): Likewise.
	(grub_video_fb_map_rgba): Likewise.
	(grub_video_fb_unmap_color): Likewise.
	(grub_video_fb_unmap_color_int): Likewise.
	(grub_video_fb_fill_rect): Likewise.
	(grub_video_fb_blit_bitmap): Likewise.
	(grub_video_fb_blit_render_target): Likewise.
	(grub_video_fb_scroll): Likewise.
	(grub_video_fb_create_render_target): Likewise.
	(grub_video_fb_doublebuf_blit_init): Likewise.
	(grub_video_fb_set_active_render_target): Handle doublebuffering.
	(doublebuf_pageflipping_update_screen): New function.
	(doublebuf_pageflipping_init): Likewise.
	(grub_video_fb_setup): Likewise.
	(grub_video_fb_swap_buffers): Likewise.
	(grub_video_fb_get_info_and_fini): Likewise.
	* video/i386/pc/vbe.c (framebuffer): Remove all doublebuffering fields.
	All users updated.
	(doublebuf_pageflipping_commit): Restructured into ...
	(doublebuf_pageflipping_set_page): ... this.
	(doublebuf_pageflipping_update_screen): Removed.
	(doublebuf_pageflipping_init): Likewise.
	(double_buffering_init): Likewise.
	(grub_video_vbe_setup): Use grub_video_fb_setup.
	(grub_video_vbe_swap_buffers): Removed.
	(grub_video_vbe_set_active_render_target): Likewise.
	(grub_video_vbe_get_active_render_target): Likewise.
	(grub_video_vbe_get_info_and_fini): Use grub_video_fb_get_info_and_fini.
	(grub_video_vbe_adapter): Use grub_video_fb_swap_buffers,
	grub_video_fb_set_active_render_target and
	grub_video_fb_get_active_render_target.
	* video/i386/pc/vga.c (SEQUENCER_ADDR_PORT): Move to include/grub/vga.h.
	(SEQUENCER_DATA_PORT): Likewise.
	(MAP_MASK_REGISTER): Likewise.
	(CRTC_ADDR_PORT): Likewise.
	(CRTC_DATA_PORT): Likewise.
	(START_ADDR_HIGH_REGISTER): Likewise.
	(START_ADDR_LOW_REGISTER): Likewise.
	(GRAPHICS_ADDR_PORT): Likewise.
	(GRAPHICS_DATA_PORT): Likewise.
	(READ_MAP_REGISTER): Likewise.
	(INPUT_STATUS1_REGISTER): Likewise.
	(INPUT_STATUS1_VERTR_BIT): Likewise.
	(get_map_mask): Use grub_vga_sr_read.
	(set_map_mask): Use grub_vga_sr_write.
	(set_read_map): Use grub_vga_gr_write.
	(set_start_address): Use grub_vga_cr_write.
	* video/sm712.c (framebuffer): Remove leftover fields.
2010-06-20 14:15:20 +02:00