Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build failure on vanilla Ubuntu 8.10 #29

Closed
GoogleCodeExporter opened this issue May 26, 2015 · 14 comments
Closed

Build failure on vanilla Ubuntu 8.10 #29

GoogleCodeExporter opened this issue May 26, 2015 · 14 comments

Comments

@GoogleCodeExporter
Copy link


Attempting to build distcc from source.  

distcc 3.1
Ubuntu 8.10

$ tar xjvf distcc-3.1.tar.bz2
$ cd distcc-3.1

Tried the simple
  ./configure && make && sudo make install

Warning are treated as errors so multiple failure.  You can hack the make
file to turn this off but other errors occur 

gcc -DHAVE_CONFIG_H -D_GNU_SOURCE -DSYSCONFDIR="\"/usr/local/etc\""
-DPKGDATADIR="\"/usr/local/share/distcc\"" -Isrc -I"./src" -I"./lzo"
-I"./popt" -Werror -g -O2 -MD -W -Wall -Wimplicit -Wshadow -Wpointer-arith
-Wcast-align -Wwrite-strings -Waggregate-return -Wstrict-prototypes
-Wmissing-prototypes -Wnested-externs -Wmissing-declarations
-Wuninitialized -pthread -o src/emaillog.o -c src/emaillog.c
cc1: warnings being treated as errors
src/emaillog.c: In function ‘dcc_add_file_to_log_email’:
src/emaillog.c:92: error: ignoring return value of ‘write’, declared with
attribute warn_unused_result
src/emaillog.c:93: error: ignoring return value of ‘write’, declared with
attribute warn_unused_result
src/emaillog.c:94: error: ignoring return value of ‘write’, declared with
attribute warn_unused_result
src/emaillog.c:98: error: ignoring return value of ‘write’, declared with
attribute warn_unused_result

... etc.


Regenerating configure results in a similar set of errors but starting in a
different file.

$ sh autogen.sh
$ ./configure
$ make

cc1: warnings being treated as errors
src/trace.c: In function ‘rs_logger_file’:
src/trace.c:330: error: ignoring return value of ‘write’, declared with
attribute warn_unused_result
make: *** [src/trace.o] Error 1


Original issue reported on code.google.com by rrans...@gmail.com on 3 Dec 2008 at 11:31

@GoogleCodeExporter
Copy link
Author

Have you tried

  ./configure --disable-Werror
  make

?

Original comment by fergus.h...@gmail.com on 3 Dec 2008 at 11:39

@GoogleCodeExporter
Copy link
Author

Just did.  error -> warnings.  Has a problem finding Python.h

if test -z "/usr/bin/python2.5"; then   \
      echo "Not building include-server: No suitable python found"; \
    else                        \
      mkdir -p "./_include_server" &&      \
      DISTCC_VERSION="3.1"          \
      SRCDIR="."                            \
      CFLAGS="-g -O2 -MD -W -Wall -Wimplicit -Wshadow -Wpointer-arith -Wcast-align
-Wwrite-strings -Waggregate-return -Wstrict-prototypes -Wmissing-prototypes
-Wnested-externs -Wmissing-declarations -Wuninitialized -pthread
-Wno-missing-prototypes -Wno-missing-declarations -Wno-write-strings
-Wp,-U_FORTIFY_SOURCE"           \
      CPPFLAGS="-DHAVE_CONFIG_H -D_GNU_SOURCE -DSYSCONFDIR="\"/usr/local/etc\""
-DPKGDATADIR="\"/usr/local/share/distcc\"" -Isrc -I"./src" -I"./lzo" 
-I"./popt""    
                   \
      /usr/bin/python2.5 "./include_server/setup.py" \
          build                     \
            --build-base="./_include_server"  \
            --build-temp="./_include_server"; \
    fi
setup.py: PYTHON_CFLAGS must be defined.
running build
running build_py
running build_ext
building 'include_server.distcc_pump_c_extensions' extension
gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall 
-Wstrict-prototypes
-g -O2 -MD -W -Wall -Wimplicit -Wshadow -Wpointer-arith -Wcast-align 
-Wwrite-strings
-Waggregate-return -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs
-Wmissing-declarations -Wuninitialized -pthread -Wno-missing-prototypes
-Wno-missing-declarations -Wno-write-strings -Wp,-U_FORTIFY_SOURCE 
-DHAVE_CONFIG_H
-D_GNU_SOURCE -DSYSCONFDIR=/usr/local/etc -DPKGDATADIR=/usr/local/share/distcc 
-Isrc
-I./src -I./lzo -I./popt -fPIC -D_GNU_SOURCE=1 -Isrc -I./src -I./lzo -I./popt
-I/usr/include/python2.5 -c
/home/rranslam/wrs/tools/distcc-3.1/include_server/c_extensions/distcc_pump_c_ex
tensions_module.c
-o
./_include_server/home/rranslam/wrs/tools/distcc-3.1/include_server/c_extensions
/distcc_pump_c_extensions_module.o
/home/rranslam/wrs/tools/distcc-3.1/include_server/c_extensions/distcc_pump_c_ex
tensions_module.c:24:20:
error: Python.h: No such file or directory
/home/rranslam/wrs/tools/distcc-3.1/

Original comment by rrans...@gmail.com on 3 Dec 2008 at 11:47

@GoogleCodeExporter
Copy link
Author

Looks like there is a fix for "PYTHON_CFLAGS must be defined."  I can pull from 
the
head and give it a spin

Original comment by rrans...@gmail.com on 4 Dec 2008 at 12:07

@GoogleCodeExporter
Copy link
Author

You can just ignore the message about PYTHON_CFLAGS.  It's a spurious message.  
The
fix just makes the message go away.

Python.h is supposed to be part of your Python installation.
You need to have the right packages installed in order to build distcc from 
source.
Try "apt-get install python2.4-dev"?

Let us know if that solves the problem.

Cheers,
  Fergus.

Original comment by fergus.h...@gmail.com on 9 Dec 2008 at 1:18

@GoogleCodeExporter
Copy link
Author

darn though i had python-dev installed... that was it. Thanks

to recap, for ubuntu-8.10 do

  sudo apt-get install python2.5-dev
  tar xjvf distcc-3.1.tar.bz2
  cd distcc-3.1
  ./autogen.sh
  ./configure --disable-Werror && make && sudo make install

  ready to go


Original comment by rrans...@gmail.com on 10 Dec 2008 at 4:57

@GoogleCodeExporter
Copy link
Author

I'll update the installation instructions.
http://code.google.com/p/distcc/source/detail?r=632#

Original comment by fergus.h...@gmail.com on 10 Dec 2008 at 6:41

@GoogleCodeExporter
Copy link
Author

Documentation updated in revision 634.

Original comment by fergus.h...@gmail.com on 10 Dec 2008 at 8:23

  • Changed state: Fixed

@GoogleCodeExporter
Copy link
Author

Original comment by fergus.h...@gmail.com on 10 Dec 2008 at 8:39

  • Added labels: Type-Defect

@GoogleCodeExporter
Copy link
Author

If python is truly optional, as the install docs indicate, then your solution 
really
doesn't fix the problem.  The configure script should detect that the python dev
tools (like Python.h) are missing, print a big warning message, and then 
proceed as
if python were completely missing.

I'm having the same problem described, but I don't have root access, nor do I 
want to
try to install the python dev tools by hand in my home dir just so I can compile
this.  Is there some way to make the configure script think that python isn't 
installed?

Original comment by andrew.s...@gmail.com on 21 Mar 2009 at 10:38

@GoogleCodeExporter
Copy link
Author

In general it's a good idea to have Python, including the Python dev tools; you 
need
that for "pump" mode, which has much better performance in a lot of cases.

But, if you're really keen on not using Python...
You might be able to get configure to not detect Python by setting PATH to 
something
that doesn't contain "python*", e.g.

   mkdir $HOME/usr_bin
   ln -s /usr/bin/* $HOME/usr_bin
   rm -f ~/usr_bin/python*
   PATH=$(echo "$PATH" | sed "s@/usr/bin@$HOME/usr_bin)

Alternatively, please feel free to make a patch to configure.ac to add a
--without_python option, and send it to the distcc-patches list.

Original comment by fergus.h...@gmail.com on 23 Mar 2009 at 6:49

@GoogleCodeExporter
Copy link
Author

[deleted comment]

@GoogleCodeExporter
Copy link
Author

I think it's common to have python installed, while without python-dev. 
Thus,what will distcc be if python-dev is missing while python existing? 
It involves the dependency of python and python-dev from distcc.

Original comment by compan...@gmail.com on 8 Jun 2012 at 12:10

@GoogleCodeExporter
Copy link
Author

I think the INSTALL file explains the dependencies on other packages.

Original comment by fergus.h...@gmail.com on 8 Jun 2012 at 3:28

@GoogleCodeExporter
Copy link
Author

Thanks. I forget to check that. : - )

Original comment by compan...@gmail.com on 11 Jun 2012 at 1:58

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant