User forums > Help

Cannot build Code::Blocks from source

<< < (2/3) > >>

oBFusCATed:

--- Code: ---./bootstrap
./configure
make dist
rpmbuild -ba codeblocks*.tar.*

--- End code ---

If you like you can use a separate build folder.

alexchen:
Because 'make dist' cannot finish the build, I get the following errors:

$ pwd
/home/fmserver/Downloads/CodeBlocks.http/trunk

$ sudo make dist
[sudo] password for fmserver:
make  dist-bzip2 am__post_remove_distdir='@:'
make[1]: Entering directory `/home/fmserver/Downloads/CodeBlocks.http/trunk'
if test -d "codeblocks-17.12svn11664"; then find "codeblocks-17.12svn11664" -type d ! -perm -200 -exec chmod u+w {} ';' && rm -rf "codeblocks-17.12svn11664" || { sleep 5 && rm -rf "codeblocks-17.12svn11664"; }; else :; fi
test -d "codeblocks-17.12svn11664" || mkdir "codeblocks-17.12svn11664"
 (cd src && make  top_distdir=../codeblocks-17.12svn11664 distdir=../codeblocks-17.12svn11664/src \
....
....
make[4]: Entering directory `/home/fmserver/Downloads/CodeBlocks.http/trunk/src/plugins/contrib'
make[4]: *** No rule to make target `FortranProject/images/*.png', needed by `distdir'.  Stop. <-----  This is killing the build.
make[4]: Leaving directory `/home/fmserver/Downloads/CodeBlocks.http/trunk/src/plugins/contrib'
make[3]: *** [distdir] Error 1
make[3]: Leaving directory `/home/fmserver/Downloads/CodeBlocks.http/trunk/src/plugins'
make[2]: *** [distdir] Error 1
make[2]: Leaving directory `/home/fmserver/Downloads/CodeBlocks.http/trunk/src'
make[1]: *** [distdir] Error 1
make[1]: Leaving directory `/home/fmserver/Downloads/CodeBlocks.http/trunk'
make: *** [dist] Error 2

$ rpmbuild -ba codeblocks*.tar.*
error: failed to stat /home/fmserver/Downloads/CodeBlocks.http/trunk/codeblocks*.tar.*: No such file or directory

oBFusCATed:
Pass --disable-fortran or make sure you download the external fortranproject...

alexchen:
I am running CentOS 7.6 and I use the command "svn checkout http://svn.code.sf.net/p/codeblocks/code/trunk" to get the source.  The output shows 'Fortran' plugin is downloaded:
A    trunk/src
A    trunk/src/sdk
A    trunk/src/sdk/resources
A    trunk/src/sdk/resources/lexers
A    trunk/src/sdk/editormanager.cpp
A    trunk/src/sdk/scriptingmanager.cpp
....
....
A    trunk/bundle.sh.in
A    trunk/README.debian
A    trunk/COMPILERS
A    trunk/NEWS
 U   trunk

Fetching external item into 'trunk/src/plugins/contrib/FortranProject':
A    trunk/src/plugins/contrib/FortranProject/resources
A    trunk/src/plugins/contrib/FortranProject/images
A    trunk/src/plugins/contrib/FortranProject/images/22x22
A    trunk/src/plugins/contrib/FortranProject/images/32x32
A    trunk/src/plugins/contrib/FortranProject/images/fortranproject
A    trunk/src/plugins/contrib/FortranProject/images/fortranproject/16x16
A    trunk/src/plugins/contrib/FortranProject/images/fortranproject/16x16/fprojectjumpback.png
A    trunk/src/plugins/contrib/FortranProject/images/fortranproject/16x16/interface_function_gen.png
A    trunk/src/plugins/contrib/FortranProject/images/fortranproject/16x16/fprojectjumphome.png
A    trunk/src/plugins/contrib/FortranProject/fortranproject.cpp
A    trunk/src/plugins/contrib/FortranProject/resources/fortranprojecttoolbar.xrc
A    trunk/src/plugins/contrib/FortranProject/resources/workspacebrowserf.xrc
A    trunk/src/plugins/contrib/FortranProject/images/fortranproject/16x16/interface_private.png
A    trunk/src/plugins/contrib/FortranProject/images/fortranproject/16x16/interface_subroutine_gen_private.png


I can complete 'make dist' if I use './configure --disable-fortran'.  But it still fails in 'rpmbuild'.
$ make dist
make  dist-bzip2 am__post_remove_distdir='@:'
make[1]: Entering directory `/home/fmserver/Downloads/CodeBlocks.http/trunk'
if test -d "codeblocks-17.12svn11664"; then find "codeblocks-17.12svn11664" -type d ! -perm -200 -exec chmod u+w {} ';' && rm -rf "codeblocks-17.12svn11664" || { sleep 5 && rm -rf "codeblocks-17.12svn11664"; }; else :; fi
test -d "codeblocks-17.12svn11664" || mkdir "codeblocks-17.12svn11664"
 (cd src && make  top_distdir=../codeblocks-17.12svn11664 distdir=../codeblocks-17.12svn11664/src \
.....
....
|| find "codeblocks-17.12svn11664" -type d ! -perm -755 \
   -exec chmod u+rwx,go+rx {} \; -o \
  ! -type d ! -perm -444 -links 1 -exec chmod a+r {} \; -o \
  ! -type d ! -perm -400 -exec chmod a+r {} \; -o \
  ! -type d ! -perm -444 -exec /bin/sh /home/fmserver/Downloads/CodeBlocks.http/trunk/install-sh -c -m a+r {} {} \; \
|| chmod -R a+r "codeblocks-17.12svn11664"
tardir=codeblocks-17.12svn11664 && /bin/sh /home/fmserver/Downloads/CodeBlocks.http/trunk/missing tar chf - "$tardir" | BZIP2=${BZIP2--9} bzip2 -c >codeblocks-17.12svn11664.tar.bz2
make[1]: Leaving directory `/home/fmserver/Downloads/CodeBlocks.http/trunk'
if test -d "codeblocks-17.12svn11664"; then find "codeblocks-17.12svn11664" -type d ! -perm -200 -exec chmod u+w {} ';' && rm -rf "codeblocks-17.12svn11664" || { sleep 5 && rm -rf "codeblocks-17.12svn11664"; }; else :; fi

$ rpmbuild -ba codeblocks*.tar.*
error: File /home/fmserver/Downloads/CodeBlocks.http/trunk/codeblocks-17.12svn11664.tar.bz2 does not appear to be a specfile.

I was able to build revision 11558 with 'make' and the RPM.
(I forgot the command to build RPM, but now I will keep this in mind.)

Can you build the RPM from the instructions in "http://wiki.codeblocks.org/index.php/Installing_Code::Blocks_from_source_on_RPM_based_distributions#Build_the_RPM_package"?

oBFusCATed:
Sorry rpmbuild -ta is the correct command...

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version