Operating System - OpenVMS
1748201 Members
3020 Online
108759 Solutions
New Discussion юеВ

Re: Not able to compile linux code on OVMS 7.3.2

 
santosh b b
New Member

Not able to compile linux code on OVMS 7.3.2

Hi

I am porting an application from linux to OVMS7.3.2 alpha server.

Its a c++ code
I have header files included in the my source file as
#incldue "myInclude/myheader.h"


The cxx compiler errors out saying that "myInclude/myheader.h" not found. But I can see that the file exist there in that location, with permissions set properly.

I have included the paths properly in .mms file.

I am using the mmk utility.

I have also installed the GNV kit. But not of use

Can anyone please help me resolve this issue.

Thanks
Santosh.
6 REPLIES 6
Steven Schweda
Honored Contributor

Re: Not able to compile linux code on OVMS 7.3.2

1. Please learn how to ask a question. As
usual, showing actual commands with their
actual output can be more helpful than vague
descriptions and interpretations.

> [...] an application [...]

Which "an application"? Is this a secret?

> [...] c++ code [...]

cxx /version

> #incldue "myInclude/myheader.h"

Why are you hiding potentially useful
informatiuon?

> But I can see [...]

I can't. Perhaps you could show us exactly
what you see, and then we all could see it.

> I have included the paths properly in .mms
> file.

I can't see any of that, either. (And if you
knew what "properly" was, then you probably
wouldn't be asking this question here.)

> I am using the mmk utility.

Does that actually matter for this problem?

> Can anyone please help me resolve this
> issue.

