GFortran Module Must Be In A Separate File Only, Otherwise It Does Not Compile. Why?

I am wondering why if I place a GFortran module inside of the same file as the MAIN program it is not recognized by the compiler? I had to move it out into a separate file to be recognized. Then everything compiled. Thanls, - A.


Similar Content



Gfortran: Attribute That Requires Explicit Interface ???

Hi there,

Trying to compile a few Gfortran lines in Ubuntu 12.04 I get this error:

Quote:
lun = newunit(unit)
1
Error: Dummy argument 'unit' of procedure 'newunit' at (1) has an attribute that requires an explicit interface for this procedure
The number one in fact points to the word "unit" not "lun" in the terminal. It got left-shifted when posted.

The code itself:

Code:
program main
  INTEGER*4 counter,lun,unit
  REAL*8, parameter :: pi = 3.141592653589793
  unit = 10
  lun = newunit(unit)
  ...................  
end program main

What does it all mean and how shall I change the code to compile it without an error?

Thanks, - A.

How To Add .so File To The Makefile(LINUX)

I want to add a TBB dynamic library in Makefile.
I m using .libirml.so in the makefile. It shows the error like that:libirml.so.1 file not recognized: File format not recognized

How to proceed further TO finish the task?

Linux Kernel Module Installation And Other Questions Related To Kernel Module Install

I have installed Linux 3.5 kernel and have compiled e2fsprogs as well. I have my own version of ext3 file system - lets say it is myfs. I have compiled myfs as well. Now I have few questions:

1.How to insert myfs module and where? When I do modprobe myfs (.ko file) it says module not found. When I simply do insmod myfs.ko it works but I am not sure where is it putting the .ko file. Also the displays I have added (on mkdir call) are not showing up (kernel debug level is also set to 8) when I try to create a directory in mounted folder

Makefile in myfs directory looks like this:

KERNEL_TREE ?= /lib/modules/$(shell uname -r)/build
PWD := $(shell pwd)

obj-m := iext3.o

iext3-objs := balloc.o bitmap.o dir.o file.o fsync.o ialloc.o inode.o \
ioctl.o namei.o super.o symlink.o hash.o resize.o ext3_jbd.o \
xattr.o xattr_user.o xattr_trusted.o acl.o xattr_security.o icefs.o \
transaction.o commit.o recovery.o checkpoint.o revoke.o journal.o

all:
make -C $(KERNEL_TREE) M=$(PWD) modules

clean:
rm -rf *.o *~ core .depend .*.cmd *.ko *.mod.c .tmp_versions *.markers *.order *.symvers

and I am compiling myfs from my own directory: /home/myname/soft/myfs.

Also, I don't see any ext2/ext3/ext4 directories in /lib/modules/linuxversion/kernel/fs/ -- not sure if this is right or wrong.

2.Mount is working fine. I can see myfs is mounted on /dev/sda3 by doing df -a. When I unmount It says - umount: /home/..../mnt: not mounted and then if I do df -a the file system is unmounted. This is strange as its unmounting but still throwing error.

Some Background: Directory where I have everything: /home/soft myfs/ mye2fs/ Linux-3.5/ mnt/

Step1: cd Linux-3.5 --> 1) make 2) make modules 3) make modules_install 4) make install 5) reboot

Step2: compile myfs (my version of ext3) and insert the myfs kernel module --> cd myfs/ --> make --> insmod myfs.ko

Step3: compiled mye2fs for mkfs

Step4: use mye2fs to create myfilesystem on a device --> mount --> test printk statements put under myfs modules

.o: File Not Recognized: File Format Not Recognized When Compiling

Hello,

I am working on a board (sbc6000x with at91sam9261 micro, linux 2.6.24 to be precise) and having some fun making script i wanted to make real application.
The board is coming with a cross compilation toolchain. When trying to make a simple "hello world" executable to print on the terminal there is no problem.
I open my terminal, give the path of the compiler, cd into the folder where my .c file is and then i type :
Code:
arm-linux-gcc -o hello hello.c

Which create my executable "hello" and this one is working. But like i said, this program only played with the terminal.

The board is starting with a script calling another executable which use the lcd display, i have the source of this executable. My idea was to look at what was in the source of this application (lots of folders and files) in order to understand how it was working. I wanted to test the toolchain on the source (with the makefile) to see if i was able to generate an executable from a application with folderS/fileS but when i try to "make" it i have this error.

In my understanding this is an object file but aside from that i don't see why it would not works.

Thank you for your future answers !

Want To Update GCC And Gfortran As A Result

