Forum > IDE/CodeTools

Cross compile out of the box

(1/3) > >>

Trenatos:
I would love to see working cross compilation available out of the box.

I work mainly on a Mac, but my servers run Linux.

I've never gotten cross compilation to work, so right now I have to use a VM or go grab another machine just to compile for Windows and Linux, not a very good process.

It would also help when trying to convince management that we should try out FPC/Lazarus, any developer on any OS can create and compile the software that will run on various servers and user machines.

tudi_x:
what do you think about a DevOps layer with Bitbucket and Jenkins for CD/CI?
i think it is used even with Java for cross platform.

Phil:

--- Quote from: Trenatos on September 14, 2017, 03:41:56 pm ---I've never gotten cross compilation to work, so right now I have to use a VM or go grab another machine just to compile for Windows and Linux, not a very good process.

--- End quote ---

I've never quite understood the appeal of cross-compiling, since you still have to copy the resulting executable and any files it depends on at runtime to the target platform. I've always found it easier to just do what you do on my Mac: Ubuntu on VirtualBox (easy to copy files to Ubu from a shared Mac folder) and Windows on an AWS server (again, using a shared folder to copy files).

Trenatos:
I'm using Brook framework to write APIs.

I code and test locally on my Mac, then it's time to get it onto the linux server.

With cross compile I can just compile and transfer the executable.

Without cross compile, I have to load up a vm, transfer the source files or use a linked folder, compile on the vm, then transfer files.

Which means I have to set up a whole VM, version control access, guest additions, fix screen resolution issues, set up folder access, set up Lazarus with the packages I use for a second time.

Now rinse and repeat that once more for Windows.

Or I could cross compile.

That's what the appeal is.

Trying to convince others to develop server software using FPC?

Good luck once they hear about all the extra steps just because cross compilation doesn't work out of the box.

Phil:

--- Quote from: Trenatos on September 14, 2017, 04:10:09 pm ---Good luck once they hear about all the extra steps just because cross compilation doesn't work out of the box.

--- End quote ---

I assume you've tried to follow the instructions given here:

http://wiki.lazarus.freepascal.org/Cross_compiling

There's nothing out of the box about cross compiling.

Navigation

[0] Message Index

[#] Next page

Go to full version