Code Monkey home page Code Monkey logo

Comments (11)

shundhammer avatar shundhammer commented on May 12, 2024

Hm - that sounds like it cannot find the main() function, but it's there alright in src/main.cpp, and it's listed under SOURCES in src/src.pro .

You seem to be using Qt 4.8. The one time we did build it on MacOS X, we were using the latest Qt 5 for that platform. I don't think that this should make a difference, though. But if you have both Qt 4.8 and Qt 5.x installed, please make sure you are using it consistently: I.e., make sure you use the Qt 4.8 qmake when building with Qt 4.8, and the Qt 5.x qmake when building with Qt 5.x.

This should normally not make a difference, but every once in a while after some build step went horribly wrong, it helps to clean the build directory. The most thorough cleaning is this:

git clean -dfx

(there is also 'make clean' and 'make distclean' which are not quite as thorough)
Then rebuild competely:

qmake
make

I also checked StackOverflow, but all I came up with is people actually not having a main() function. But we do have one.

BTW this kind of thing is why I announced that this project is looking for a MacOS X platform container. Not sure if I can give you much more help here; I don't have access to such a machine, let alone the platform-specific expertise.

from qdirstat.

shundhammer avatar shundhammer commented on May 12, 2024

BTW did you manage to build any Qt application on that platform? Is the build environment (compiler, linker, Qt stuff) set up correctly?

https://github.com/shundhammer/qdirstat/blob/master/README.md#build-environment

from qdirstat.

anovstrup avatar anovstrup commented on May 12, 2024

I haven't used Qt at all before on this machine -- I just installed it with homebrew to build qdirstat. I uninstalled Qt 4 (brew uninstall qt), installed Qt 5 (brew install qt5 && brew link --force qt5), and tried again, with a similar result:

/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -headerpad_max_install_names -Wl,-syslibroot,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk -mmacosx-version-min=10.6 -o .app/Contents/MacOS/ -F/usr/local/Cellar/qt5/5.3.1/lib -framework QtGui -framework QtCore -framework OpenGL -framework AGL
Undefined symbols for architecture x86_64:
"_main", referenced from:
start in crt1.10.6.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[1]: *** [.app/Contents/MacOS] Error 1
make: *** [sub-scripts-make_first-ordered] Error 2

I'm not in a great position to dig much deeper myself -- hopefully someone will come along with some insight.

from qdirstat.

anovstrup avatar anovstrup commented on May 12, 2024

Oh, I also used git clean -dfx as you suggested. No effect.

from qdirstat.

shundhammer avatar shundhammer commented on May 12, 2024

Well, can you build any of the supplied Qt examples successfully?

from qdirstat.

shundhammer avatar shundhammer commented on May 12, 2024

See also
https://github.com/shundhammer/qdirstat/blob/master/README.md#build-environment

from qdirstat.

shundhammer avatar shundhammer commented on May 12, 2024

Please make sure you have a working Qt environment.

from qdirstat.

anovstrup avatar anovstrup commented on May 12, 2024

I wasn't able to resolve this issue. Can I suggest that you reopen it in case someone else ends up with the same problem and/or finds a solution?

I wasn't able to find the "supplied Qt examples" -- I'm not sure whether the homebrew package includes them. But I also haven't had a lot of time to look into it.

from qdirstat.

shundhammer avatar shundhammer commented on May 12, 2024

Having a working Qt build environment is a prerequesite. Sorry, but there is just no way I can maintain people's build and compile environments from remote. And there is a link to that calculator example in the README.md.

from qdirstat.

anovstrup avatar anovstrup commented on May 12, 2024

I fully understand that you can't be responsible for my build environment, and I'm not requesting that you do anything other than keeping the issue open until it's actually resolved.

Someone else with an OS X machine may run into the same issue and either figure out a solution or benefit from seeing the steps I tried. It will be harder for them to find the Issue if it's marked as closed.

from qdirstat.

shundhammer avatar shundhammer commented on May 12, 2024

Well, no. This issue tracker is about QDirStat problems, not a web site to educate the general public about how to set up a build system, even less so since it's not the primary target platform for this piece of software.

This issue tracker is is a working tool for the QDirStat developers. It needs to be clear which issues are open and ready to be worked on. I am not going to put up with ever-growing lists of unresolvable problems any more just to keep users happy who won't accept a qualified bug resolution by the developers.

The build instructions clearly pointed out from the very beginning that a working Qt environment is a prerequesite for building QDirStat. For the primary platforms (i.e., various flavour of Linux), people who want to try building it on their own can get by with very little know-how about how to build software and just follow the instructions, but for the exotic platforms people just need to have more expertise about it. If they don't and it doesn't work, that's just too bad, but it's clearly not the fault of QDirStat.

We've seen it build and run on MacOS X, so it is possible in general with the correct setup.

from qdirstat.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.