Error building SDL2 from HG

Hey,
I clone SDL2 from hg with this command to my pc ( Ubuntu 12.10 ):
hg clone http://hg.libsdl.org/SDL?

This downloads everything successfully. But, according to the README file, I have to run ./autogen.sh before
./configure. I do this, however it can’t seem to find ‘autoconf’. Therefore, It’s impossible to configure and build.

How can I fix the problem??? Any help will be appreciated…

autoconf is part of GNU autotools, which you need make sure you have
installed. Simplest way under Ubuntu is run “sudo apt-get install
build-essential” to get the full set of basic compilation tools, and
then “sudo apt-get build-dep libsdl1.2” to install all of the extra
header packages required to build SDL.

Also, while the README says that you need to run autogen.sh, the SDL
guys do a pretty good job at keeping the configure script in hg
up-to-date, so you should be able to just run with that.On 5 February 2013 05:47, Aggelos Kolaitis wrote:

Hey,
I clone SDL2 from hg with this command to my pc ( Ubuntu 12.10 ):
hg clone http://hg.libsdl.org/SDL

This downloads everything successfully. But, according to the README file, I have to run ./autogen.sh before
./configure. I do this, however it can’t seem to find ‘autoconf’. Therefore, It’s impossible to configure and build.

How can I fix the problem??? Any help will be appreciated…


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

autoconf is part of GNU autotools, which you need make sure you have

installed. Simplest way under Ubuntu is run “sudo apt-get install
build-essential” to get the full set of basic compilation tools, and
then “sudo apt-get build-dep libsdl1.2” to install all of the extra
header packages required to build SDL.

Also, while the README says that you need to run autogen.sh, the SDL
guys do a pretty good job at keeping the configure script in hg
up-to-date, so you should be able to just run with that.

Well, I installed autoconf fine, ./autogen.sh executes successfully, but I keep getting the same error while running ./configure.?
NOTE: This is the part of the configure that prints the error.=========================================================
checking for gcc option to accept ISO C89… (cached) none needed
checking for g++… g++
checking whether we are using the GNU C++ compiler… yes
checking whether g++ accepts -g… yes
checking how to run the C++ preprocessor… g++ -E
checking for ld used by g++… /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld… yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries… yes
checking for g++ option to produce PIC… -fPIC -DPIC
checking if g++ PIC flag -fPIC -DPIC works… yes
checking if g++ static flag -static works… yes
checking if g++ supports -c -o file.o… yes
checking if g++ supports -c -o file.o… (cached) yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries… yes
checking dynamic linker characteristics… (cached) GNU/Linux ld.so
checking how to hardcode library paths into programs… immediate
checking for a BSD-compatible install… /usr/bin/install -c
checking whether make sets $(MAKE)… yes
checking for windres… no
configure: error:?
*** When building from Mercurial you should configure and build in a
? ? separate directory so you don’t clobber SDL_config.h, SDL_revision.h

zeus at andromeda:~/SDL$?

Did you consider building in a separate directory, as it says?

Make a directory (anywhere) and cd into it. Then run your /configure from there.

Jonny DOn Tue, Feb 5, 2013 at 9:08 AM, Aggelos Kolaitis wrote:

autoconf is part of GNU autotools, which you need make sure you have

installed. Simplest way under Ubuntu is run “sudo apt-get install
build-essential” to get the full set of basic compilation tools, and
then “sudo apt-get build-dep libsdl1.2” to install all of the extra
header packages required to build SDL.

Also, while the README says that you need to run autogen.sh, the SDL
guys do a pretty good job at keeping the configure script in hg
up-to-date, so you should be able to just run with that.

Well, I installed autoconf fine, ./autogen.sh executes successfully, but I
keep getting the same error while running ./configure.
NOTE: This is the part of the configure that prints the error.

checking for gcc option to accept ISO C89… (cached) none needed
checking for g++… g++
checking whether we are using the GNU C++ compiler… yes
checking whether g++ accepts -g… yes
checking how to run the C++ preprocessor… g++ -E
checking for ld used by g++… /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld… yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries…
yes
checking for g++ option to produce PIC… -fPIC -DPIC
checking if g++ PIC flag -fPIC -DPIC works… yes
checking if g++ static flag -static works… yes
checking if g++ supports -c -o file.o… yes
checking if g++ supports -c -o file.o… (cached) yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries…
yes
checking dynamic linker characteristics… (cached) GNU/Linux ld.so
checking how to hardcode library paths into programs… immediate
checking for a BSD-compatible install… /usr/bin/install -c
checking whether make sets $(MAKE)… yes
checking for windres… no
configure: error:
*** When building from Mercurial you should configure and build in a
separate directory so you don’t clobber SDL_config.h, SDL_revision.h