Code:
$ gfortran --version
GNU Fortran (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3

How can I upgrade gcc?

I've tried a few tricks, none worked so far.

Thanks, - Alex

How To Recover From A Botched Graphics Card Driver Install

OK,

Lastnight I decided to finally attempt to install the dedicated ATI/AMD Catylist drivers. After all I was successfull with the HP drivers, right...

No matter which grub selection I make, getting in is broken, except of course for the Windows XP Pro x64 entry, that works just fine. I'm here with you today, because of the Fedora 21 Live DVD, (slooooww).

Here is the drivers log file:

==========================================================
Supported adapter detected.
Check if system has the tools required for installation.
Uninstalling any previously installed drivers.
Unloading radeon module...
rmmod: ERROR: Module radeon is in use
Unloading drm module...
rmmod: ERROR: Module drm is in use by: ttm drm_kms_helper radeon
[Message] Kernel Module : Trying to install a precompiled kernel module.
[Message] Kernel Module : Precompiled kernel module version mismatched.
[Message] Kernel Module : Found kernel module build environment, generating kernel module now.
AMD kernel module generator version 2.1
doing Makefile based build for kernel 2.6.x and higher
rm -rf *.c *.h *.o *.ko *.a .??* *.symvers
make -C /lib/modules/3.18.3-201.fc21.x86_64/build SUBDIRS=/usr/lib/modules/fglrx/build_mod/2.6.x modules
make[1]: Entering directory '/usr/src/kernels/3.18.3-201.fc21.x86_64'
CC [M] /usr/lib/modules/fglrx/build_mod/2.6.x/firegl_public.o
/usr/lib/modules/fglrx/build_mod/2.6.x/firegl_public.c:6396:12: warning: ‘KCL_fpu_save_init’ defined but not used [-Wunused-function]
static int KCL_fpu_save_init(struct task_struct *tsk)
^
CC [M] /usr/lib/modules/fglrx/build_mod/2.6.x/kcl_acpi.o
/usr/lib/modules/fglrx/build_mod/2.6.x/kcl_acpi.c: In function ‘KCL_ACPI_Slot_No_Hotplug’:
/usr/lib/modules/fglrx/build_mod/2.6.x/kcl_acpi.c:845:21: error: ‘struct acpi_device_flags’ has no member named ‘no_hotplug’
tdev->flags.no_hotplug = true;
^
scripts/Makefile.build:257: recipe for target '/usr/lib/modules/fglrx/build_mod/2.6.x/kcl_acpi.o' failed
make[2]: *** [/usr/lib/modules/fglrx/build_mod/2.6.x/kcl_acpi.o] Error 1
Makefile:1385: recipe for target '_module_/usr/lib/modules/fglrx/build_mod/2.6.x' failed
make[1]: *** [_module_/usr/lib/modules/fglrx/build_mod/2.6.x] Error 2
make[1]: Leaving directory '/usr/src/kernels/3.18.3-201.fc21.x86_64'
Makefile:88: recipe for target 'kmod_build' failed
make: *** [kmod_build] Error 2
build failed with return value 2
[Error] Kernel Module : Failed to compile kernel module - please consult readme.
[Reboot] Kernel Module : dracut
==========================================================

I just rebooted without attempting to configure the card, as per the ATI/AMD warning stating that it's important to do so, because my thinking was derailed due to seeing errors, and the install program said I needed to reboot. Afterall, I just couln't believe that with a "Failed to compile kernel module" error, it would actually keep the changes I'd made, that surely Linux had a failsafe in place for such circumstances. In other words, I'm also a newbie, and just don't know how many hoops of fire one has to jump through to be at peace with linux.

Can anyone please help be get back into my install, I've already set up so many things, there's just got to be a way, right?


Thanks in Advance!


JustAnotherHuman

*** ERROR: PERL Module Apache::DBI Is Not Installed !

Hello,

I am configuring OCS Server using the following two documentations:

http://wiki.centos.org/HowTos/OCSNG
http://www.howtoforge.com/how-to-ins...-on-centos-5.5

Getting below error during installaton:

""Checking for DBI PERL module...
Found that PERL module DBI is available.
Checking for Apache:BI PERL module...
*** ERROR: PERL module Apache:BI is not installed !
Checking for DBD::mysql PERL module...
Found that PERL module DBD::mysql is available.
Checking for Compress::Zlib PERL module...
Found that PERL module Compress::Zlib is available.
Checking for XML::Simple PERL module...
Found that PERL module XML::Simple is available.
Checking for Net::IP PERL module...
Found that PERL module Net::IP is available.
*** ERROR: There is one or more required PERL modules missing on your computer !
Please, install missing PERL modules first.""

i have googled for the solution unsuccessfully.
please help me in installing the missing perl module.

thanks in advance..

--
Anil Anji

How To Know The Loading Sequence/time Of Modules During Boot?

Hello,
the "lsmod" give the list of the loaded modules/drivers.
How to know when was theier loading time (start/end) ?
Is there any existing log file where that information can be seen ?
For another topic, see http://www.linuxquestions.org/questi...ml#post5362257, I am thinking the unfinished loading of a specific module (ehci-pci or other pci driver) or the loading of a module before another one, could disturb the loading of a module e1000e during a cold boot.
Thanks a lot for any help.

Printing a bootchart? http://www.bootchart.org/images/bootchart.png
Something else?

Making Kickstart File Available On USB Drive?

The RHEL installation guide says:

The kickstart file should be on a
separate flash memory drive to the boot media.

Why is this?

If I want to have the minimal boot media, the kickstart file and the complete installation software on the same USB drive, is it not possible?

How do I point to the kickstart file on the USB drive if it has a file system and the kickstart file is not a raw copy but a file on the file system?

Dell C840 Now Recognizes Intel Pro Wireless 2200BG:Driver Install Question

O/s: Xandros 3.0.3 Business
Laptop: Dellc840
Given: Wireless card recognized by laptop and executable driver file sitting waiting for installation.

Question:When I click on the .exe file (driver file) it opens and installs somewhere that I can't find, even with the Tools - Find Files/Folders option using the *.inf file format as a search handle.
How do I control where this file opens to? If I could control where it opens to, I could then find it to install it for use.