473,725 Members | 2,383 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

C header files--Urgent

Hi All,

I am very new to C language and I got really big assignment in my
work.I am wondering if anyone can help me.........I need to port
compiler from unix to windows and compiler is written partially in c
and partially in fortran. I guess i need to change host specific files
to make it working. I wonder if standard header files are going to
change in this case.my current windows compiler doesn't have
sys/resource.h but unix compiler does. shud i create one or talk to my
vendor about missing header file or i need to do some work around for
that part.

Also plz explain concept of header files in little details........ ..
Thanks!

Apr 11 '06 #1
8 2775
gi**********@gm ail.com wrote:
Hi All,

I am very new to C language and I got really big assignment in my
work.I am wondering if anyone can help me.........I need to port
compiler from unix to windows and compiler is written partially in c
and partially in fortran. I guess i need to change host specific files
to make it working. I wonder if standard header files are going to
change in this case.my current windows compiler doesn't have
sys/resource.h but unix compiler does. shud i create one or talk to my
vendor about missing header file or i need to do some work around for
that part.
sys/resource.h is not a Standard header so it is off-topic here.
Unless your vendor advertises the availablity of this header I doubt
they will be very responsive to your request. If resource.h declares
functions that are not implemented by your system it would do little
good to simply recreate the header on your target system. You might
want to look for an implementation for your target platform that does
provide the needed functions, otherwise you will probably need to
identify the ones it doesn't provide and write them yourself. If you
can identify the functionality that you need you may have better luck
in in group dedicated to windows programming.
Also plz explain concept of header files in little details........ ..


Hmm, you may be in over your head here...

Robert Gamble

Apr 11 '06 #2
In article <11************ **********@g10g 2000cwb.googleg roups.com>,
gi**********@gm ail.com <gi**********@g mail.com> wrote:
I am very new to C language and I got really big assignment in my
work.
"really big assignments" usually come along with reasonable timeframes
in which to research the technologies involved. They may be
time-sensitive, but not "Urgent".

If you have a "big assignment" that is also "Urgent" then
it is within your capabilities (that is, you have a reasonable
chance of success) -- or else it is not within your capabilities,
in which case it is not a "really big assignment" but rather
an "impossible assignment" for you. Which might make it urgent
for you, but not for -us-.

"really big assignment" together with not knowing fundamentals
of what you have to do tends to suggest either (1) homework; or
(2) that you volunteered for something over your head.

I am wondering if anyone can help me.........I need to port
compiler from unix to windows and compiler is written partially in c
and partially in fortran. I guess i need to change host specific files
to make it working.
And possibly *many* other things as well, depending on how portable
to software was in the first place. It might not even be possible
in the new system, as some capabilities the original system had
might not be present in the new one and it might not be practical
to implement them. And it might not be possible on the new system to
link routines from the supplied C compiler with routines from
the supplied Fortran compiler.

I wonder if standard header files are going to
change in this case.
Not in the way you mean. If they are standard header files then
they do whatever implementation magic is necessary to import
the standard functionality. The implementation magic varies from
system to system and even version to version, but the thing
about *standard* header files is that the functionality they
import is *standard* -- the same functionality on each system.
You don't care what the header files look like (they are not
necessarily even text files), you only care what functionality they
alow you.
my current windows compiler doesn't have
sys/resource.h but unix compiler does. shud i create one or talk to my
vendor about missing header file or i need to do some work around for
that part.
sys/resource.h is not a "standard header file" in any version of
the C language standard. It might be part of some -other- standard,
but not part of the -C- standard. Therefore you should not talk
talk to your vendor about the "missing header file" because it is
not "missing": it is simply not functionality that the second
operating system (Windows) happens to have. If your program depends
on that functionality, you are going to have to find a work around
or disable that part of the program or give up the project.

<off topic>
In some Unix systems, sys/resource.h is used to examine or
set resource limits (such as the maximum stack size). There is
no real need to -reduce- your resources for a compiler, and
the way that Windows controls resource limits is different enough
from Unix's that you would likely want some completely different
way of increasing the resources... modifying the "properties " of
the executable for example.
</off topic>

Also plz explain concept of header files in little details........ ..


Read any C manual. Read the comp.lang.c FAQ. Read the C language
standards themselves.
--
"It is important to remember that when it comes to law, computers
never make copies, only human beings make copies. Computers are given
commands, not permission. Only people can be given permission."
-- Brad Templeton
Apr 11 '06 #3
ro******@ibd.nr c-cnrc.gc.ca (Walter Roberson) writes:
In article <11************ **********@g10g 2000cwb.googleg roups.com>,
gi**********@gm ail.com <gi**********@g mail.com> wrote:

[...]
Also plz explain concept of header files in little details........ ..


Read any C manual. Read the comp.lang.c FAQ. Read the C language
standards themselves.


Read K&R2 (Kernighan & Ritchie, _The C Programming Language_, 2nd Edition).

--
Keith Thompson (The_Other_Keit h) ks***@mib.org <http://www.ghoti.net/~kst>
San Diego Supercomputer Center <*> <http://users.sdsc.edu/~kst>
We must do something. This is something. Therefore, we must do this.
Apr 11 '06 #4
gi**********@gm ail.com wrote:
I am very new to C language and I got really big assignment in my
work.I am wondering if anyone can help me.........I need to port
compiler from unix to windows and compiler is written partially in c
and partially in fortran.
wow. I think you need to go back and talk to your boss. This is a tough

assignment, probably for anyone. For someone with your level of
knowledge it sails close to the "impossible " region of the problem
space.

If you work for a commercial orgainisation perhaps an experienced
software engineer should be brought in from another part of your
organisation to review this project. It sounds like an excellent way to

spend a lot of money for no net result.

I'm not trying to be rude about you abilities but it seems clear you
know
little of C or programming in general or have the skills to rapidly
bootstrap
yourself into a new technology.

Still if it does sound like fun...

<snip>
Also plz explain concept of header files in little details........ ..


oh dear...
--
Nick Keighley

My god it's full of stars!
Dave Bowman, on seeing HAL's source code

Apr 11 '06 #5
<gi**********@g mail.com> wrote:
Hi All,

I am very new to C language and I got really big assignment in my
work.I am wondering if anyone can help me.........I need to port
compiler from unix to windows and compiler is written partially in c
and partially in fortran. I guess i need to change host specific files
to make it working. I wonder if standard header files are going to
change in this case.my current windows compiler doesn't have
sys/resource.h but unix compiler does. shud i create one or talk to my
vendor about missing header file or i need to do some work around for
that part.

Also plz explain concept of header files in little details........ ..
I am sorry, but you questions tell very clearly that this assignment
is well above you current skills. You sound like this, (from a
previous post of mine to comp.arch.embed ded):
--------------------------------------- Hi group!! I'm a surgeon and will
be performing open chest surgery
on one of my patients tomorrow.
I have a few questions:
What is an hemorrhage, when do
you use it?
What is a suture?
What is coagulation,
What is an antibiotic?
What is anesthesia, do you implant
it before or after the coagulation?
Where exactly is the heart?
Can you help me? Please email
the answer directly to the
operating room.

Yes, I am exaggerating.
No, I am not exaggerating a lot.---------------------------------------


I suggest to go back to your managers and request that they assign
somebody else to work together with you, somebody with more experience
on both the language and the target environment, or that they provide
you with adequate training before tackling the job.

Apr 11 '06 #6

"Nick Keighley" <ni************ ******@hotmail. com>
??????:11****** *************** @t31g2000cwb.go oglegroups.com. ..
gi**********@gm ail.com wrote:
I am very new to C language and I got really big assignment in my
work.I am wondering if anyone can help me.........I need to port
compiler from unix to windows and compiler is written partially in c
and partially in fortran.
wow. I think you need to go back and talk to your boss. This is a tough


I think so. If can not finished it on time,you'd better
to tell your boss. Oherwise, you may delay the schedule
of the whole project.
assignment, probably for anyone. For someone with your level of
knowledge it sails close to the "impossible " region of the problem
space.

If you work for a commercial orgainisation perhaps an experienced
software engineer should be brought in from another part of your
organisation to review this project. It sounds like an excellent way to

spend a lot of money for no net result.

I'm not trying to be rude about you abilities but it seems clear you
know
little of C or programming in general or have the skills to rapidly
bootstrap
yourself into a new technology.

Still if it does sound like fun...

<snip>
Also plz explain concept of header files in little details........ ..


oh dear...
--
Nick Keighley

My god it's full of stars!
Dave Bowman, on seeing HAL's source code

Apr 11 '06 #7
Nick Keighley wrote:
gi**********@gm ail.com wrote:
I am very new to C language and I got really big assignment in my
work.I am wondering if anyone can help me.........I need to port
compiler from unix to windows and compiler is written partially in c
and partially in fortran.


wow. I think you need to go back and talk to your boss. This is a tough

assignment, probably for anyone. For someone with your level of
knowledge it sails close to the "impossible " region of the problem
space.

