Compiling Avogadro

Hi,

I would like to have two copies of Avogrado, a stable one for actual use and a development version in a local directory rather than /Applications on Mac OS X (or /usr/bin for a UNIX box). Is there a rule in the Makefile for doing this?

Thanks and Best Wishes,

Chris

If you compile Avogadro from sources and follow proposed procedure:
mkdir build
cmake …
make
use command
ccmake …

Than, set CMAKE_INSTALL_PREFIX variable in dialog, than press ‘c’ to configure and ‘g’ to generate makefiles. Than build Avogadro

27.10.09, 18:13, “Christopher Williams” christopherfwilliams@yahoo.co.uk:

Hi,
I would like to have two copies of Avogrado, a stable one for actual use and a development version in a local directory rather than /Applications on Mac OS X (or /usr/bin for a UNIX box). Is there a rule in the Makefile for doing this?
Thanks and Best Wishes,
Chris


Come build with us! The BlackBerry® Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference


Avogadro-devel mailing list
Avogadro-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/avogadro-devel


Regards,
Konstantin

Почта с приветом находится здесь: http://mail.yandex.ru/promo/new/cards

Christopher Williams wrote:

Hi,

I would like to have two copies of Avogrado, a stable one for actual use and a development version in a local directory rather than /Applications on Mac OS X (or /usr/bin for a UNIX box). Is there a rule in the Makefile for doing this?

Thanks and Best Wishes,

Chris

This is actually pretty easy. I did a lot of work on making Avogadro
relocatable independent of the prefix etc. So you should be able to run
a development version straight out of the build directory (no install
necessary), if this doesn’t work it is because I do not have access to a
Mac anymore and Macs have weird layouts in the build dir due to the .app
stuff). I could likely fix it up with a little debug help in trunk.

You can also move the /Applications/Avogadro.app to any directory and
run it from there (assuming everything I put in place for the Mac
bundles still woks - it definitely used to). You can of course set
CMAKE_INSTALL_PREFIX to something of your choosing too - that will cause
the make install step to put Avogadro wherever you like. So you should
be in good shape.

I develop mainly on Linux, but usually have a copy of the latest stable
release in /usr and then a development copy in my home directory that I
run out of the build location. To be honest, I have a Release build dir
and a full Debug build dir for when I need the symbols as well as the
stable copy.

If you have any questions please feel free to ask.

Marcus

It’s definitely something weird with regard to the directory layout.
If you try to run it out of the build directory it starts but gives a
gives a dialogue box with the message

No tools or engines loaded. It is unlikely this application will
function correctly. Please correct this error.

Looking in the Avogadro.app/Contents/ directory I find it has only the
directories:

Info.plist MacOS

as opposed to the working installed version which has:

Info.plist MacOS Resources include lib share

I tried moving the appropriate directories into the local version
manually but then it just quit unexpectedly on startup. Also if you
use the cmake command

-DCMAKE_INSTALL_PREFIX=/Users/Williams/Software/AvagadroClean/Test

then grepping in all files for ‘/Users/Williams/Software/AvagadroClean/
Test’ gives

AvogadroBuildSettings.cmake:SET(CMAKE_BUILD_SETTING_BUILD_TYPE “/Users/
Williams/Software/AvagadroClean/Test”)
CMakeCache.txt:CMAKE_BUILD_TYPE:STRING=/Users/Williams/Software/
AvagadroClean/Test
CMakeCache.txt:QT_QTTEST_INCLUDE_DIR:PATH=/Library/Frameworks/
QtTest.framework/Headers
CMakeCache.txt:QT_QTTEST_LIBRARY:STRING=optimized;/Library/Frameworks/
QtTest.framework;debug;/Library/Frameworks/QtTest.framework
CMakeCache.txt:QT_QTTEST_LIBRARY_RELEASE:FILEPATH=/Library/Frameworks/
QtTest.framework
CMakeCache.txt://Test COMPILES_WITHOUT_FPERMISSIVE
CMakeCache.txt://Test HAVE_GCC_VISIBILITY
cmake_install.cmake: SET(CMAKE_INSTALL_CONFIG_NAME “/Users/Williams/
Software/AvagadroClean/Test”)

but grepping for ‘/Applications/Avogadro.app/Contents’ gives

AvoCPackOptions.cmake:# New apple packaging stuff
AvogadroConfig.cmake:set(Avogadro_INSTALL_PREFIX “/Applications/
Avogadro.app/Contents”)
AvogadroConfig.cmake:set(Avogadro_INCLUDE_DIRS “/Applications/
Avogadro.app/Contents/include”)
AvogadroConfig.cmake:set(Avogadro_LIBRARY_DIRS “/Applications/
Avogadro.app/Contents/lib”)
AvogadroConfig.cmake:set(Avogadro_PLUGIN_DIR “/Applications/
Avogadro.app/Contents/lib/avogadro/1_1”)
AvogadroConfig.cmake:set(Avogadro_BIN_DIRS “/Applications/
Avogadro.app/Contents/bin”)
cmake_install.cmake: SET(CMAKE_INSTALL_PREFIX “/Applications/
Avogadro.app/Contents”)

Overall it looks like there’s some problems with the cmake scripts not
setting everything to the right value. What do you think is the best
way to proceed? If I manage to get the right directories in bin/
Avogadro.app/Contents/ in the build directory will everything be OK?

Chris

On Oct 27, 2009, at 6:36 PM, Marcus D. Hanwell wrote:

Christopher Williams wrote:

Hi,

I would like to have two copies of Avogrado, a stable one for
actual use and a development version in a local directory rather
than /Applications on Mac OS X (or /usr/bin for a UNIX box). Is
there a rule in the Makefile for doing this?

Thanks and Best Wishes,

Chris

This is actually pretty easy. I did a lot of work on making Avogadro
relocatable independent of the prefix etc. So you should be able to
run
a development version straight out of the build directory (no install
necessary), if this doesn’t work it is because I do not have access
to a
Mac anymore and Macs have weird layouts in the build dir due to
the .app
stuff). I could likely fix it up with a little debug help in trunk.

You can also move the /Applications/Avogadro.app to any directory and
run it from there (assuming everything I put in place for the Mac
bundles still woks - it definitely used to). You can of course set
CMAKE_INSTALL_PREFIX to something of your choosing too - that will
cause
the make install step to put Avogadro wherever you like. So you should
be in good shape.

I develop mainly on Linux, but usually have a copy of the latest
stable
release in /usr and then a development copy in my home directory
that I
run out of the build location. To be honest, I have a Release build
dir
and a full Debug build dir for when I need the symbols as well as the
stable copy.

If you have any questions please feel free to ask.

Marcus

Williams wrote:

It’s definitely something weird with regard to the directory layout.
If you try to run it out of the build directory it starts but gives a
gives a dialogue box with the message

No tools or engines loaded. It is unlikely this application will
function correctly. Please correct this error.

If you could run it from a shell compiled with debug output then it
should spit out the directories it is searching for plugins in. My guess
is that I broke the relative layout, and if you can copy and paste those
lines I should be able to get it fixed up.

Looking in the Avogadro.app/Contents/ directory I find it has only the
directories:

Info.plist MacOS

That is fine - there is logic in Avogadro to figure out it is in a build
directory, and use a different directory layout. All of the libs are in
the lib subdirectory of the build directory.

as opposed to the working installed version which has:

Info.plist MacOS Resources include lib share

I tried moving the appropriate directories into the local version
manually but then it just quit unexpectedly on startup. Also if you
use the cmake command

Not sure why it quit, but moving things around like that is unlikely to
work.

-DCMAKE_INSTALL_PREFIX=/Users/Williams/Software/AvagadroClean/Test

then grepping in all files for ‘/Users/Williams/Software/AvagadroClean/
Test’ gives

AvogadroBuildSettings.cmake:SET(CMAKE_BUILD_SETTING_BUILD_TYPE “/Users/
Williams/Software/AvagadroClean/Test”)
CMakeCache.txt:CMAKE_BUILD_TYPE:STRING=/Users/Williams/Software/
AvagadroClean/Test
CMakeCache.txt:QT_QTTEST_INCLUDE_DIR:PATH=/Library/Frameworks/
QtTest.framework/Headers
CMakeCache.txt:QT_QTTEST_LIBRARY:STRING=optimized;/Library/Frameworks/
QtTest.framework;debug;/Library/Frameworks/QtTest.framework
CMakeCache.txt:QT_QTTEST_LIBRARY_RELEASE:FILEPATH=/Library/Frameworks/
QtTest.framework
CMakeCache.txt://Test COMPILES_WITHOUT_FPERMISSIVE
CMakeCache.txt://Test HAVE_GCC_VISIBILITY
cmake_install.cmake: SET(CMAKE_INSTALL_CONFIG_NAME “/Users/Williams/
Software/AvagadroClean/Test”)

but grepping for ‘/Applications/Avogadro.app/Contents’ gives

AvoCPackOptions.cmake:# New apple packaging stuff
AvogadroConfig.cmake:set(Avogadro_INSTALL_PREFIX “/Applications/
Avogadro.app/Contents”)
AvogadroConfig.cmake:set(Avogadro_INCLUDE_DIRS “/Applications/
Avogadro.app/Contents/include”)
AvogadroConfig.cmake:set(Avogadro_LIBRARY_DIRS “/Applications/
Avogadro.app/Contents/lib”)
AvogadroConfig.cmake:set(Avogadro_PLUGIN_DIR “/Applications/
Avogadro.app/Contents/lib/avogadro/1_1”)
AvogadroConfig.cmake:set(Avogadro_BIN_DIRS “/Applications/
Avogadro.app/Contents/bin”)
cmake_install.cmake: SET(CMAKE_INSTALL_PREFIX “/Applications/
Avogadro.app/Contents”)

Overall it looks like there’s some problems with the cmake scripts not
setting everything to the right value. What do you think is the best
way to proceed? If I manage to get the right directories in bin/
Avogadro.app/Contents/ in the build directory will everything be OK?

Part of the problem is with caching - if you just try to change these
things and rerun cmake a lot of the variables are cached and will not be
changed. This is a bug I need to spend some time fixing. You need to
delete the CMakeCache.txt file in the build directory, or start with a
fresh build directory. That Mac has a different directory layout to the
other platforms, but I am 99% certain the installed Avogadro should work
without issue (this receives the most testing).

I think only a few people like me ran Avogadro from the command line. So
that may not work correctly. You would have to let me see the output
from Avogadro on the command line to see where it is searching for
things. I kept promising to make an extension that dumped this stuff to
a useful debug text file, but never found the time to do it.

You may have more success starting with a clean build directory with the
install prefix you would like to use. I worked quite hard to get
Avogadro on the Mac to just use a single app directory, before that it
was installing half its files into /usr/local… The released app runs
install_name_tool to give relative references to libraries, but this
step is quite slow. This allows the final app to be relocated, but that
final step is still quite clunky.

I hope this makes things a little clearer. There are still some issues
that need cleaning up, and I would like to fix the running from the
build dir on Mac if I can.

Marcus

From the command line it gives the following warnings about things
that it can’t find. (Sorry for the massive text dump… a lot of this
doesn’t really mean that much to me so it’s hard to tell what’s
important)

Chris

warning: Unable to read symbols for “QtOpenGL.framework/Versions/4/
QtOpenGL” (file not found).

warning: Unable to read symbols from “QtOpenGL” (not yet mapped into
memory).

warning: Unable to read symbols for “QtGui.framework/Versions/4/
QtGui” (file not found).

warning: Unable to read symbols from “QtGui” (not yet mapped into
memory).

warning: Unable to read symbols for “QtNetwork.framework/Versions/4/
QtNetwork” (file not found).

warning: Unable to read symbols from “QtNetwork” (not yet mapped into
memory).

warning: Unable to read symbols for “QtCore.framework/Versions/4/
QtCore” (file not found).

