04-25-2011
what is your input and expected output?
10 More Discussions You Might Find Interesting
1. Programming
Hi
I'm getting
ld: fatal: option -h and building a dynamic executable are incompatible
ld: fatal: Flags processing errors
When I run
ld -shared -L/usr/dt/lib -lDtSvc -o builtin.so Workspace.o
after running
gcc -fPIC -I/usr/X11R6/include -I/usr/dt/include -c Workspace.c
I'm... (6 Replies)
Discussion started by: laho
6 Replies
2. UNIX for Dummies Questions & Answers
Hi guys! I have a dummy question for u :p
I cant find a solution for these tascks...tried everything (i know :cool: ).
1 Issue the following command sleep 1000
Note that sleep 1000 waits 1000 seconds!!! You cannot do anything now!!!
2 Open another terminal window and enter the tty... (1 Reply)
Discussion started by: RomeO
1 Replies
3. Shell Programming and Scripting
I know that this has a bad title, but I'm not sure how to sum it up well.
(And I'm new to Linux in general, so please excuse any incorrect terminology :o)
Anyway, I'm trying to create a script that gets whatever folder you're in, and then does a command with that directory as an argument. I... (2 Replies)
Discussion started by: droppedonjapan
2 Replies
4. Shell Programming and Scripting
Trying to figure out why this works:
printpwd.pl
#!/usr/bin/perl
use CGI::Carp qw( fatalsToBrowser );
print "Content-type: text/html\n\n";
$A = system("pwd");
$A = `pwd`;
print "$A\n";
^^actually that works/breaks if that makes any sense.. i get the working directory twice but when... (5 Replies)
Discussion started by: phpfreak
5 Replies
5. Shell Programming and Scripting
Scenario:
I have two PCs (named as A & B) which would send some traps to my third PC (named as C).
In PC C, I have to write a shell script such that it should accept the datas from both the PC-A & B parallely.
So my question is, is it possible to have two different child threads/tasks... (2 Replies)
Discussion started by: nthiruvenkatam
2 Replies
6. Homework & Coursework Questions
1. Write a shell program which renames the current directory with the given file extension to another extension. The playoffs are given on the command line.
Example usage:
$ Rename txt doc
will be renamed:
aaa.txt in aaa.doc
Juhutxt in Juhudoc
...
* To solve, you can also help with... (5 Replies)
Discussion started by: eclip
5 Replies
7. Shell Programming and Scripting
shell=ksh,
How could I schedule tasks in shell script INSTEAD OF using the crontab -e functionality?
For example, I want a script to print "Hello World" every 10 seconds (i.e., INTERVAL = 10s) until external termination signal is triggered.
Thanks, (2 Replies)
Discussion started by: isaacniu
2 Replies
8. Homework & Coursework Questions
1. The problem statement, all variables and given/known data:
Hello!
I need help with this problem bash shell scripting that basically just reads the data in a tab delimited file and does the following below
1. Read in the data file Survey.txt and assign the column values to variables of... (6 Replies)
Discussion started by: jsmith6932
6 Replies
9. Shell Programming and Scripting
I have 2 txt files, 1.txt and 2.txt which contain the paths to files that need to be linked.
Example 1.txt:
/root/001/folder2/image4.nii.gz
/root/002/folder2/image4.nii.gz
Example 2.txt:
/root/001/folder2/image5.nii.gz
/root/002/folder2/image5.nii.gz
Each line represents images from... (7 Replies)
Discussion started by: LeftoverStew
7 Replies
10. Shell Programming and Scripting
Hello,
im having bash script with
while ***
command1 &&
command2 &&
command3 &&
done
i want to ask how i can prevent overloading server, by waiting untill all commands complete? any low resources intensive command like "wait" - i dont know if exist? (2 Replies)
Discussion started by: postcd
2 Replies
LEARN ABOUT SUSE
funinfoput
funinfoput(3) SAORD Documentation funinfoput(3)
NAME
FunInfoPut - put information into a Funtools struct
SYNOPSIS
#include <funtools.h>
int FunInfoPut(Fun fun, int type, char *addr, ...)
DESCRIPTION
The FunInfoPut() routine puts information into a Funtools structure. The first argument is the Fun handle from which information is to be
retrieved. After this first required argument comes a variable length list of pairs of arguments. Each pair consists of an integer repre-
senting the type of information to store and the address of the new information to store in the struct. The variable list is terminated by
a 0. The routine returns the number of put actions performed.
The full list of available information is described above with the FunInfoPut() routine. Although use of this routine is expected to be
uncommon, there is one important situation in which it plays an essential part: writing multiple extensions to a single output file.
For input, multiple extensions are handled by calling FunOpen() for each extension to be processed. When opening multiple inputs, it some-
times is the case that you will want to process them and then write them (including their header parameters) to a single output file. To
accomplish this, you open successive input extensions using FunOpen() and then call FunInfoPut() to set the Funtools reference handle of
the output file to that of the newly opened input extension:
/* open a new input extension */
ifun=FunOpen(tbuf, "r", NULL)) )
/* make the new extension the reference handle for the output file */
FunInfoPut(ofun, FUN_IFUN, &ifun, 0);
Resetting FUN_IFUN has same effect as when a funtools handle is passed as the final argument to FunOpen(). The state of the output file is
reset so that a new extension is ready to be written. Thus, the next I/O call on the output extension will output the header, as expected.
For example, in a binary table, after resetting FUN_IFUN you can then call FunColumnSelect() to select the columns for output. When you
then call FunImagePut() or <A HREF="./library.html#funtablerowput">FunTableRowPut(), a new extension will be written that contains the
header parameters from the reference extension. Remember to call FunFlush() to complete output of a given extension.
A complete example of this capability is given in the evcol example code. The central algorithm is:
o open the output file without a reference handle
o loop: open each input extension in turn
o set the reference handle for output to the newly opened input extension
o read the input rows or image and perform processing
o write new rows or image to the output file
o flush the output
o close input extension
o close output file
Note that FunFlush() is called after processing each input extension in order to ensure that the proper padding is written to the output
file. A call to FunFlush() also ensures that the extension header is written to the output file in the case where there are no rows to
output.
If you wish to output a new extension without using a Funtools reference handle, you can call FunInfoPut() to reset the FUN_OPS value
directly. For a binary table, you would then call FunColumnSelect() to set up the columns for this new extension.
/* reset the operations performed on this handle */
int ops=0;
FunInfoPut(ofun, FUN_OPS, &ops, 0);
FunColumnSelect(fun, sizeof(EvRec), NULL,
"MYCOL", "J", "w", FUN_OFFSET(Ev, mycol),
NULL);
Once the FUN_OPS variable has been reset, the next I/O call on the output extension will output the header, as expected.
SEE ALSO
See funtools(7) for a list of Funtools help pages
version 1.4.2 January 2, 2008 funinfoput(3)