LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 09-08-2004, 09:33 AM   #1
MadCactus
Member
 
Registered: Jul 2003
Distribution: Slackware 9.1
Posts: 195

Rep: Reputation: 30
Help with variables in autoconf needed


Hi,

I'm having trouble getting CHECK_LIB to work with the following configure.in script:


Snip ...

Code:
# check for X:
AC_PATH_X

# linker flags for using with CHECK_LIB - checked library is appended automatically:
X_LDFLAGS="$X_LIBS -lX11 -lXmu -lXext -lXi"

GL_LDFLAGS="$X_LDFLAGS"

GLU_LDFLAGS="$GL_LDFLAGS -lGL"

GLUT_LDFLAGS="$GLU_LDFLAGS -lGLU"

AC_SUBST(X_LDFLAGS, $X_LDFLAGS)

AC_SUBST(GL_LDFLAGS, $GL_LDFLAGS)

AC_SUBST(GLU_LDFLAGS, $GLU_LDFLAGS)

AC_SUBST(GLUT_LDFLAGS, $GLUT_LDFLAGS)

# Checks for programs.
AC_PROG_CXX
AC_PROG_CC
AC_PROG_CC_C_O
AC_PROG_INSTALL

# Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS([stdlib.h unistd.h math.h GL/gl.h GL/glut.h])

# Checks for typedefs, structures, and compiler characteristics.
AC_HEADER_STDBOOL
		
# Check for libs:
AC_CHECK_LIB(GL, glVertex3f,
		   [],
		   AC_MSG_ERROR([*** libGL not found ***]),
		   $GL_LDFLAGS)

AC_CHECK_LIB(GLU, gluBeginCurve,
		   [],
		   AC_MSG_ERROR([*** libGLU not found ***]),
		   $GLU_LDFLAGS)

AC_CHECK_LIB(glut, glutMainLoop,
		   [],
		   AC_MSG_ERROR([*** libglut not found ***]),
		   $GLUT_LDFLAGS)
It throws a *** libGL not found *** error even though libGL exists and is in the path, and the flags are right. Any idea what i'm doing wrong? I thought it might be the variables, but just copying and pasting still doesn't work.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
autoconf 2.54 need HELP !! Baldrick65 Linux - Software 1 08-21-2003 07:56 AM
Shel scripting: variables pointing to variables and case Dark_Helmet Programming 5 06-08-2003 11:07 AM
autoconf 2.52 or 2.53 caleb Conectiva 14 10-08-2002 03:53 PM
Autoconf jISV Linux - Software 2 05-30-2002 01:45 AM
autoconf.h safrout Linux - Newbie 3 05-25-2002 04:48 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 09:14 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration