libolt
01-12-2007 21:20:52
CaseyB,
I have created some patches for the auto tools build system used by OgreAL on Linux and other Unix platforms.
The first issue I found when attempting to build OgreAL on Linux and FreeBSD is that it doesn't check that OIS is available via pkg-config. I added this to configure.ac.
The second issue is that none of the Demos link against OIS, which causes the build to fail.
The third issue is that the ManySource_Demo and PlayPen demo are not included in the build process.
The fourth issue is that each Demo's Listener.cpp is looking for OIS::numKeyboards when at least with the version of OIS included in Ubuntu 7.10 it is defined as OIS::numKeyBoards.
I have gone ahead and corrected all of these issues as well as added a Makefile.am to the ManySources_Demo and PlayPen directories so that they will build.
The following is the output of svn diff, which should include all of the above mentioned changes.
I hope this helps. If you want I can send you the diff file.
[edit]
I forgot to mention that 'make install' also fails with the following:
It seems that plugins.cfg.in and resources.cfg.in are missing and causing plugins.cfg and resources.cfg to not being properly generated. I haven't gotten around to looking into what is required for this yet.
[/edit]
I still am unable to get OgreAL to actually run (none of the demos work either) on any of my Linux or FreeBSD systems. They all give me the same error I posted in my last thread.
Cheers,
Mike
I have created some patches for the auto tools build system used by OgreAL on Linux and other Unix platforms.
The first issue I found when attempting to build OgreAL on Linux and FreeBSD is that it doesn't check that OIS is available via pkg-config. I added this to configure.ac.
The second issue is that none of the Demos link against OIS, which causes the build to fail.
The third issue is that the ManySource_Demo and PlayPen demo are not included in the build process.
The fourth issue is that each Demo's Listener.cpp is looking for OIS::numKeyboards when at least with the version of OIS included in Ubuntu 7.10 it is defined as OIS::numKeyBoards.
I have gone ahead and corrected all of these issues as well as added a Makefile.am to the ManySources_Demo and PlayPen directories so that they will build.
The following is the output of svn diff, which should include all of the above mentioned changes.
Index: configure.ac
===================================================================
--- configure.ac (revision 90)
+++ configure.ac (working copy)
@@ -24,6 +24,9 @@
dnl freealut requires openal
PKG_CHECK_MODULES(OPENAL, freealut)
+dnl The Demos require OIS
+PKG_CHECK_MODULES(OIS, OIS)
+
dnl You may want to export each var individually
AC_SUBST(OGREAL_CFLAGS,"$OGRE_CFLAGS $VORBIS_FLAGS $OPENAL_FLAGS")
AC_SUBST(OGREAL_LIBS, "$OGRE_LIBS $VORBIS_LIBS $OPENAL_LIBS")
@@ -41,7 +44,9 @@
Demos/Basic_Demo/Makefile \
Demos/Directional_Demo/Makefile \
Demos/Doppler_Demo/Makefile \
+ Demos/ManySources_Demo/Makefile \
Demos/MultiChannel_Demo/Makefile \
+ Demos/PlayPen/Makefile \
OgreAL.pc])
AC_OUTPUT
Index: Demos/Directional_Demo/Listener.cpp
===================================================================
--- Demos/Directional_Demo/Listener.cpp (revision 90)
+++ Demos/Directional_Demo/Listener.cpp (working copy)
@@ -40,7 +40,7 @@
mMouse = static_cast<OIS::Mouse*>(mInputManager->createInputObject(OIS::OISMouse, true));
mMouse->setEventCallback(this);
}
- if(mInputManager->numKeyboards() > 0)
+ if(mInputManager->numKeyBoards() > 0)
{
mKeyboard = static_cast<OIS::Keyboard*>(mInputManager->createInputObject(OIS::OISKeyboard, true));
mKeyboard->setEventCallback(this);
Index: Demos/Directional_Demo/Makefile.am
===================================================================
--- Demos/Directional_Demo/Makefile.am (revision 90)
+++ Demos/Directional_Demo/Makefile.am (working copy)
@@ -1,6 +1,6 @@
-INCLUDES= -I$(top_srcdir)/include $(OGREAL_CFLAGS)
+INCLUDES= -I$(top_srcdir)/include $(OGREAL_CFLAGS) $(OIS_CFLAGS)
demosdir= $(abs_top_builddir)/Demos/bin
demos_PROGRAMS= Directional
Directional_SOURCES= Listener.cpp Listener.h main.cpp OgreApp.cpp OgreApp.h
Directional_LDFLAGS= -L$(top_builddir)/src
-Directional_LDADD= -lOgreAL
+Directional_LDADD= -lOgreAL $(OIS_LIBS)
Index: Demos/Basic_Demo/Listener.cpp
===================================================================
--- Demos/Basic_Demo/Listener.cpp (revision 90)
+++ Demos/Basic_Demo/Listener.cpp (working copy)
@@ -38,7 +38,7 @@
mMouse = static_cast<OIS::Mouse*>(mInputManager->createInputObject(OIS::OISMouse, true));
mMouse->setEventCallback(this);
}
- if(mInputManager->numKeyboards() > 0)
+ if(mInputManager->numKeyBoards() > 0)
{
mKeyboard = static_cast<OIS::Keyboard*>(mInputManager->createInputObject(OIS::OISKeyboard, true));
mKeyboard->setEventCallback(this);
Index: Demos/Basic_Demo/Makefile.am
===================================================================
--- Demos/Basic_Demo/Makefile.am (revision 90)
+++ Demos/Basic_Demo/Makefile.am (working copy)
@@ -1,6 +1,6 @@
-INCLUDES= -I$(top_srcdir)/include $(OGREAL_CFLAGS)
+INCLUDES= -I$(top_srcdir)/include $(OGREAL_CFLAGS) $(OIS_CFLAGS)
demosdir= $(abs_top_builddir)/Demos/bin
demos_PROGRAMS= Basic
Basic_SOURCES= Listener.cpp Listener.h main.cpp OgreApp.cpp OgreApp.h
Basic_LDFLAGS= -L$(top_builddir)/src
-Basic_LDADD= -lOgreAL
+Basic_LDADD= -lOgreAL $(OIS_LIBS)
Index: Demos/MultiChannel_Demo/Listener.cpp
===================================================================
--- Demos/MultiChannel_Demo/Listener.cpp (revision 90)
+++ Demos/MultiChannel_Demo/Listener.cpp (working copy)
@@ -38,7 +38,7 @@
mMouse = static_cast<OIS::Mouse*>(mInputManager->createInputObject(OIS::OISMouse, true));
mMouse->setEventCallback(this);
}
- if(mInputManager->numKeyboards() > 0)
+ if(mInputManager->numKeyBoards() > 0)
{
mKeyboard = static_cast<OIS::Keyboard*>(mInputManager->createInputObject(OIS::OISKeyboard, true));
mKeyboard->setEventCallback(this);
Index: Demos/MultiChannel_Demo/Makefile.am
===================================================================
--- Demos/MultiChannel_Demo/Makefile.am (revision 90)
+++ Demos/MultiChannel_Demo/Makefile.am (working copy)
@@ -1,6 +1,6 @@
-INCLUDES= -I$(top_srcdir)/include $(OGREAL_CFLAGS)
+INCLUDES= -I$(top_srcdir)/include $(OGREAL_CFLAGS) $(OIS_CFLAGS)
demosdir= $(abs_top_builddir)/Demos/bin
demos_PROGRAMS= MultiChannel
MultiChannel_SOURCES= Listener.cpp Listener.h main.cpp OgreApp.cpp OgreApp.h
MultiChannel_LDFLAGS= -L$(top_builddir)/src
-MultiChannel_LDADD= -lOgreAL
+MultiChannel_LDADD= -lOgreAL $(OIS_LIBS)
Index: Demos/PlayPen/Listener.cpp
===================================================================
--- Demos/PlayPen/Listener.cpp (revision 90)
+++ Demos/PlayPen/Listener.cpp (working copy)
@@ -38,7 +38,7 @@
mMouse = static_cast<OIS::Mouse*>(mInputManager->createInputObject(OIS::OISMouse, true));
mMouse->setEventCallback(this);
}
- if(mInputManager->numKeyboards() > 0)
+ if(mInputManager->numKeyBoards() > 0)
{
mKeyboard = static_cast<OIS::Keyboard*>(mInputManager->createInputObject(OIS::OISKeyboard, true));
mKeyboard->setEventCallback(this);
Index: Demos/PlayPen/Makefile.am
===================================================================
--- Demos/PlayPen/Makefile.am (revision 0)
+++ Demos/PlayPen/Makefile.am (revision 0)
@@ -0,0 +1,6 @@
+INCLUDES= -I$(top_srcdir)/include $(OGREAL_CFLAGS) $(OIS_CFLAGS)
+demosdir= $(abs_top_builddir)/Demos/bin
+demos_PROGRAMS= PlayPen
+PlayPen_SOURCES= Listener.cpp Listener.h main.cpp OgreApp.cpp OgreApp.h
+PlayPen_LDFLAGS= -L$(top_builddir)/src
+PlayPen_LDADD= -lOgreAL $(OIS_LIBS)
Index: Demos/Doppler_Demo/Listener.cpp
===================================================================
--- Demos/Doppler_Demo/Listener.cpp (revision 90)
+++ Demos/Doppler_Demo/Listener.cpp (working copy)
@@ -123,7 +123,7 @@
mMouse = static_cast<OIS::Mouse*>(mInputManager->createInputObject(OIS::OISMouse, true));
mMouse->setEventCallback(this);
}
- if(mInputManager->numKeyboards() > 0)
+ if(mInputManager->numKeyBoards() > 0)
{
mKeyboard = static_cast<OIS::Keyboard*>(mInputManager->createInputObject(OIS::OISKeyboard, true));
mKeyboard->setEventCallback(this);
Index: Demos/Doppler_Demo/Makefile.am
===================================================================
--- Demos/Doppler_Demo/Makefile.am (revision 90)
+++ Demos/Doppler_Demo/Makefile.am (working copy)
@@ -1,6 +1,6 @@
-INCLUDES= -I$(top_srcdir)/include $(OGREAL_CFLAGS)
+INCLUDES= -I$(top_srcdir)/include $(OGREAL_CFLAGS) $(OIS_CFLAGS)
demosdir= $(abs_top_builddir)/Demos/bin
demos_PROGRAMS= Doppler
Doppler_SOURCES= Listener.cpp Listener.h main.cpp OgreApp.cpp OgreApp.h BetaGUI.h BetaGUI.cpp
Doppler_LDFLAGS= -L$(top_builddir)/src
-Doppler_LDADD= -lOgreAL
+Doppler_LDADD= -lOgreAL $(OIS_LIBS)
Index: Demos/Makefile.am
===================================================================
--- Demos/Makefile.am (revision 90)
+++ Demos/Makefile.am (working copy)
@@ -1,3 +1,3 @@
# EXTRA_DIST=Media
-SUBDIRS=bin Basic_Demo Directional_Demo Doppler_Demo MultiChannel_Demo
+SUBDIRS=bin Basic_Demo Directional_Demo Doppler_Demo ManySources_Demo MultiChannel_Demo PlayPen
Index: Demos/ManySources_Demo/Listener.cpp
===================================================================
--- Demos/ManySources_Demo/Listener.cpp (revision 90)
+++ Demos/ManySources_Demo/Listener.cpp (working copy)
@@ -38,7 +38,7 @@
mMouse = static_cast<OIS::Mouse*>(mInputManager->createInputObject(OIS::OISMouse, true));
mMouse->setEventCallback(this);
}
- if(mInputManager->numKeyboards() > 0)
+ if(mInputManager->numKeyBoards() > 0)
{
mKeyboard = static_cast<OIS::Keyboard*>(mInputManager->createInputObject(OIS::OISKeyboard, true));
mKeyboard->setEventCallback(this);
Index: Demos/ManySources_Demo/Makefile.am
===================================================================
--- Demos/ManySources_Demo/Makefile.am (revision 0)
+++ Demos/ManySources_Demo/Makefile.am (revision 0)
@@ -0,0 +1,6 @@
+INCLUDES= -I$(top_srcdir)/include $(OGREAL_CFLAGS) $(OIS_CFLAGS)
+demosdir= $(abs_top_builddir)/Demos/bin
+demos_PROGRAMS= ManySources
+ManySources_SOURCES= Listener.cpp Listener.h main.cpp OgreApp.cpp OgreApp.h
+ManySources_LDFLAGS= -L$(top_builddir)/src
+ManySources_LDADD= -lOgreAL $(OIS_LIBS)
I hope this helps. If you want I can send you the diff file.
[edit]
I forgot to mention that 'make install' also fails with the following:
make[2]: Nothing to be done for `install-data-am'.
make[2]: Leaving directory `/home/libolt/builds/ogreal/src'
make[1]: Leaving directory `/home/libolt/builds/ogreal/src'
Making install in Demos
make[1]: Entering directory `/home/libolt/builds/ogreal/Demos'
Making install in bin
make[2]: Entering directory `/home/libolt/builds/ogreal/Demos/bin'
make[3]: Entering directory `/home/libolt/builds/ogreal/Demos/bin'
make[3]: Nothing to be done for `install-exec-am'.
for i in plugins.cfg resources.cfg ; do \
sed -e "s,@OGRE_PLUGINDIR\@,/usr/local/lib/OGRE,g" -e "s,@OGREAL_MEDIADIR\@,../../Demos/Media,g" ./$i.in > $i.tmp && \
/usr/bin/install -c -m 644 $i.tmp $i && \
rm -f $i.tmp; \
done
sed: can't read ./plugins.cfg.in: No such file or directory
sed: can't read ./resources.cfg.in: No such file or directory
make[3]: *** [install-data-local] Error 2
make[3]: Leaving directory `/home/libolt/builds/ogreal/Demos/bin'
make[2]: *** [install-am] Error 2
make[2]: Leaving directory `/home/libolt/builds/ogreal/Demos/bin'
make[1]: *** [install-recursive] Error 1
make[1]: Leaving directory `/home/libolt/builds/ogreal/Demos'
make: *** [install-recursive] Error 1
It seems that plugins.cfg.in and resources.cfg.in are missing and causing plugins.cfg and resources.cfg to not being properly generated. I haven't gotten around to looking into what is required for this yet.
[/edit]
I still am unable to get OgreAL to actually run (none of the demos work either) on any of my Linux or FreeBSD systems. They all give me the same error I posted in my last thread.
Cheers,
Mike