[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Makefile works in Ubuntu Maverick but not anymore in Ubuntu Natty
From: |
Victor henri |
Subject: |
Makefile works in Ubuntu Maverick but not anymore in Ubuntu Natty |
Date: |
Tue, 7 Jun 2011 01:16:10 +0200 |
Hello
I have a problem with my automake generated Makefile : what worked perfectly on
Ubuntu Maverick 10.10 doesn't work anymore on Ubuntu Natty 11.04. My program
displays harmonics of the sound in Ubuntu Linux, using Gstreamer, SDL, OpenGL
an Gtk; it uses Jack, and geis (and libbamf) for multitouch input
1. on Ubuntu Maverick 10.10, everything was just fine : it compiles and works
perfectly;
2. on Ubuntu Natty (the latest version untill now) with exactly the same
'configure.ac' and 'makefiles.am' files (everything, including the sources
files, is exacltly the same): it compiles good, but does not work at all;
however, when I compile without a makefile (as I used to do before), with the
following line :
gcc -Wall display.c events.c geis.c main.c mainwindow.c menu.c onclick.c
scale.c testrtpool.c -o spectrum3d `pkg-config jack gstreamer-0.10 gtk+-2.0
libbamf --libs --cflags` -lSDL -lSDL_ttf -lGL -lGLU -lutouch-geis
it works perfectly on Natty!!! I don't have a clue why...
This is my configure.ac :
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
############### INITIALIZE EVERYTHING ######################
AC_PREREQ([2.67])
AC_INIT([spectrum3d],
[0.2.3],
address@hidden,
[spectrum3d])
AC_CONFIG_SRCDIR([Makefile.am])
AM_INIT_AUTOMAKE([-Wall, -Werror])
AM_MAINTAINER_MODE
AC_PROG_CC
AM_PROG_CC_C_O
################ CREATE A CONFIG.H FILE #####################
> src/include.h
echo "/* This file was automatically generated by the 'configure' script */
#ifndef DEFINE_DEFINES
#define DEFINE_DEFINES
">> src/include.h
AC_ARG_ENABLE([jack], AS_HELP_STRING[--enable-jack], [
JACK=1
echo "#define JACK " >> src/include.h
jack="jack" ], [])
AC_ARG_ENABLE([geis], AS_HELP_STRING[--enable-jack], [
GEIS=1
echo "#define GEIS " >> src/include.h
geis="-lutouch-geis" ], [])
echo "
#endif " >> src/include.h
################# CHECK FOR LIBRAIRIES ######################
PKG_CHECK_MODULES([GTK], [gtk+-2.0], [], [])
PKG_CHECK_MODULES([GSTREAMER], [gstreamer-0.10], [], [])
AC_CHECK_LIB([SDL], [SDL_Init], [],[
echo "SDL library is required for this program"
exit -1])
AC_CHECK_LIB([SDL_ttf], [TTF_Init], [],[
echo "SDL_ttf library is required for this program"
exit -1])
AC_CHECK_LIB([GL], [glClear], [],[
echo "OpenGL(gl) library is required for this program"
exit -1])
AC_CHECK_LIB([GLU], [gluBeginCurve], [],[
echo "OpenGL(glu) library is required for this program"
exit -1])
if [[ $JACK ]]
then
AC_CHECK_LIB([jack], [jack_client_open], [],[
echo "Jack support is enabled but Jack library is not found. Please
install libjack."
exit -1])
fi
if [[ $GEIS ]]
then
AC_CHECK_LIB([utouch-geis], [geis_new], [],[
echo "Multitouch support is enabled but utouch-geis library is not
found. Please install libutouch-geis"
exit -1])
PKG_CHECK_MODULES([BAMF], [libbamf >= 0.2.53], [],[
echo "Multitouch support is enabled but libbamf library is not found.
Please install libbamf"
exit -1])
fi
##############################################################
AC_CONFIG_FILES([Makefile
src/Makefile
data/Makefile
data/spectrum3d.desktop
spectrum3d.pc])
#AC_CHECK_HEADERS([stdlib.h string.h])
# Checks for library functions.
#AC_CHECK_FUNCS([strtol])
AC_OUTPUT
This is the 'main' Makefile.am :
SUBDIRS = src data
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = spectrum3d.pc
#INCLUDES = $(top_srcdir)/include/
.PHONY: INSTALL
INSTALL:
$(INSTALL_CMD)
uninstall-hook:
rm -f $(HOME)/.spectrum3d.pref
and this is the Makefile.am from the src directory :
bin_PROGRAMS = spectrum3d
spectrum3d_CFLAGS = $(GSTREAMER_CFLAGS) $(GTK_CFLAGS) $(BAMF_CFLAGS)
spectrum3d_LDADD = $(GSTREAMER_LIBS) $(GTK_LIBS) $(BAMF_LIBS)
spectrum3d_SOURCES = display.c events.c geis.c main.c mainwindow.c menu.c
onclick.c scale.c testrtpool.c include.h display.h events.h geis.h main.h
mainwindow.h menu.h onclick.h scale.h testrtpool.h
Could please help to solve this issue...?
Thank you so much
Victor
- Makefile works in Ubuntu Maverick but not anymore in Ubuntu Natty,
Victor henri <=