automake
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

cannot get the name of my app


From: Victor henri
Subject: cannot get the name of my app
Date: Thu, 19 May 2011 21:57:31 +0200

Hello

I'm starting to use the autotools; everything works fine, but the only thing I 
have a problem with is the name of my app. 

I'm on Ubuntu Linux  and I use libbamf to get the current active app name. It 
work with every running app, but not mine. It was working then not anymore. The 
name I had first was " ", then "spectrum3d" (that is the name of my app), then 
"Unnamed" now. I'm not sure if I have to write to the "autoconf" or "automake" 
list, since this seems linked together. I need to get the name of the running 
app dynamically.

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 INCLUDE.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([realtime], AS_HELP_STRING[--enable-jack], [
                REALTIME=1
                echo "#define REALTIME " >> src/include.h ], [])
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])
        

AC_OUTPUT

#######################

and the makefile.am files (there are 3 of them):

the MAIN ONE : 

SUBDIRS = src data

pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = spectrum3d.pc

.PHONY: INSTALL
INSTALL:
    $(INSTALL_CMD)

uninstall-hook:
    rm -f $(HOME)/.spectrum3d.pref

##########################

the SRC one : 


bin_PROGRAMS = spectrum3d

spectrum3d_CFLAGS = $(GSTREAMER_CFLAGS) $(GTK_CFLAGS) $(BAMF_CFLAGS)
spectrum3d_LDFLAGS = $(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

#############################

the DATA one :

## Process this file with automake to produce Makefile.in

svgicondir = $(datadir)/icons
dist_svgicon_DATA = spectrum3d.svg

gtk_update_icon_cache = gtk-update-icon-cache -f -t $(datadir)/icons

install-data-hook: update-icon-cache
uninstall-hook: update-icon-cache
update-icon-cache:
    @-if test -z "$(datadir)"; then \
        echo "Updating Gtk icon cache."; \
        $(gtk_update_icon_cache); \
    else \
        echo "*** Icon cache not updated.  After (un)install, run this:"; \
        echo "***   $(gtk_update_icon_cache)"; \
    fi

desktop_in_files= spectrum3d.desktop.in

desktop_files=$(desktop_in_files:.desktop.in=.desktop)

Applicationsdir = $(datadir)/applications
Applications_DATA = $(desktop_files)

DISTCLEANFILES = $(desktop_files)

fontsdir = $(datadir)/fonts
fonts_DATA = FreeSans.ttf


Would please someone have an idea on what I should do/add/change? thank you!!

Victor
                                          

reply via email to

[Prev in Thread] Current Thread [Next in Thread]