Results 1 to 10 of 31

Thread: Problem with FreePascal + MacOS

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Quote Originally Posted by Relfos
    Also using {$APPTYPE GUI} does not work, my program still brings up a console when run.
    Do you know what is "Bundle" in MacOS X world?

    Quote Originally Posted by Relfos
    but even now I'm just compilling the hello world, that just uses a logger class and nothing else
    I think there is a problem with this "just hello world" and "just a logger class". Try to do something separately from your engine.

    [offtop]
    Quote Originally Posted by code_glitch
    hey, now I think of it, wasn't it you that uses Arch Andru? That part of your avatar looks familiar...
    Yes, I use ArchLinux x86_64 on my desktop and laptop.
    what your idle ram on those machines
    Desktop and laptop has 4GB, so I never checked how much free RAM I have
    [/offtop]
    Last edited by Andru; 02-02-2011 at 11:08 PM.

  2. #2
    Moving to Linux is not an option, actually this code already compiles on linux, this is a game engine that should run on all major operating systems, and only Mac is left now.
    I actually bought a Macbook just for this, it has all latest updates and such, and enough ram, and latest FPC installed.

    I don't know what a 'Bundle' is, I'll read about it, but for now just a simple console application should run.
    Tomorrow, I will try to create a application from scratch that reproduces the error, without using the engine.

  3. #3
    Quote Originally Posted by Relfos
    I don't know what a 'Bundle' is, I'll read about it, but for now just a simple console application should run.
    About "Bundle" I remembered because of your problem with "my program still brings up a console".

    Tomorrow, I will try to create a application from scratch that reproduces the error, without using the engine.
    Sometimes starting something from scratch is better then trying to modify something huge Good luck with your experiments.

  4. #4
    I'm having no luck finding what a bundle is. When I talked about that, was about the {$APPTYPE CONSOLE} and {$APPTYPE GUI}, I'm using the later, and from what I read it is supported on darwin, however, when I double click the executable, a console window opens.

    Another thing I remembered now, maybe I'm compiling for 64bits?
    All other ports I have done are 32bits, and the code itself uses lots of pointer hacks that would probably crash under 64bits.
    How to compile a 32bits application under snow leopard, is that even possible?
    Last edited by Relfos; 02-02-2011 at 11:48 PM.

  5. #5
    Passing the -Wb compiler switch will create a bundle
    Peregrinus, expectavi pedes meos in cymbalis
    Nullus norvegicorum sole urinat

  6. #6
    Co-Founder / PGD Elder WILL's Avatar
    Join Date
    Apr 2003
    Location
    Canada
    Posts
    6,107
    Blog Entries
    25
    By 'Bundle' I believe that he simply means the way an "App" is packaged...

    All those neat little App-like files that you just drag and drop into your Applications folder are really just fancy folders that contain files, yet act like an executable file. If you hold down the Option button while you right click on an "App" you'll see the option "Show Package Contents" to see the contents. If you select this you can go in and modify the contents. If your case add textures, audio files, etc...
    Jason McMillen
    Pascal Game Development
    Co-Founder





  7. #7
    I found the problem, guys.
    The problem is the unit cmem!
    I included it because I read that when using fpc threads we should include cthreads and cmem units as the first units in the program.
    But this breaks the program everywhere, things like SetLength fail, for example.
    FPC bug, or cmem is not needed anymore, or something else?

  8. #8
    Hm, I never used cmem, and my apps worked fine on Linux and MacOS X But if you need it, maybe you forgot that cmem unit should be the first unit in the uses clause?

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •