473,503 Members | 2,167 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

`mysql_config --...` does not work

Hello list

For some strange reason `mysql_config --...` does not work. If try something
like

gcc -o progname `mysql_config --cflags` progname.c `mysql_config --libs`

(NOTE: "/usr/local/mysql/bin" is in the PATH var, mysql_config works when
invoked)

the compiler does not find the header files and the libraries... if I execute
the command by hand and paste the output to the gcc/g++ command line it
works, but not with the quotes `mysql...`

I can't run by hand mysql_config and paste the output to the gcc statement
since it will be invoked from a Makefile, and don't want to paste the output
directly into the Makefile since linked libs could vary from one version of
mysql to another... what can I do? generated Makefile should work with any
linux system without changes

I need to have a distribution Makefile working for ANY possible version of
mysql and mysql_config `quoted` does not give the compiler the right
parameters (don't know why).

Is there some way to let the system (linux x86) find the libraries (.a)
*without moving* them to a standard lib path? /etc/ld.so.conf does not work
since libraries are static, not shared...

Am using qmake (Qt) to generate the Makefile and need to make something like

-------------------------------------
TEMPLATE = app
TARGET = myapp

SOURCES = app.cpp
HEADERS = app.h

INCLUDEPATH += `mysql_config --cflags`

CONFIG += qt thread warn_on release
LIBS += `mysql_config --libs` lpthread -ldl -lvoodoo2
-------------------------------------

I've created a library that manages all mysql stuff I need, so can't use mysql
stuff included with Qt 'cos should change all my sources from my applications
already working... necesarily have to use my lib and generate the right
makefiles with qmake...

HELP!!!
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/my***********...ie.nctu.edu.tw

Jul 19 '05 #1
0 1666

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
4838
by: Jonas | last post by:
This works fine in Win XP but does not work at all in Win 98. Private WithEvents objIExplorer As InternetExplorer I have to do it like this to get it to work in Win 98 Dim objIExplorer As...
0
678
by: Miguel Cardenas | last post by:
Hello list For some strange reason `mysql_config --...` does not work. If try something like gcc -o progname `mysql_config --cflags` progname.c `mysql_config --libs` (NOTE:...
5
3593
by: me | last post by:
I have a Class Library that contains a Form and several helper classes. A thread gets created that performs processing of data behind the scenes and the Form never gets displayed (it is for debug...
22
2569
by: Robert Bralic | last post by:
CAN anybody tell me any address where I can download some small(1000-2000) lines C++ proghram source. Or send me ,a small(1000-2000) lines C++ program source that I can compille with gpp under...
12
2916
by: Frank Hauptlorenz | last post by:
Hello Out there! I have a DB2 V7.2 Database (Fix11) on Win 2000 Professional. It was before a NT 4 based Domain - now it is a Win 2000 Domain. The database server is a domain member. Now...
0
1356
by: Dave Hammond | last post by:
I recently upgraded to mysql version 4.1.13 (server is SuSE linux 9.3) and attempted to re-install the Perl DBD::mysql module, which kept failing because it couldn't open /tmp/mysql.sock. After...
14
4814
by: Anoop | last post by:
Hi, I am new to this newsgroup and need help in the following questions. 1. I am workin' on a GUI application. Does C# provides Layout Managers the way Java does to design GUI? I know that it...
89
5948
by: Cuthbert | last post by:
After compiling the source code with gcc v.4.1.1, I got a warning message: "/tmp/ccixzSIL.o: In function 'main';ex.c: (.text+0x9a): warning: the 'gets' function is dangerous and should not be...
1
3845
by: Eric West | last post by:
Hello gurus of the internet- I'm trying to install PHP on a system with MySQL I've had success using MySQL which was installed via "yum install mysql" on my CentOS 4.3 system. My problem is...
14
3450
by: webEater | last post by:
I have a problem, it's not browser specific, and I don't get a solution. I have an (X)HTML document, I show you a part of it: .... <!--<div class="pad">--> <div id="eventImages"><img src=""...
0
7205
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
7093
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7287
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7353
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
5023
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4689
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3180
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
1
747
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
401
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.