[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [open-cobol-list] Linux Mint Borked?
From: |
Michael Anderson |
Subject: |
Re: [open-cobol-list] Linux Mint Borked? |
Date: |
Wed, 03 Jul 2013 00:11:35 -0500 |
User-agent: |
Mozilla/5.0 (X11; Linux i686; rv:17.0) Gecko/20130623 Thunderbird/17.0.7 |
You could just compile all statically into one single executable file.
Unless you're working on a production project, and all libraries must be
properly installed, eg. /usr/local/lib and ld config, and so on...
production stuff!
Example of dev and test/research coding.......:
If C calling Cobol, then your C source file must have a 'main', if Cobol
calling C, your C source file must NOT have a 'main'
Try:
cobc -x sourcefile.cob sourcefile.c -o executable_program
To run:
./executable_program
That should work.
I can send example source files, Cobol calling C, where the C source
file contains multiple functions, and the Cobol source file makes calls
to all of'em.
Two source files, that compile an run on 32 bit Ubuntu 12.04, just like
the above cobc statement.
Let me know..... if ya wanna look at an example.
--
Mike.
On 07/02/2013 10:38 PM, Patrick wrote:
Hi Everyone
I need to copy a bunch of DVDs for my kids and Mint Linux is well suited
for this so I switched over from Trisquel(also based on Ubunutu).
I installed OC from the repos and I have not had trouble compiling
simple programs. However now that I am trying to mix C with Cobol,
things are going bad. After failing with the repo version, I purged it
and installed OC from source.
I have Brain's OCGTK example here and it compiled fine before. I even
made a little shell script to compile it before, so I am running the
exact same commands but I get this:
libcob: Cannot find module 'CBL_OC_G_SIGNAL_CONNECT'
I have also tried Brains cobpy and had similar issues.
I thought I'd try something simpler so I made a C program that calls
Cobol and a Cobol program that is linked and calling back too. It calls
into Cobol just fine and DISPLAY statements are printing but with this
little piece:
void nothing(){
printf("printf calling");
}
I can't call back into C from Cobol. I get this:
libcob: Cannot find module 'nothing'
I edited my /etc/ld.so.conf and I added /usr/local/lib.
I ran ldconfig as sudo
I have tried for a couple hours to solve this and I am out of ideas. Is
there something else I can try or should I just dump Mint?
Thanks for reading-Patrick
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:
Build for Windows Store.
http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
open-cobol-list mailing list
address@hidden
https://lists.sourceforge.net/lists/listinfo/open-cobol-list