Nah. Just recompile under Cygwin.

Well, it might work.

OK, probably not. But it's worth a shot.

S.
Apr 11 '06 #8

<gi**********@g mail.com> wrote in message
news:11******** **************@ g10g2000cwb.goo glegroups.com.. .
Hi All,

I am very new to C language and I got really big assignment in my
work.I am wondering if anyone can help me.........I need to port
compiler from unix to windows and compiler is written partially in c
and partially in fortran. I guess i need to change host specific files
to make it working. I wonder if standard header files are going to
change in this case.my current windows compiler doesn't have
sys/resource.h but unix compiler does. shud i create one or talk to my
vendor about missing header file or i need to do some work around for
that part.


http://en.wikipedia.org/wiki/Snipe_hunt

Apr 11 '06 #9

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
3432
by: John | last post by:
Hi. I am having a few header problems at the moment with a login page. I don't have my headers at the top of the page where I've learned I need to have them. However, I also know I'm supposed to have the session_start(); at the top of the page as well. So when you have two things that need to be the first which do you put first? And if I put one before the other will that cause problems? Below is a copy of the php from my page. It...
11
2756
by: Steven T. Hatton | last post by:
In the past there have been lengthy discussiions regarding the role of header files in C++. People have been very adamat about header files serving as in interface to the implementation. I do understand the objective. This example may represent an interface in need of a bit of refactoring, but it goes to demonstrate the basic idea as I understand it. http://developer.kde.org/documentation/library/cvs-api/kdevelop/html/ast_8h-source.html...
60
8286
by: Derrick Coetzee | last post by:
It seems like, in every C source file I've ever seen, there has been a very definite include order, as follows: - include system headers - include application headers - include the header associated with this source file For example, in a file hello.c: #include <stdio.h>
18
2741
by: John Smith | last post by:
Hi all What does the group think of the practise of including one header file from inside another? I have some legacy code where this has been done, and it creates a dependency on a module (collection of files) which are not required, except for one header file's contents. I'd say 'No, header files should be included in the C source, not in another
6
7078
by: Jason Collins | last post by:
There seems to be an inconsistency (bug?) in the way the Set-Cookie header is handled by the WebHeaderCollection. That is, the values of Set-Cookie, when an Expires is specified, contain the "," character. This seems to be incorrectly parsed during GetValues(). A simple example shows it best (there are 2 .aspx pages and an output): AddHeaders.aspx: <%@ Page language="c#" %>
0
3729
by: Dean Hallman | last post by:
Hello, I am developing a BHO that should add a custom HTTP header on a specific domain only. Don't want the header globally, otherwise I could just add a registry key. So, on BEFORENAVIGATE2, I am canceling the current navigation and renavigating with the new custom header using Navigate2. This usually works fine, but in some cases (particularly when selecting a link that starts a new window), the Navigate2 call fails.
4
2483
by: Joseph Geretz | last post by:
We use a Soap Header to pass a token class (m_Token) back and forth with authenticated session information. Given the following implementation for our Logout method, I vastly prefer to simply code m_Token = null in order to destroy the session token when the user logs out. However, I'm finding that setting class instance to null results in no header being sent back to the client, with the result that the client actually remains with an...
1
24161
by: Shalako | last post by:
I check my error log and see these entries: malformed header from script. Bad header= Missing gauge reports are ind: padata.pl /perl/pema/padata.pl did not send an HTTP header malformed header from script. Bad header= : padata.pl /perl/pema/padata.pl did not send an HTTP header malformed header from script. Bad header= Missing gauge reports are ind: padata.pl /perl/pema/padata.pl did not send an HTTP header malformed...
5
1968
by: =?Utf-8?B?V2ViQnVpbGRlcjQ1MQ==?= | last post by:
I have a sub in vb.net that adds extra headers to a gridview and it works very well. however, i tried to translate it to c# and i'm getting the header inserting itself over the first datarows and inserting blank rows at the bottom. i can post the code if necessary for the C# but it basicly mirrors the vb.net -- (i''ll be asking a lot of these, but I find C# totally way cooler than vb
12
5399
by: William Gill | last post by:
I am retooling my design habits, trying to get rid of some mental artifacts, and trying to "standardize" my starting point "templates" (both html and css). I am also trying to avoid "div-itis." I find myself using selectors like div#header instead of just #header. I know that div#header and #header both refer to the same target, and (for me) it is easy to see exactly what the style is being applied to. Any thoughts, pro and con, on one...
0
8874
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9393
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
1
9164
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9092
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8072
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4506
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4775
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3212
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
2622
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.