Create hc-cpp.yml (#19)

* Create hc-cpp.yml

* update actions

* update actions

* update actions

* update actions

* update actions

* fix format string for VMX preemption timer dbg message
Fix compilation with BX_HAVE_XRANDR_H = 0: XRRQueryExtension is not available

* update actions

* add .conf.everything to testing

Co-authored-by: Stanislav Shwartsman <sshwarts@users.sourceforge.net>
This commit is contained in:
Stanislav Shwartsman 2022-07-27 01:26:55 +03:00 committed by GitHub
parent cac8d1486a
commit 430ba44b0e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 37 additions and 2 deletions

31
.github/workflows/hc-cpp.yml vendored Normal file
View File

@ -0,0 +1,31 @@
name: C/C++ CI
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: configure for release
run: cd bochs && ./.conf.linux
- name: make
run: make -C bochs
- name: cleanup
run: make -C bochs all-clean
- name: configure minimalistic configuration
run: cd bochs && ./.conf.nothing
- name: make
run: make -C bochs
- name: cleanup
run: make -C bochs all-clean
- name: configure maximum possible configuration
run: cd bochs && ./.conf.everything
- name: make
run: make -C bochs

View File

@ -1176,7 +1176,7 @@ void bx_local_apic_c::set_vmx_preemption_timer(Bit32u value)
vmx_preemption_timer_value = value;
vmx_preemption_timer_initial = bx_pc_system.time_ticks();
vmx_preemption_timer_fire = ((vmx_preemption_timer_initial >> vmx_preemption_timer_rate) + value) << vmx_preemption_timer_rate;
BX_DEBUG(("VMX Preemption timer: value = %u, rate = %u, init = %u, fire = %u", value, vmx_preemption_timer_rate, vmx_preemption_timer_initial, vmx_preemption_timer_fire));
BX_DEBUG(("VMX Preemption timer: value = %u, rate = %u, init = " FMT_LL "u, fire = " FMT_LL "u", value, vmx_preemption_timer_rate, vmx_preemption_timer_initial, vmx_preemption_timer_fire));
bx_pc_system.activate_timer_ticks(vmx_timer_handle, vmx_preemption_timer_fire - vmx_preemption_timer_initial, 0);
vmx_timer_active = 1;
}

View File

@ -925,6 +925,7 @@ void bx_x_gui_c::specific_init(int argc, char **argv, unsigned headerbar_y)
}
Window root = RootWindow(dpy, 0);
#if BX_HAVE_XRANDR_H
if (XRRQueryExtension(dpy, &event_base, &error_base)) {
int num_sizes;
Rotation original_rotation;
@ -935,7 +936,10 @@ void bx_x_gui_c::specific_init(int argc, char **argv, unsigned headerbar_y)
x11_max_xres = xrrs[original_size_id].width;
x11_max_yres = xrrs[original_size_id].height - bx_headerbar_y - bx_statusbar_y;
free(conf);
} else {
}
else
#endif
{
int screen = DefaultScreen(dpy);
x11_max_xres = DisplayWidth(dpy, screen);
x11_max_yres = DisplayHeight(dpy, screen) - bx_headerbar_y - bx_statusbar_y;