warning: Unable to read symbols from “QtCore” (not yet mapped into
memory).
Reading symbols for shared libraries .
warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/atom.o” - no debug information available for “atom.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/alias.o” - no debug information available for “alias.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/base.o” - no debug information available for “base.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/bitvec.o” - no debug information available for “bitvec.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/bond.o” - no debug information available for “bond.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/bondtyper.o” - no debug information available for
"bondtyper.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/canon.o” - no debug information available for “canon.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/builder.o” - no debug information available for “builder.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/chains.o” - no debug information available for “chains.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/chiral.o” - no debug information available for “chiral.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/data.o” - no debug information available for “data.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/descriptor.o” - no debug information available for
"descriptor.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/fingerprint.o” - no debug information available for
"fingerprint.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/forcefield.o” - no debug information available for
"forcefield.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/format.o” - no debug information available for “format.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/generic.o” - no debug information available for “generic.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/griddata.o” - no debug information available for
"griddata.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/grid.o” - no debug information available for “grid.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/locale.o” - no debug information available for “locale.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/kekulize.o” - no debug information available for
"kekulize.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/matrix.o” - no debug information available for “matrix.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/mol.o” - no debug information available for “mol.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/molchrg.o” - no debug information available for “molchrg.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/obconversion.o” - no debug information available for
"obconversion.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/oberror.o” - no debug information available for “oberror.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/obiter.o” - no debug information available for “obiter.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/obmolecformat.o” - no debug information available for
"obmolecformat.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/obutil.o” - no debug information available for “obutil.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/op.o” - no debug information available for “op.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/ops.o” - no debug information available for “ops.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/parsmart.o” - no debug information available for
"parsmart.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/patty.o” - no debug information available for “patty.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/phmodel.o” - no debug information available for “phmodel.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/plugin.o” - no debug information available for “plugin.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/pointgroup.o” - no debug information available for
"pointgroup.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/rand.o” - no debug information available for “rand.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/residue.o” - no debug information available for “residue.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/ring.o” - no debug information available for “ring.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/rotor.o” - no debug information available for “rotor.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/rotamer.o” - no debug information available for “rotamer.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/tokenst.o” - no debug information available for “tokenst.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/typer.o” - no debug information available for “typer.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/transform.o” - no debug information available for
"transform.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/dlhandler_unix.o” - no debug information available for
"dlhandler_unix.cpp".

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libmath.a/matrix3x3.o” - no debug
information available for “matrix3x3.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libmath.a/spacegroup.o” - no debug
information available for “spacegroup.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libmath.a/transform3d.o” - no debug
information available for “transform3d.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libmath.a/vector3.o” - no debug information
available for “vector3.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libfingerprints.a/finger2.o” - no debug
information available for “finger2.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libfingerprints.a/finger3.o” - no debug
information available for “finger3.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libforcefields.a/forcefieldghemical.o” - no
debug information available for “forcefieldghemical.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libforcefields.a/forcefieldmmff94.o” - no
debug information available for “forcefieldmmff94.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libforcefields.a/forcefielduff.o” - no
debug information available for “forcefielduff.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libops.a/addpolarh.o” - no debug
information available for “addpolarh.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libops.a/fillUC.o” - no debug information
available for “fillUC.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libops.a/gen3d.o” - no debug information
available for “gen3d.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libops.a/loader.o” - no debug information
available for “loader.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libops.a/optransform.o” - no debug
information available for “optransform.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libdescriptors.a/cmpdfilter.o” - no debug
information available for “cmpdfilter.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libdescriptors.a/filters.o” - no debug
information available for “filters.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libdescriptors.a/groupcontrib.o” - no debug
information available for “groupcontrib.cpp”.

warning: Could not find object file “/Volumes/Home/ghutchis/Devel/ob22/
src/.libs/libopenbabel.lax/libdescriptors.a/smartsdescriptors.o” - no
debug information available for “smartsdescriptors.cpp”.

On Nov 1, 2009, at 5:43 PM, Marcus D. Hanwell wrote:

Williams wrote:

It’s definitely something weird with regard to the directory layout.
If you try to run it out of the build directory it starts but gives a
gives a dialogue box with the message

No tools or engines loaded. It is unlikely this application will
function correctly. Please correct this error.

If you could run it from a shell compiled with debug output then it
should spit out the directories it is searching for plugins in. My
guess
is that I broke the relative layout, and if you can copy and paste
those
lines I should be able to get it fixed up.

Looking in the Avogadro.app/Contents/ directory I find it has only
the
directories:

Info.plist MacOS

