I was installing this program: THERMUS, that, as i know should install fine. I/m installing this program through ubuntu console. But when i run make all i got this message:
make: ***No rule to make target '/main/TTMParticle.h', needed by 'BQConstrainQ.o'. Stop.
I know that it could be caused by the fact that file TTMParticle.h doesn't exist in /main/, but i checked - it's there.
Your environment variable THERMUS is not properly set. The build instructions mention:
3 . Set an environment variable `THERMUS' to point at the top-level
directory containing the THERMUS code
It does not mention that you have to do export THERMUS to make that variable available to other processes, like make, so you might have forgotten that -- or not have set THERMUS at all. Without actually having tried it, I think the fastest way to get rid of this message is to run make as follows:
THERMUS=.. make all
To track down the issue, check out the file functions/makefile where you problem occurs. It mentions:
SEP_CLASSESH = $(THERMUS)/main/TTMParticle.h \
and later contains the dependency
$(FNCSO): $(FNCSS) $(SEP_CLASSESH)
which is the line that causes the actual error, because
FNCSO = BQConstrainQ.o \
Related
I have a strange behavior on an embedded linux system. It is created from an image file and has been used on many system for about a year without any issues. But a new system that I installed just now fail to work.
I have an app that is started by one of the boot scripts, and is dependent on a library foo.so in a special path.
So the script sets LD_LIBRARY_PATH to foopath.
LD_LIBRARY_PATH=foopath \
foo.app
But after boot I can see that the app was never started and if I try to start it manually it complains that it can't find the library.
The strange thing is that I can get it to work by setting the same path again by just copying the path using the clipboard, like this:
$ echo $LD_LIBRARY_PATH
foopath
$ export LD_LIBRARY_PATH=foopath
After this my app will find the library and executes correct.
But if I reboot the system the problem is of course back again.
What could be wrong, and what can I do to solve the issue?
As seen in the comments I got it to work by changing my script like this, but I still can't understand why it works on some systems, but not all.
export LD_LIBRARY_PATH=foopath
foo.app
I'm following a tutorial to install a program on an RHEL environment and I've overcome some errors up until this point. I'm at the end of the installation process, attempting to confirm the validity through "make test", which returns the following error:
[user#localhost verilator-4.018]$ make test
Can't open perl script "/bin/verilator": No such file or directory
...
[Makefile:228: smoke-test] Error 10
I first checked to see if there was a verilator-4.018/bin/verilator file, which there was.
I then tried researching the error online and got a single result, where a user stated the issue could be solved by "Setting VERILATOR_ROOT to the root of your checkout", but I'm not too sure how to interpret this since I'm a beginner.
I tried setting as root:
[root#localhost verilator-4.018]# make test
But got the same error messages.
Also, please let me know how I can rephrase the title to make it more specific. I thought it was difficult to be specific about a question where I need interpretation help.
There is no /bin/verilator ... there is bin/verilator. But it's more tricky than that : The tests are done with test_regress/driver.pl, so "bin/verilator" is one level up.
Edit test_regress/driver.pl, line 782 to
my #cmdargs = ("perl", "$ENV{VERILATOR_ROOT}../bin/verilator",
... and the firsts tests can be run.
More bugs : "smoke-test" fails : Will use a file from the install destination. Please do # make install ... and the next tests can also be run.
Test result → make-test__result.txt https://www.dropbox.com/s/tebcqj7bl5dkzx8/make-test__result.txt?dl=0
Please notice the SYSTEMC settings. verilator was built with $ export SYSTEMC_INCLUDE=/usr/local/include/ && export SYSTEMC_LIBDIR=/usr/local/lib-linux64 && ./configure && make
SYSTEMC is required for the tests to pass. See verilator/README
I have a check for a header file in configure.ac in the source root
AC_CHECK_HEADER(log4c.h,
[],
[AC_MSG_ERROR([Couldn't find or include log4c.h])])
and I'd like to give different feedback on different platform to reflect different most straight forward ways of providing the header:
on Debian it should error with the message Couldn't find or include log4c.h. Install log4c using 'sudo apt-get install liblog4c-dev'
on OpenSUSE it should error with ... Install log4c using 'sudo yum install log4c-devel' (didn't research the package name, but you catch my drift)
on other systems (where I'm too lazy to research the package name) it should error with ... Install log4c by fetching ftp://.../log4c.tar.gz and installing with './configure && make && make install' in the source root
I
checked the AM_CONDITIONAL macro, but I don't get how to use it in configure.ac rather than in Makefile.am (as described in autoconf/automake: conditional compilation based on presence of library?)
found the tip to run esyscmd in stackoverflow.com/questions/4627900/m4-executing-a-shell-command, but adding esyscmd (/bin/echo abc) to configure.ac doesn't print anything when I run autoreconf --install --verbose --force.
Both answers describing the usage of conditional macros without the shell commands for the mentioned OS and links to predefined macros (like AC_CHECK_HEADER_DEBIAN, AC_CHECK_HEADER_SUSE, etc.) are appreciated.
The following configure.ac doesn't work:
AC_INIT([cndrvcups-common], [2.90], [krichter722#aol.de])
AC_CONFIG_MACRO_DIR([m4])
AM_INIT_AUTOMAKE([foreign -Wall subdir-objects])
AC_PROG_CC
AM_PROG_AR
AM_PROG_CC_C_O
AC_MSG_NOTICE([Hello, world.])
AC_INCLUDES_DEFAULT
AC_CHECK_HEADER(check.h,
[],
[
AS_IF (test "$(lsb_release -cs)" = "vivid", [echo aaaaaa], [echo bbbbbb])
])
LT_INIT # needs to be after AM_PROGS_AR
AC_CONFIG_HEADERS([config.h])
AC_CONFIG_FILES([Makefile])
AC_OUTPUT
because ./configure fails with
checking check.h usability... no
checking check.h presence... no
checking for check.h... no
./configure: line 4433: syntax error near unexpected token `;'
./configure: line 4433: ` if ; then :'
There's also ./configure: line 4427: #include: command not found which happens no matter whether AC_CHECK_HEADER is specified.
Your configure.ac is almost ok. The only problem is space between AS_IF and the parenthesis. No whitespace is allowed between a macro name and the opening parenthesis in m4 scripts. This is correct syntax:
AC_CHECK_HEADER(check.h,
[],
[
AS_IF(test "$(lsb_release -cs)" = "vivid", [echo aaaaaa], [echo bbbbbb])
])
If you are looking for a way to detect different distros look for example at configure.ac of cgmanager.
Update
I noticed one more problem in your configure.ac.
AC_INCLUDES_DEFAULT macro expands to a set of default includes and can't be used here. It is not needed also. It will be used by default in your AC_CHECK_HEADER macro, as you omit last parameter.
This is the cause of line 4427: #include: command not found error you mention.
Update to your comment
First of all, running a system command itself, like lsb_release is not portable. You should first check, for example with AC_CHECK_PROG, for its presence.
Regarding the syntax I would first get the output of the command using backticks: result=`lsb_release -cs` and later test resulting output: test "x$result" = "xvivid". x is needed to avoid problems with empty value in some shells.
At last, I have doubts whether configure script is a proper place for all this distro specific messages. You may consider placing it in the README file.
Avoid those system specific messages.
Print one message which allows people to figure out what package to install on their respective system, but avoid naming the system specific package names and system specific installation tools.
You will never be able to add messages for all systems, so it is better to go the part of the way which you know and let your users go the rest of the way because they know their systems better than you can.
The proper way would be to write a software package outside but called from your configure which, given a header filename, foo.pc filename, library name, etc. figures out how to install that on the respective system. Then let system specific maintainers fix that package, and call it from configure if it is installed, and issue a generic error message otherwise.
A portable shell script local to your software package might do the same job to some extent. You still have to maintain all the system specific parts for all possible systems, though.
Hmm... now that I am thinking about that, the idea appears not that bad. I might add such a script to some of the projects I maintain and see how it turns out in practical use.
I would still try to keep most of that logic outside configure, though.
Can't get Eclipse to build my NDK/JNI project. Eclipse, or ndk-build from a command prompt, both give following output:
/cygdrive/c/android-ndk-r8b/build/core/setup-app.mk:75: recipe for target `clean-installed-binaries' failed
make: *** [clean-installed-binaries] Error 6
What is "Error 6"? I can't find any doc on that anywhere. Helpfully, it doesn't say what the problem is, just giving the cryptic error code.
I found setup-app.mk and tried inserting something to echo the command it was executing, which was simply removing some files. I copied and pasted it to the command prompt and it worked fine on its own:
rm -f ./libs/armeabi/lib*.so ./libs/armeabi-v7a/lib*.so ./libs/mips/lib*.so ./libs/x86/lib*.so
Also tried inserting a "whoami" and it matched a whoami directly from the command prompt, so it's not acting as a different user with different permissions or something.
Been stuck on this for days. Can anyone help?
Rob.
PS. I'm finding Eclipse/NDK/JNI almost impossible to work with. It only seems to work for a week or two before falling in a heap again, seemingly with no change from me. This one is now unusable until I fix this error. I also have it installed on another machine, which is now also completely broken for completely different reasons. How does anyone work in this environment?
It's no miracle the actual command works: the error message comes from the make itself, which failed to generate the appropriate command!
Now what could have happened: most likely, you have some paths with spaces. Make sure that neigher eclipse, cygwin, project, workspace, nor ndk have spaces in their root paths.
Maybe, there is some problem with PATH. I refer to the environment variable in three environments: windows native, cygwin, and eclipse. Could it be that make you actually run is different from what you expect?
Note that you do not need cygwin to build with NDK 7 and higher, simply use ndk-build.cmd.
I am building a Linux system with cross-compiler using ptxdist. It allows me to configure Qt4 for installation and it builds and installs qt-everywhere-opensource-src-4.6.3 Ok. However, the qmake internal settings are screwed up and I don't know how to fix them.
When I run qmake -query I get:
me#ubuntu:~$ qmake -query
QT_INSTALL_PREFIX:/
QT_INSTALL_DATA:/
QT_INSTALL_DOCS://doc
QT_INSTALL_HEADERS://include
QT_INSTALL_LIBS://lib
QT_INSTALL_BINS://bin
QT_INSTALL_PLUGINS://plugins
QT_INSTALL_TRANSLATIONS://translations
QT_INSTALL_CONFIGURATION:/etc/xdg
QT_INSTALL_EXAMPLES://examples
QT_INSTALL_DEMOS://demos
QMAKE_MKSPECS://mkspecs
QMAKE_VERSION:2.01a
QT_VERSION:4.6.3
Through some research, it looks like this can be fixed by simply rebuilding Qt, but it's not fixing this problem. I dug into the build output a bit and it looks like the ./configure command for the Qt build has "-prefix /usr" so I don't know why this isn't being fixed.
I would like to fix these internal values manually if possible because the Qt build takes hours. Does anyone know how to do this?
At configure time these paths are hardcoded in 'src/corelib/global/qconfig.cpp', and end up hardcoded into qmake when it is built. They are also hardcoded into many other files, like all the .la and .pc files, not to mention the Makefile install rules.
The only way to fix this is to figure out why configure keeps screwing up the prefix. configure is a big shell script, so it's easy to see where $QT_INSTALL_PREFIX is assigned from the '-prefix' argument, and then the different checks that are done on it (like running it through 'config.tests/unix/makeabs'). Try putting print statements before/after $QT_INSTALL_PREFIX is changed, and you should be able to find out where the path gets screwed up.
Also, you don't have to wait for the full build to complete to tell if the prefix was set
correctly. After configure runs, take a look in 'src/corelib/global/qconfig.cpp' and see what 'qt_configure_prefix_path_str' is set to.
You can manually set these properties using
qmake -set VARIABLE VALUE
They are stored using QSettings, the Qt built-in persistent applications settings.
see Configuring qmake's Environment
Configure scripts can be fuzzy about slashes. Are you sure that the build prefix is /usr and not /usr/ .