(That's a question???)

Perhaps if you include even a little useful
information, like, say, the actual code, the
actual command(s), the actual error message,
and so on, then someone might be able to.
Hoff
Honored Contributor

Re: Not able to compile linux code on OVMS 7.3.2

Bad permissions don't return "not found", but rather return the OpenVMS equivalent of a no-permissions error.

GNV is only marginally related, and only if you're building within that environment.

MMK is also only marginally related, save for its use in reproducing the error.

If I've guessed at the question, please take the time to read the CXX user's guide and related parts of the manual and the HELP text:

HELP CXX /INCLUDE_DIRECTORY

My guess here is that the "myinclude" stuff isn't set up or isn't set up correctly, and that's covered in the help and the manuals.

If I've not guessed correctly, please post the versions and a concise reproducer and the compiler diagnostics that are encountered when you build the reproducer.

Also take the time to improve your own career prospects and your value to your project and your manager by reading and learning this:

http://www.catb.org/~esr/faqs/smart-questions.html
Alex Chupahin
Super Advisor

Re: Not able to compile linux code on OVMS 7.3.2

#incldue "myInclude/myheader.h"

This notation means that this include file should be in OpenVMS logical disk notation.

myInclude:myheader.h

If you not familiar with OpenVMS well,
shortly,
myInclude is a logical name of the path,
myheader.h is a file located in the path.

Example:
your include file myheader.h is located at
dka0:[project.files.myinclude]

you should:
$DEF myInclude dka0:[project.files.myinclude]
Then you may to be sure its ok:
$dir myInclude:myheader.h
The file should be present.

Then you can
#include
H.Becker
Honored Contributor

Re: Not able to compile linux code on OVMS 7.3.2

No logical needed, but if there is one, it should point to the right directory, except ...

$ sh sys/full/noproc
OpenVMS V7.3-2 on node KUCHL 14-APR-2010 09:15:38.27 Uptime 2 00:30:23
Digital Personal WorkStation
$ cxx/ver
HP C++ V7.1-015 for OpenVMS Alpha V7.3-2
$
$ ty f.cxx
#include "myinclude/include.h"
$
$ ty [.myinclude]include.h
int foo;
$
$ sh log myinclude
%SHOW-S-NOTRAN, no translation for logical name MYINCLUDE
$
$ cxx/prep=tt: f
#line 1 "SYS$SYSDEVICE:[HARTMUT]F.CXX;1"
#line 1 "SYS$SYSDEVICE:[HARTMUT.MYINCLUDE]INCLUDE.H;2"
int foo;
#line 2 "SYS$SYSDEVICE:[HARTMUT]F.CXX;1"
$
$ def myinclude huhu
$ cxx/prep=tt: f
#line 1 "SYS$SYSDEVICE:[HARTMUT]F.CXX;1"

#include "myinclude/include.h"
..............................^
%CXX-E-SRCFILNOOPEN, could not open source file "myinclude/include.h"
at line number 1 in file SYS$SYSDEVICE:[HARTMUT]F.CXX;1

%CXX-I-MESSAGE, 1 error detected in the compilation of "SYS$SYSDEVICE:[HARTMUT]F
.CXX;1".
$

PS: Translating a logical here is a CRTL feature. The behavior is influenced by the setting of the logical DECC$DISABLE_TO_VMS_LOGNAME_TRANSLATION (although the documentation indicates it isn't).
santosh b b
New Member

Re: Not able to compile linux code on OVMS 7.3.2

$ sh log openssl
"OPENSSL" = "DKA100:[SYS0.SYSMGR.SSSU_OVMS.CCB2.INCLUDE.OPENSSL.COMMON.OPENSSL]" (LNM$PROCESS_TABLE)
$

As my header files related to openssl is in that path.

but once i created the logical path and compiled I am getting the below error
---------------------------------------------------------------------
$ mmk
COPY CCB:[CCB]CCB.H CCB:[INCLUDE.OVMS-ALPHA]CCB.H
COPY VMS_SEMAPHORE.H CCB:[INCLUDE.OVMS-ALPHA]VMS_SEMAPHORE.H
CREATE/DIRE [.OVMS-ALPHA]
%CREATE-I-EXISTS, [.OVMS-ALPHA] already exists
OB := obj
CPPFLAGS := /OBJ=[.OVMS-ALPHA]/NODEBUG/NOOPTIMIZE/define=(_SOCKADDR_LEN,__VMS,__USE_STD_IOSTREAM,OPENSSL_NO_KRB5,SNIAHBALIB)
/STANDARD=GNU /NAMES=(UPPERCASE,SHORT) /NOWARNINGS /include=([],CCB:[CCB],CCB:[INCLUDE.OVMS-ALPHA],CCB:[INCLUDE.
OPENSSL.OVMS-ALPHA],CCB:[INCLUDE.OPENSSL.COMMON.openssl],CCB:[INCLUDE.OPENSSL.COMMON])
mmk/MACRO=(OB=obj) /DESCRIP=DESCRIP.MMS [--.LIB.OVMS-ALPHA]CCB2
CXX /exception /OBJ=[.OVMS-ALPHA]/NODEBUG/NOOPTIMIZE/DEFINE=(_SOCKADDR_LEN,__VMS,__USE_STD_IOSTREAM,OPENSSL_NO_KRB5,SNIAHBALI
B) /STANDARD=GNU /NAMES=(UPPERCASE,SHORT) /NOWARNINGS /INCLUDE=([],CCB:[CCB],CCB:[INCLUDE.OVMS-ALPHA],CCB:[INCLUDE.OPENSSL.OV
MS-ALPHA],CCB:[INCLUDE.OPENSSL.COMMON.OPENSSL],CCB:[INCLUDE.OPENSSL.COMMON]) BASE64.CPP/template_define=definition_file_type=
".cxx,.c,.cc"
Fatal: Insufficient virtual memory to continue compilation.
%LIB-F-INSVIRMEM, insufficient virtual memory
%MMK-F-ERRUPD, error status %X00158214 occurred when updating target [.OVMS-ALPHA]BASE64.OBJ
%MMK-F-ERRUPD, error status %X1C14803C occurred when updating target ALL
---------------------------------------------------------------------
My CXX version is
$ cxx/v
HP C++ V7.3-009 for OpenVMS Alpha V7.3-2
$
---------------------------------------------------------------------
Can anyone please correct me, where I am going wrong.

Thanks
santosh









Jansen_8
Regular Advisor

Re: Not able to compile linux code on OVMS 7.3.2

For Insufficient Virtual Memory check this first:

http://h71000.www7.hp.com/wizard/wiz_9565.html