Groups | Search | Server Info | Login | Register


Groups > comp.parallel.pvm > #17

Trying to compile my hello.c program in PVM

Newsgroups comp.parallel.pvm
Date 2015-06-30 10:21 -0700
Message-ID <ca38ecf9-c2fb-455c-a5ce-a9a7a05f9994@googlegroups.com> (permalink)
Subject Trying to compile my hello.c program in PVM
From David Hernández <davisoski@gmail.com>

Show all headers | View raw


Hi.

I have installed pvm using sudo apt-get install pvm following this link:
http://varuagdiary.blogspot.com.es/2011/06/installing-pvm-on-ubuntu-1010-64bit.html

so I have my pvm up and running correctly.

Later I have downloaded dist from: http://www.netlib.org/pvm3/pvm3.4.6.tgz

in /home/david

unpacking using tar -xvf pvm3.4.6.tgz which create a folder called pvm3

I have established this variables

export PVM_ROOT=/usr/lib/pvm3
export PVM_ARCH=LINUX64
PATH=$PVM_ROOT/bin:$PATH

and make

Everything seems to be ok

Now I create my first hello.c project in /home/david/hello.c

and trying to compile:

gcc hello.c -o hello  (FAILS)

gcc hello.c -o hello -lpvm3 (WORKS, but show Hello World, THIS IS NOT MINE)

gcc hello.c -o hello -I$PVM_ROOT/include -L$PVM_ROOT/lib/$PVM_ARCH -lpvm3 (WORKS, but show Hello World, THIS IS NOT MINE)

gcc hello.c -o hello -I$PVM_ROOT/include -L$PVM_ROOT/lib/$PVM_ARCH 
ERROR:
hello.c:(.text+0x9): undefined reference to `pvm_mytid'
hello.c:(.text+0x28): undefined reference to `pvm_exit'

hello.c

#include <stdio.h>
#include <pvm3.h>

int main()
{
  int mytid;

  mytid = pvm_mytid();
  printf("My TID is %d\n", mytid);
  pvm_exit();
  return 0;
}


I don't know what else to try.

Any help.

Thanks



PS: ubuntun 12.04 x64

Back to comp.parallel.pvm | Previous | Next | Find similar


Thread

Trying to compile my hello.c program in PVM David Hernández <davisoski@gmail.com> - 2015-06-30 10:21 -0700

csiph-web