zeus at andromeda:~/SDL$


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Oh, yeah, do pretty much what it says -_-’ (though I never got that
working honestly, which is why I stick to the snapshots)

2013/2/5, Aggelos Kolaitis :>>autoconf is part of GNU autotools, which you need make sure you have

installed. Simplest way under Ubuntu is run “sudo apt-get install
build-essential” to get the full set of basic compilation tools, and
then “sudo apt-get build-dep libsdl1.2” to install all of the extra
header packages required to build SDL.

Also, while the README says that you need to run autogen.sh, the SDL
guys do a pretty good job at keeping the configure script in hg
up-to-date, so you should be able to just run with that.

Well, I installed autoconf fine, ./autogen.sh executes successfully, but I
keep getting the same error while running ./configure.
NOTE: This is the part of the configure that prints the error.

checking for gcc option to accept ISO C89… (cached) none needed
checking for g++… g++
checking whether we are using the GNU C++ compiler… yes
checking whether g++ accepts -g… yes
checking how to run the C++ preprocessor… g++ -E
checking for ld used by g++… /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld… yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries…
yes
checking for g++ option to produce PIC… -fPIC -DPIC
checking if g++ PIC flag -fPIC -DPIC works… yes
checking if g++ static flag -static works… yes
checking if g++ supports -c -o file.o… yes
checking if g++ supports -c -o file.o… (cached) yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries…
yes
checking dynamic linker characteristics… (cached) GNU/Linux ld.so
checking how to hardcode library paths into programs… immediate
checking for a BSD-compatible install… /usr/bin/install -c
checking whether make sets $(MAKE)… yes
checking for windres… no
configure: error:
*** When building from Mercurial you should configure and build in a
? ? separate directory so you don’t clobber SDL_config.h, SDL_revision.h

zeus at andromeda:~/SDL$


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

2013/2/5 Aggelos Kolaitis

autoconf is part of GNU autotools, which you need make sure you have

installed. Simplest way under Ubuntu is run “sudo apt-get install
build-essential” to get the full set of basic compilation tools, and
then “sudo apt-get build-dep libsdl1.2” to install all of the extra
header packages required to build SDL.

Also, while the README says that you need to run autogen.sh, the SDL
guys do a pretty good job at keeping the configure script in hg
up-to-date, so you should be able to just run with that.

Well, I installed autoconf fine, ./autogen.sh executes successfully, but I
keep getting the same error while running ./configure.
NOTE: This is the part of the configure that prints the error.

checking for gcc option to accept ISO C89… (cached) none needed
checking for g++… g++
checking whether we are using the GNU C++ compiler… yes
checking whether g++ accepts -g… yes
checking how to run the C++ preprocessor… g++ -E
checking for ld used by g++… /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld… yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries…
yes
checking for g++ option to produce PIC… -fPIC -DPIC
checking if g++ PIC flag -fPIC -DPIC works… yes
checking if g++ static flag -static works… yes
checking if g++ supports -c -o file.o… yes
checking if g++ supports -c -o file.o… (cached) yes
checking whether the g++ linker (/usr/bin/ld) supports shared libraries…
yes
checking dynamic linker characteristics… (cached) GNU/Linux ld.so
checking how to hardcode library paths into programs… immediate
checking for a BSD-compatible install… /usr/bin/install -c
checking whether make sets $(MAKE)… yes
checking for windres… no
configure: error:
*** When building from Mercurial you should configure and build in a
separate directory so you don’t clobber SDL_config.h, SDL_revision.h

zeus at andromeda:~/SDL$


SDL mailing list
SDL at lists.libsdl.org
http://lists.libsdl.org/listinfo.cgi/sdl-libsdl.org

Make a copy of SDL in a separate directory and remove the .hg folder from
it, that should do the trick. It’s not exactly out of source building, but
it’s easier to just get it working.–
Gabriel.