Page 1 of 1

Makefile.am issue in makehuman/src

PostPosted: Fri May 23, 2008 10:11 am
by cmassaloux
Hi again,

Still on Ubuntu Feisty, gcc 4.1.2 (Ubuntu 4.1.2-0ubuntu4), Make 3.81

I tried to build makehuman from svn and got the following errors during the link stage:

Code: Select all
ImageListener.o: In function `ImageListener::showExpressions()':
/usr/local/src/makehuman/src/ImageListener.cpp:919: undefined reference to `ExpressionsPanel::ExpressionsPanel()'
/usr/local/src/makehuman/src/ImageListener.cpp:921: undefined reference to `ExpressionsPanel::createWidgets()'
ImageListener.o: In function `ImageListener::resetMeshExpressions()':
/usr/local/src/makehuman/src/ImageListener.cpp:1032: undefined reference to `typeinfo for ExpressionsTargetPanel'
ConsoleListener.o: In function `ConsoleListener::loadPoses(mhgui::Console&, std::basic_string<char, std::char_traits<char>, std::allocator<char> > const&)':
/usr/local/src/makehuman/src/ConsoleListener.cpp:601: undefined reference to `ExpressionsTargetPanel::calcSelectorValues()'
collect2: ld returned 1 exit status


After some look around, I think the pb is partly in the Makefile.am which doesn't declare properly the makehuman_SOURCES variable with all the necessary source files, and partly in src/ConsoleListener.cpp which needs a missing #include "ExpressionsTargetPanel.h".

I did a quick diff between the *.cpp & *.h files in the src/directory, and the makehuman_SOURCES file list, and added the missing cpp & h files in Makefile.am, except for the "FantasyBody" related files which seem to be not completely stabilized (don't compile).

I'm not sure if all the added files were actually needed, but now it works and the compilation/link is doing ok.

Here are the two patches provided by svn diff:

Code: Select all
Index: src/ConsoleListener.cpp
===================================================================
--- src/ConsoleListener.cpp     (rĂ©vision 489)
+++ src/ConsoleListener.cpp     (copie de travail)
@@ -45,6 +45,7 @@
 #include "FileTools.h"
 #include "CharacterSettingPanel.h"
 #include "ExpressionsConsts.h"
+#include "ExpressionsTargetPanel.h"

 #ifdef __APPLE__
   #include "FileTools.h" // Move this out when tested on Linux and WIN32 too!



Code: Select all
Index: src/Makefile.am
===================================================================
--- src/Makefile.am     (rĂ©vision 489)
+++ src/Makefile.am     (copie de travail)
@@ -99,8 +99,27 @@
        PosesBsPanelSelectionListener.cpp\
        PosesBsPanelSelectionListener.h\
        BsPanelSelectionListener.cpp\
-       BsPanelSelectionListener.h
-
+       BsPanelSelectionListener.h \
+       DialogListener.cpp\
+       DialogListener.h\
+       DialogPanel.cpp\
+       DialogPanel.h\
+       ExpressionsConsts.h\
+       ExpressionsImageListener.cpp\
+       ExpressionsImageListener.h\
+       ExpressionsPanel.cpp\
+       ExpressionsPanel.h\
+       ExpressionsPresetListener.cpp\
+       ExpressionsPresetListener.h\
+       ExpressionsSelectionListener.cpp\
+       ExpressionsSelectionListener.h\
+       ExpressionsSelectorListener.cpp\
+       ExpressionsSelectorListener.h\
+       ExpressionsTargetPanel.cpp\
+       ExpressionsTargetPanel.h\
+       ExpressionsUtil.cpp\
+       ExpressionsUtil.h
+
 makehuman_LDFLAGS =

 makehuman_LDADD = @PACKAGE_LIBS@\



Best regards and congrats for the amazing job done !

Christophe Massaloux
cmassaloux@free.fr