That is fine - there is logic in Avogadro to figure out it is in a
build
directory, and use a different directory layout. All of the libs are
in
the lib subdirectory of the build directory.

as opposed to the working installed version which has:

Info.plist MacOS Resources include lib share

I tried moving the appropriate directories into the local version
manually but then it just quit unexpectedly on startup. Also if you
use the cmake command

Not sure why it quit, but moving things around like that is unlikely
to
work.

-DCMAKE_INSTALL_PREFIX=/Users/Williams/Software/AvagadroClean/Test

then grepping in all files for ‘/Users/Williams/Software/
AvagadroClean/
Test’ gives

AvogadroBuildSettings.cmake:SET(CMAKE_BUILD_SETTING_BUILD_TYPE “/
Users/
Williams/Software/AvagadroClean/Test”)
CMakeCache.txt:CMAKE_BUILD_TYPE:STRING=/Users/Williams/Software/
AvagadroClean/Test
CMakeCache.txt:QT_QTTEST_INCLUDE_DIR:PATH=/Library/Frameworks/
QtTest.framework/Headers
CMakeCache.txt:QT_QTTEST_LIBRARY:STRING=optimized;/Library/
Frameworks/
QtTest.framework;debug;/Library/Frameworks/QtTest.framework
CMakeCache.txt:QT_QTTEST_LIBRARY_RELEASE:FILEPATH=/Library/
Frameworks/
QtTest.framework
CMakeCache.txt://Test COMPILES_WITHOUT_FPERMISSIVE
CMakeCache.txt://Test HAVE_GCC_VISIBILITY
cmake_install.cmake: SET(CMAKE_INSTALL_CONFIG_NAME “/Users/
Williams/
Software/AvagadroClean/Test”)

but grepping for ‘/Applications/Avogadro.app/Contents’ gives

AvoCPackOptions.cmake:# New apple packaging stuff
AvogadroConfig.cmake:set(Avogadro_INSTALL_PREFIX “/Applications/
Avogadro.app/Contents”)
AvogadroConfig.cmake:set(Avogadro_INCLUDE_DIRS “/Applications/
Avogadro.app/Contents/include”)
AvogadroConfig.cmake:set(Avogadro_LIBRARY_DIRS “/Applications/
Avogadro.app/Contents/lib”)
AvogadroConfig.cmake:set(Avogadro_PLUGIN_DIR “/Applications/
Avogadro.app/Contents/lib/avogadro/1_1”)
AvogadroConfig.cmake:set(Avogadro_BIN_DIRS “/Applications/
Avogadro.app/Contents/bin”)
cmake_install.cmake: SET(CMAKE_INSTALL_PREFIX “/Applications/
Avogadro.app/Contents”)

Overall it looks like there’s some problems with the cmake scripts
not
setting everything to the right value. What do you think is the best
way to proceed? If I manage to get the right directories in bin/
Avogadro.app/Contents/ in the build directory will everything be OK?

Part of the problem is with caching - if you just try to change these
things and rerun cmake a lot of the variables are cached and will
not be
changed. This is a bug I need to spend some time fixing. You need to
delete the CMakeCache.txt file in the build directory, or start with a
fresh build directory. That Mac has a different directory layout to
the
other platforms, but I am 99% certain the installed Avogadro should
work
without issue (this receives the most testing).

I think only a few people like me ran Avogadro from the command
line. So
that may not work correctly. You would have to let me see the output
from Avogadro on the command line to see where it is searching for
things. I kept promising to make an extension that dumped this stuff
to
a useful debug text file, but never found the time to do it.

You may have more success starting with a clean build directory with
the
install prefix you would like to use. I worked quite hard to get
Avogadro on the Mac to just use a single app directory, before that it
was installing half its files into /usr/local… The released app runs
install_name_tool to give relative references to libraries, but this
step is quite slow. This allows the final app to be relocated, but
that
final step is still quite clunky.

I hope this makes things a little clearer. There are still some issues
that need cleaning up, and I would like to fix the running from the
build dir on Mac if I can.

Marcus

On Nov 3, 2009, at 12:38 AM, Williams wrote:

From the command line it gives the following warnings about things
that it can’t find.

AFAIK, running Avogadro from the build directory on Mac doesn’t work.
I haven’t had time to work it out – I run “make install” and go for
coffee.

