我一直在嘗試使用automake將OpenGL SuperBible附帶到libtool庫中的GLTools庫。Automake Libtool'沒有規則制定目標'
我已經設置了autoconf和automake的,但是當涉及到實際構建庫,我得到:
$ make
make: *** No rule to make target `GLBatch.lo', needed by `libgltools.la'. Stop.
我搜索谷歌多達我的理智讓我拿出什麼,我是automake新手,所以我不太確定要搜索什麼。我相信這不是一個小錯誤,就是我錯過了一些根本性的東西。
這裏是我的Makefile.am:
ACLOCAL_AMFLAGS = -I m4
lib_LTLIBRARIES = libgltools.la
libgltools_la_SOURCES = GLBatch.cpp GLShaderManager.cpp GLTriangeBatch.cpp GLTools.cpp math3d.cpp glew.c
#libgltools_la_CFLAGS =
libgltools_la_LIBADD = -lX11 -lglut -lGL -lGLU -lm
include_HEADERS = GLBatchBase.h GLBatch.h GLFrame.h GLFrustum.h GLGeometryTransform.h GLMatrixStack.h GLShaderManager.h GLTools.h GLTriangleBatch.h math3d.h StopWatch.h GL/glew.h GL/glxew.h GL/wglew.h
EXTRA_DIST = autogen.sh
而且我configure.ac如果它的事項:
# -*- Autoconf -*-
# Process this file with autoconf to produce a configure script.
AC_PREREQ([2.67])
AC_INIT([libgltools.la], [0.1], [[email protected]])
AM_INIT_AUTOMAKE([libgltools.la], [0.1])
AC_PROG_LIBTOOL
AC_SUBST(LIBTOOL_DEPS)
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_SRCDIR([src/])
AC_CONFIG_HEADERS([include/config.h])
# Checks for programs.
AC_PROG_CXX
AC_PROG_CC
# Checks for libraries.
# FIXME: Replace `main' with a function in `-lGL':
AC_CHECK_LIB([GL], [main])
# FIXME: Replace `main' with a function in `-lGLU':
AC_CHECK_LIB([GLU], [main])
# FIXME: Replace `main' with a function in `-lX11':
AC_CHECK_LIB([X11], [main])
# FIXME: Replace `main' with a function in `-lglut':
AC_CHECK_LIB([glut], [main])
# FIXME: Replace `main' with a function in `-lm':
AC_CHECK_LIB([m], [main])
# Checks for header files.
AC_PATH_X
AC_CHECK_HEADERS([inttypes.h stddef.h stdint.h stdlib.h string.h sys/time.h unistd.h])
# Checks for typedefs, structures, and compiler characteristics.
AC_HEADER_STDBOOL
AC_C_INLINE
AC_TYPE_INT32_T
AC_TYPE_INT64_T
AC_TYPE_UINT64_T
AC_CHECK_TYPES([ptrdiff_t])
# Checks for library functions.
AC_HEADER_MAJOR
AC_FUNC_MALLOC
AC_CHECK_FUNCS([gettimeofday sqrt strchr strstr])
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
非常感謝。
你運行配置? – TJD
你在源代碼樹上運行'libtoolize'嗎? –
你的目錄中是否有'GLBatch.cpp'文件? – adl