Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails to build on Debian GNU/kFreeBSD #1297

Closed
SDLBugzilla opened this issue Feb 10, 2021 · 0 comments
Closed

Fails to build on Debian GNU/kFreeBSD #1297

SDLBugzilla opened this issue Feb 10, 2021 · 0 comments

Comments

@SDLBugzilla
Copy link
Collaborator

SDLBugzilla commented Feb 10, 2021

This bug report was migrated from our old Bugzilla tracker.

These attachments are available in the static archive:

Reported in version: HG 2.0
Reported for operating system, platform: FreeBSD, x86_64

Comments on the original bug report:

On 2014-01-05 12:42:44 +0000, Felix Geyer wrote:

Created attachment 1514
SDL_cpuinfo.c build fix for kFreeBSD

Starting from version 2.0.1 libsdl fails to build on Debian GNU/kFreeBSD in SDL_cpuinfo.c.

GNU/kFreeBSD defines FreeBSD_kernel but not FreeBSD.
The #ifdef FreeBSD check should be extended for FreeBSD_kernel, see the attached patch.

Build log:
libtool: compile: gcc -g -O2 -fstack-protector --param=ssp-buffer-size=4 -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 -DUSING_GENERATED_CONFIG_H -Iinclude -I/«BUILDDIR»/libsdl2-2.0.1+dfsg1/include -mmmx -m3dnow -msse -msse2 -fvisibility=hidden -D_REENTRANT -I/usr/include/dbus-1.0 -I/usr/lib/x86_64-kfreebsd-gnu/dbus-1.0/include -DHAVE_USBHID_H -DUSBHID_NEW -D_REENTRANT -Wall -c /«BUILDDIR»/libsdl2-2.0.1+dfsg1/src/cpuinfo/SDL_cpuinfo.c -fPIC -DPIC -o build/.libs/SDL_cpuinfo.o
/«BUILDDIR»/libsdl2-2.0.1+dfsg1/src/cpuinfo/SDL_cpuinfo.c: In function 'SDL_GetSystemRAM':
/«BUILDDIR»/libsdl2-2.0.1+dfsg1/src/cpuinfo/SDL_cpuinfo.c:632:35: error: 'HW_MEMSIZE' undeclared (first use in this function)
int mib[2] = {CTL_HW, HW_MEMSIZE};
^
/«BUILDDIR»/libsdl2-2.0.1+dfsg1/src/cpuinfo/SDL_cpuinfo.c:632:35: note: each undeclared identifier is reported only once for each function it appears in
make[2]: *** [build/SDL_cpuinfo.lo] Error 1

On 2014-02-22 22:50:02 +0000, Ryan C. Gordon wrote:

Out of curiousity, is this the only patch needed to fix the build on Debian GNU/kFreeBSD?

--ryan.

On 2014-02-23 02:01:55 +0000, Sam Lantinga wrote:

Fixed, thanks!
https://hg.libsdl.org/SDL/rev/334257cd613d

On 2014-02-23 09:58:40 +0000, Felix Geyer wrote:

Thanks, this is the only change necessary to build on GNU/kFreeBSD.

On 2014-02-24 15:32:12 +0000, Ryan C. Gordon wrote:

(In reply to Felix Geyer from comment # 3)

Thanks, this is the only change necessary to build on GNU/kFreeBSD.

Cool, I'll add a GNU/kFreeBSD to the buildbot system then. :)

--ryan.

On 2014-02-24 16:54:32 +0000, Ryan C. Gordon wrote:

Cool, I'll add a GNU/kFreeBSD to the buildbot system then. :)

...and now I have: https://buildbot.libsdl.org/builders/sdl-kfreebsd-amd64

This will automatically build every new revision to SDL and email us if we break the build on this platform.

--ryan.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant