DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD General

OpenBSD General Other questions regarding OpenBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 18th May 2008
WeakSauceIII WeakSauceIII is offline
Port Guard
 
Join Date: May 2008
Posts: 30
Thanked 0 Times in 3 Posts
Default Compiling OpenBSD code

I'll try and be as brief as possible. I have read the page on compiling openbsd on openbsd.org. I am doing this so I can compile certain programs with debugging symbols and then source debug them with ddd / gdb. I start by going to /usr/src/sbin/echo for example and then 'make'. I add the -g to the Makefile so it includes debug info when compiling. Certain files such as ifconfig do not link.


root@/usr/src/sbin/ifconfig :make
cc -O2 -pipe -DINET6 -c ifconfig.c
ifconfig.c:102:26: netmpls/mpls.h: No such file or directory
ifconfig.c: In function `setifwmm':
ifconfig.c:1427: error: storage size of `wmm' isn't known
ifconfig.c:1431: error: `SIOCS80211WMMPARMS' undeclared (first use in this function)



I assume the search path for make/gcc is configured somewhere in the bsd.*.mk files. Anyone know how to 'make' ifconfig' for example w/out having to type out the paths for all dependencies?
Reply With Quote
  #2   (View Single Post)  
Old 19th May 2008
BSDfan666 BSDfan666 is offline
Real Name: N/A, this is the interweb.
Helpful companion
 
Join Date: Apr 2008
Location: Ontario, Canada
Posts: 2,223
Thanked 193 Times in 184 Posts
Default

It looks like you're trying to compile -CURRENT on -RELEASE.. (or an earlier -CURRENT..).

MPLS is a feature that was just recently added, clearly those headers are not on your system..
Reply With Quote
  #3   (View Single Post)  
Old 19th May 2008
WeakSauceIII WeakSauceIII is offline
Port Guard
 
Join Date: May 2008
Posts: 30
Thanked 0 Times in 3 Posts
Default

That header exists. If i add the whole path to the ifconfig.c file it will find it and I can run mkdep w/out a problem but the other errors still happen. What you said makes sense though. I will try and get the right code. I'm still interested as to where the path is configured for finding those headers but i have ordered a few used books on make and gcc so I'll find out eventually.
Reply With Quote
  #4   (View Single Post)  
Old 19th May 2008
ocicat ocicat is offline
Administrator
 
Join Date: Apr 2008
Posts: 2,930
Thanked 190 Times in 160 Posts
Default

BSDfan666 is correct. MPLS changes to ifconfig(8) were checked in for the first time in early in May, so it appears you were attempting to build -current on a non-current system. You should study Section 5.3 to find the appropriate upgrade path for whatever version you have installed:

http://openbsd.org/faq/faq5.html#BldBinary

If you do have 4.3-release installed, you can upgrade to 4.3-stable by using the OPENBSD_4_3 tag found in CVS. This is further described in Section 5.3.3:

http://openbsd.org/faq/faq5.html#BldGetSrc

Note if you are wanting to play with MPLS, you will only be able to do so in -current.

Last edited by ocicat; 19th May 2008 at 12:46 AM.
Reply With Quote
  #5   (View Single Post)  
Old 19th May 2008
WeakSauceIII WeakSauceIII is offline
Port Guard
 
Join Date: May 2008
Posts: 30
Thanked 0 Times in 3 Posts
Default

You are the man. I checked out the src again with the -rOPENBSD_4_3 option and it compiles fine.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Compiling pingus error. bsdnewbie999 OpenBSD General 7 16th May 2009 08:43 AM
Compiling Epkowa Oko OpenBSD Packages and Ports 3 30th December 2008 10:01 PM
Error while compiling e2fsprogs pax FreeBSD Ports and Packages 4 4th August 2008 11:40 AM
c++ compiling hello world Gates Programming 3 26th July 2008 12:48 PM
Compiling Nagios 3.02 roundkat Solaris 1 2nd June 2008 09:09 PM


All times are GMT. The time now is 07:23 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick