1. 09 5月, 2014 1 次提交
  2. 08 5月, 2014 3 次提交
    • S
      configure: Show trace output file conditionally · e00e36fb
      Stefan Weil 提交于
      It is only used with the simple trace backend.
      Signed-off-by: NStefan Weil <sw@weilnetz.de>
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      e00e36fb
    • M
      configure: remove bashism · 4fc00556
      Michael Tokarev 提交于
      Commit e26110cf added a check for shacmd to create a hash
      for modules.  This check in configure is using bash construct &>
      to redirect both stdout and stderr, which does fun things on some
      shells.  Get rid of it, use standard redirection instead.
      Signed-off-by: NMichael Tokarev <mjt@tls.msk.ru>
      Reviewed-by: NFam Zheng <famz@redhat.com>
      4fc00556
    • M
      configure: make source tree build more robust · cab00a5a
      Michael S. Tsirkin 提交于
      When source directory can be arrived at by two paths,
      configure might misdetect an out of tree build.
      The simplest way to trigger the problem is running
      configure using a full path. E.g. (<firstpath> refers to qemu source
      tree):
          ln -s <firstpath> <secondpath>
          cd <firstpath>
          <secondpath>/configure
      
      A more practical way is when make runs configure automatically:
      
      1. cd <firstpath>/; ./configure
          SRC_PATH=<firstpath>/ is written into config_host.mak
      2. cd <secondpath>/; touch configure; make
          make now runs <firstpath>/configure, so configure
          assumes it's an out of tree build
      
      When this happens configure overwrites parts of
      the current tree with symlinks.
      
      Make the test more robust: look for configure
      in the current directory.
      If there - we know it's a source build!
      Signed-off-by: NMichael S. Tsirkin <mst@redhat.com>
      cab00a5a
  3. 03 5月, 2014 1 次提交
    • R
      linux-user: remove configure option for setting uname release · e586822a
      Riku Voipio 提交于
      --enable-uname-release was a rather heavyweight hammer, as it allows
      providing values less that UNAME_MINIMUM_RELEASE. Also, it affects
      all built linux-user targets, which in most cases is not what user
      wants.
      
      Now that we have UNAME_MINIMUM_RELEASE for all linux-user platforms,
      we can drop --enable-uname-release and the related CONFIG_UNAME_RELEASE
      define.
      
      Users can still override the variable with QEMU_UNAME=2.6.32 or -r
      command line option. If distributors need to update a minimum version
      for a specific target, it can be done by updating UNAME_MINIMUM_RELEASE.
      Signed-off-by: NRiku Voipio <riku.voipio@linaro.org>
      e586822a
  4. 29 4月, 2014 2 次提交
  5. 27 4月, 2014 1 次提交
  6. 18 4月, 2014 2 次提交
  7. 14 4月, 2014 1 次提交
  8. 11 4月, 2014 1 次提交
  9. 01 4月, 2014 1 次提交
    • S
      configure: add option to disable -fstack-protector flags · 63678e17
      Steven Noonan 提交于
      The -fstack-protector flag family is useful for ensuring safety and for
      debugging, but has a performance impact. Here are some boot time comparisons of
      the various versions of -fstack-protector using qemu-system-arm on an x86_64
      host:
      
          # -fstack-protector-all
          Startup finished in 1.810s (kernel) + 12.331s (initrd) + 49.016s (userspace) = 1min 3.159s
          Startup finished in 1.801s (kernel) + 12.287s (initrd) + 47.925s (userspace) = 1min 2.013s
          Startup finished in 1.812s (kernel) + 12.302s (initrd) + 47.995s (userspace) = 1min 2.111s
      
          # -fstack-protector-strong
          Startup finished in 1.744s (kernel) + 11.223s (initrd) + 44.688s (userspace) = 57.657s
          Startup finished in 1.721s (kernel) + 11.222s (initrd) + 44.194s (userspace) = 57.138s
          Startup finished in 1.693s (kernel) + 11.250s (initrd) + 44.426s (userspace) = 57.370s
      
          # -fstack-protector
          Startup finished in 1.705s (kernel) + 11.409s (initrd) + 43.563s (userspace) = 56.677s
          Startup finished in 1.877s (kernel) + 11.137s (initrd) + 43.719s (userspace) = 56.734s
          Startup finished in 1.708s (kernel) + 11.141s (initrd) + 43.628s (userspace) = 56.478s
      
          # no stack protector
          Startup finished in 1.743s (kernel) + 11.190s (initrd) + 43.709s (userspace) = 56.643s
          Startup finished in 1.763s (kernel) + 11.216s (initrd) + 43.767s (userspace) = 56.747s
          Startup finished in 1.711s (kernel) + 11.283s (initrd) + 43.878s (userspace) = 56.873s
      
      This patch introduces a configure option to disable the stack protector
      entirely, and conditional stack protector flag selection (in order,
      based on availability): -fstack-protector-strong, -fstack-protector-all,
      no stack protector.
      Signed-off-by: NSteven Noonan <snoonan@amazon.com>
      Cc: Anthony Liguori <aliguori@amazon.com>
      Reviewed-by: NStefan Weil <sw@weilnetz.de>
      [Prefer -fstack-protector-all to -fstack-protector, suggested by
       Laurent Desnogues. - Paolo]
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      63678e17
  10. 27 3月, 2014 1 次提交
  11. 26 3月, 2014 1 次提交
  12. 19 3月, 2014 1 次提交
    • P
      block/nfs: bump libnfs requirement to 1.9.3 · b7d769c9
      Peter Lieven 提交于
      libnfs prior to 1.9.3 contains a bug that will report
      wrong transfer sizes if the file offset grows beyond 4GB
      and RPC responses are received out of order. this
      error is not detectable and fixable in qemu.
      
      additionally 1.9.3 introduces support for handling short
      read/writes in general and takes care of the necessary
      retransmissions internally.
      Signed-off-by: NPeter Lieven <pl@kamp.de>
      Signed-off-by: NKevin Wolf <kwolf@redhat.com>
      b7d769c9
  13. 15 3月, 2014 1 次提交
  14. 11 3月, 2014 1 次提交
  15. 10 3月, 2014 1 次提交
  16. 09 3月, 2014 1 次提交
  17. 07 3月, 2014 2 次提交
    • P
      configure: Always build with -fno-common · 4c288acb
      Peter Maydell 提交于
      MacOSX doesn't pull .o files from .a archives if the symbol that it
      requires is one which the .o file defines as a common symbol.
      (Common symbols are those declared without "extern"; the linker
      will merge together common symbols with the same name, so
      redeclaring the same variable in two compilation units results in
      them referring to the same symbol rather than a compilation error).
      
      This MacOSX difference from traditional linker behaviour means that
      "make check" produces link errors:
      
      Undefined symbols for architecture x86_64:
        "_cur_mon", referenced from:
            _error_vprintf in libqemuutil.a(qemu-error.o)
            _error_printf in libqemuutil.a(qemu-error.o)
            _error_printf_unless_qmp in libqemuutil.a(qemu-error.o)
            _error_print_loc in libqemuutil.a(qemu-error.o)
            _error_report in libqemuutil.a(qemu-error.o)
      ld: symbol(s) not found for architecture x86_64
      
      in this case because "cur_mon" is a common symbol in
      libqemustub.a(mon-set-error.o).
      
      In QEMU we don't make any use at all of the common symbol
      functionality, so we can avoid this problem entirely simply
      by compiling with -fno-common. Enable this option for all
      builds, not just MacOSX, so that if we ever inadvertently
      introduce multiple definitions of some variable that will
      be immediately spotted as a build error rather than only
      breaking the MacOSX build.
      Suggested-by: NMarkus Armbruster <armbru@redhat.com>
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Reviewed-by: NRichard Henderson <rth@twiddle.net>
      Message-id: 1393451610-24617-1-git-send-email-peter.maydell@linaro.org
      4c288acb
    • P
      configure: Make C++ test work with --enable-werror · 9c83ffd8
      Peter Maydell 提交于
      gcc's C++ compiler complains about being passed some -W options
      which make sense for C but not for C++. This means we mustn't try
      a C++ compile with QEMU_CFLAGS, but only with a filtered version
      that removes the offending options. This filtering was already being
      done for uses of C++ in the build itself, but was omitted for the
      "does C++ work?" configure test. This only showed up when doing
      builds which explicitly enabled -Werror with --enable-werror,
      because the "do the compilers work" tests were mistakenly placed
      above the "default werror based on whether compiling from git" code.
      Another error in this category is that clang warns if you ask it to
      compile C++ code from a file named "foo.c". Further, because we
      were running do_cc in a subshell in the condition part of an "if",
      the error_exit inside do_compiler wouldn't terminate configure and
      we would plunge on regardless. Fix this complex of errors:
      
      1. Move the default-werror code up so that there are no invocations
      of compile_object and friends between it and the point where we
      set $werror explicitly based on the --enable-werror command line
      option.
      
      2. Provide a mechanism for filtering QEMU_CFLAGS to create
      QEMU_CXXFLAGS, and use it for the test we run here.
      
      3. Provide a do_cxx function to run a test with the C++ compiler
      rather than doing cute tricks with subshells and do_cc.
      
      4. Use a new temporary file TMPCXX for the C++ program fragment.
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      Message-id: 1393352869-22257-1-git-send-email-peter.maydell@linaro.org
      Tested-by: NAndreas Färber <afaerber@suse.de>
      9c83ffd8
  18. 05 3月, 2014 1 次提交
    • D
      ui/sdl2 : initial port to SDL 2.0 (v2.0) · 47c03744
      Dave Airlie 提交于
      I've ported the SDL1.2 code over, and rewritten it to use the SDL2 interface.
      
      The biggest changes were in the input handling, where SDL2 has done a major
      overhaul, and I've had to include a generated translation file to get from
      SDL2 codes back to qemu compatible ones. I'm still not sure how the keyboard
      layout code works in qemu, so there may be further work if someone can point
      me a test case that works with SDL1.2 and doesn't with SDL2.
      
      Some SDL env vars we used to set are no longer used by SDL2,
      Windows, OSX support is untested,
      
      I don't think we can link to SDL1.2 and SDL2 at the same time, so I felt
      using --with-sdlabi=2.0 to select the new code should be fine, like how
      gtk does it.
      
      v1.1: fix keys in text console
      v1.2: fix shutdown, cleanups a bit of code, support ARGB cursor
      
      v2.0: merge the SDL multihead patch into this, g_new the number of consoles
      needed, wrap DCL inside per-console structure.
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      
      Fixes & improvements by kraxel:
       * baum build fix
       * remove text console logic
       * adapt to new input core
       * codestyle fixups
      Signed-off-by: NGerd Hoffmann <kraxel@redhat.com>
      47c03744
  19. 01 3月, 2014 1 次提交
  20. 27 2月, 2014 1 次提交
  21. 26 2月, 2014 1 次提交
  22. 25 2月, 2014 1 次提交
    • V
      net: Disable netmap backend when not supported · 0a985b37
      Vincenzo Maffione 提交于
      This patch fixes configure so that the netmap backend is not compiled in if the
      host doesn't support an API version >= 11. A version upper bound (15) has been
      added so that the netmap API can be extended with some minor features without
      requiring QEMU code modifications.
      
      Moreover, some changes have been done to net/netmap.c in order to reflect the
      current netmap API/ABI (11).
      
      The NETMAP_WITH_LIBS macro makes possible to include some utilities (e.g.
      netmap ring macros, D(), RD() and other high level functions) through the netmap
      headers. In this way we get rid of the D and RD macro definitions in the QEMU
      code, and we open the way for further code simplifications that will be
      introduced by future patches.
      Signed-off-by: NVincenzo Maffione <v.maffione@gmail.com>
      Signed-off-by: NStefan Hajnoczi <stefanha@redhat.com>
      0a985b37
  23. 24 2月, 2014 1 次提交
  24. 22 2月, 2014 1 次提交
    • B
      quorum: Add quorum mechanism. · 95c6bff3
      Benoît Canet 提交于
      This patchset enables the core of the quorum mechanism.
      The num_children reads are compared to get the majority version and if this
      version exists more than threshold times the guest won't see the error at all.
      
      If a block is corrupted or if an error occurs during an IO or if the quorum
      cannot be established QMP events are used to report to the management.
      
      Use gnutls's SHA-256 to compare versions.
      
      --enable-quorum must be used to enable the feature.
      Signed-off-by: NBenoit Canet <benoit@irqsave.net>
      Reviewed-by: NMax Reitz <mreitz@redhat.com>
      Signed-off-by: NKevin Wolf <kwolf@redhat.com>
      95c6bff3
  25. 21 2月, 2014 1 次提交
  26. 20 2月, 2014 7 次提交
    • D
      configure: Disable libtool if -fPIE does not work with it (bug #1257099) · 66518bf6
      Don Slutz 提交于
      Adjust TMPO and added TMPB, TMPL, and TMPA.  libtool needs the names
      to be fixed (TMPB).
      
      Add new functions do_libtool and libtool_prog.
      
      Add check for broken gcc and libtool.
      Signed-off-by: NDon Slutz <dslutz@verizon.com>
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      66518bf6
    • F
      block: convert block drivers linked with libs to modules · d3399d7c
      Fam Zheng 提交于
      The converted block drivers are:
      
          curl
          iscsi
          rbd
          ssh
          glusterfs
      Signed-off-by: NFam Zheng <famz@redhat.com>
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      d3399d7c
    • F
      module: implement module loading · e26110cf
      Fam Zheng 提交于
      This patch adds loading, stamp checking and initialization of modules.
      
      The init function of dynamic module is no longer directly called as
      __attribute__((constructor)) in static linked version, it is called
      only after passed the checking of presense of stamp symbol:
      
          qemu_stamp_$RELEASEHASH
      
      where $RELEASEHASH is generated by hashing version strings and content
      of configure script.
      
      With this, modules built from a different tree/version/configure will
      not be loaded.
      
      The module loading code requires gmodule-2.0.
      
      Modules are searched under
       - CONFIG_MODDIR
       - executable folder (to allow running qemu-{img,io} in the build
         directory)
       - ../ of executable folder (to allow running system emulator in the
         build directory)
      
      Modules are linked under their subdir respectively, then copied to top
      level of build directory for above convinience, e.g.:
          $(BUILD_DIR)/block/curl.so -> $(BUILD_DIR)/block-curl.so
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: NFam Zheng <famz@redhat.com>
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      e26110cf
    • F
      rules.mak: introduce DSO rules · 17969268
      Fam Zheng 提交于
      Add necessary rules and flags for shared object generation.
      The new rules introduced here are:
      
      1) %.o in $(common-obj-m) is compiled to %.o, then linked to %.so.
      
      2) %.mo in $(common-obj-m) is the placeholder for %.so for pattern
      matching in Makefile. It's linked to "-shared" with all its dependencies
      (multiple *.o) as input. Which means the list of depended objects must
      be specified in each sub-Makefile.objs:
      
          foo.mo-objs := bar.o baz.o qux.o
      
      in the same style with foo.o-cflags and foo.o-libs. The objects here
      will be prefixed with "$(obj)/" if it's a subdirectory Makefile.objs.
      
      3) For all files ending up in %.so, the following is added automatically:
      
          foo.o-cflags += -fPIC -DBUILD_DSO
      
      Also introduce --enable-modules in configure, the option will enable
      support of shared object build. Otherwise objects are static linked to
      executables.
      Signed-off-by: NFam Zheng <famz@redhat.com>
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      17969268
    • P
      darwin: do not use -mdynamic-no-pic · 13b6ce0e
      Paolo Bonzini 提交于
      While -mdynamic-no-pic can speed up the code somewhat, it is only used
      on the legacy PowerPC Mac OS X, and I am not sure if anyone is still
      testing that.  Disabling PIC can cause problems when enabling modules,
      so do not do that.
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: NFam Zheng <famz@redhat.com>
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      13b6ce0e
    • F
      block: use per-object cflags and libs · 6ebc91e5
      Fam Zheng 提交于
      No longer adds flags and libs for them to global variables, instead
      create config-host.mak variables like FOO_CFLAGS and FOO_LIBS, which is
      used as per object cflags and libs.
      
      This removes unwanted dependencies from libcacard.
      Signed-off-by: NFam Zheng <famz@redhat.com>
      [Split from Fam's patch to enable modules. - Paolo]
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      Signed-off-by: NFam Zheng <famz@redhat.com>
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      6ebc91e5
    • F
      rules.mak: fix $(obj) to a real relative path · ba1183da
      Fam Zheng 提交于
      Makefile.target includes rule.mak and unnested common-obj-y, then prefix
      them with '../', this will ignore object specific QEMU_CFLAGS in subdir
      Makefile.objs:
      
          $(obj)/curl.o: QEMU_CFLAGS += $(CURL_CFLAGS)
      
      Because $(obj) here is './block', instead of '../block'. This doesn't
      hurt compiling because we basically build all .o from top Makefile,
      before entering Makefile.target, but it will affact arriving per-object
      libs support.
      
      The starting point of $(obj) is passed in as argument of unnest-vars, as
      well as nested variables, so that different Makefiles can pass in a
      right value.
      Signed-off-by: NFam Zheng <famz@redhat.com>
      Signed-off-by: NPaolo Bonzini <pbonzini@redhat.com>
      ba1183da
  27. 19 2月, 2014 1 次提交
  28. 17 2月, 2014 1 次提交
    • B
      Fix QEMU build on OpenBSD on x86 archs · 46eef33b
      Brad 提交于
      This resolves the build issue with building the ROMs on OpenBSD on x86 archs.
      As of OpenBSD 5.3 the compiler builds PIE binaries by default and thus the
      whole OS/packages and so forth. The ROMs need to have PIE disabled.
      Check in configure whether the compiler supports the flags for disabling
      PIE, and if it does then use them for building the ROMs. This fixes the
      following buildbot failure:
      
      >From the OpenBSD buildbots..
        Building optionrom/multiboot.img
      ld: multiboot.o: relocation R_X86_64_16 can not be used when making a shared object; recompile with -fPIC
      
      Signed-off by: Brad Smith <brad@comstyle.com>
      Reviewed-by: NStefan Hajnoczi <stefanha@redhat.com>
      Signed-off-by: NPeter Maydell <peter.maydell@linaro.org>
      46eef33b
  29. 15 2月, 2014 1 次提交