So in my case, I keep a stable copy of Avogadro-stable.app (you can
just rename the bundle) and install into Avogadro.app.

Alternatively, you can trust in the stable Mac nightly builds:
http://avogadro.openmolecules.net/nightly/mac/

Cheers,
-Geoff

Geoffrey Hutchison wrote:

On Nov 3, 2009, at 12:38 AM, Williams wrote:

From the command line it gives the following warnings about things
that it can’t find.

AFAIK, running Avogadro from the build directory on Mac doesn’t work.
I haven’t had time to work it out – I run “make install” and go for
coffee.

So in my case, I keep a stable copy of Avogadro-stable.app (you can
just rename the bundle) and install into Avogadro.app.

Alternatively, you can trust in the stable Mac nightly builds:
http://avogadro.openmolecules.net/nightly/mac/

Like I said - it was working. It may not now as I have no access to a
Mac. The output you sent was not the one I needed - I need the text from
a debug build of Avogadro run from a command line. It shouldn’t be hard
to fix, but without a machine to test it is obviously tougher. When I
did some work on the Mac I ran Avogadro out of the build directory
without installing it.

Marcus

Weirdly it didn’t give me any error when I ran it from the command
line using gdb, after compiling with debugger flags I did

cd build/bin/Avogadro.app/Contents/MacOS

gdb Avogadro

then it gave me the text I sent. Then I did

run

and it gave a bunch of stuff which all seemed like it was successful
the only thing relevant perhaps being

Searching for plugins in "/Users/Williams/Library/Application Support/
avogadro/1_1/Plugins/colors"
Searching for plugins in "/Users/Williams/Library/Application Support/
avogadro/1_1/Plugins/engines"
Searching for plugins in "/Users/Williams/Library/Application Support/
avogadro/1_1/Plugins/extensions"
Searching for plugins in "/Users/Williams/Library/Application Support/
avogadro/1_1/Plugins/tools"
Searching for plugins in “/Users/Williams/Library/Application Support/
avogadro/1_1/Plugins/contrib”

these directories apparently don’t exist.

Anyway. It works if I just rename the clean version and install when I
recompile, so hopefully I can start doing something a little more
interesting and (hopefully) useful now.

Thanks

Chris

On Nov 3, 2009, at 6:57 PM, Marcus D. Hanwell wrote:

Geoffrey Hutchison wrote:

On Nov 3, 2009, at 12:38 AM, Williams wrote:

From the command line it gives the following warnings about things
that it can’t find.

AFAIK, running Avogadro from the build directory on Mac doesn’t
work. I haven’t had time to work it out – I run “make install” and
go for coffee.

So in my case, I keep a stable copy of Avogadro-stable.app (you can
just rename the bundle) and install into Avogadro.app.

Alternatively, you can trust in the stable Mac nightly builds:
http://avogadro.openmolecules.net/nightly/mac/

Like I said - it was working. It may not now as I have no access
to a Mac. The output you sent was not the one I needed - I need the
text from a debug build of Avogadro run from a command line. It
shouldn’t be hard to fix, but without a machine to test it is
obviously tougher. When I did some work on the Mac I ran Avogadro
out of the build directory without installing it.

Marcus

That works for me. Maybe I’ll have a look at this in more detail when
I’m a bit more familiar with the code. I’m actually a bit new to
developing on a Mac. Is there such a thing as a good brief guide for
someone coming over from Linux? I know there’s all the Xcode
documentation, but that’s a bit dense.

Thanks

Chris

On Nov 3, 2009, at 11:25 AM, Geoffrey Hutchison wrote:

On Nov 3, 2009, at 12:38 AM, Williams wrote:

From the command line it gives the following warnings about things
that it can’t find.

AFAIK, running Avogadro from the build directory on Mac doesn’t
work. I haven’t had time to work it out – I run “make install” and
go for coffee.

So in my case, I keep a stable copy of Avogadro-stable.app (you can
just rename the bundle) and install into Avogadro.app.

Alternatively, you can trust in the stable Mac nightly builds:
http://avogadro.openmolecules.net/nightly/mac/

Cheers,
-Geoff