That's the full log and yes it does create precompiled header when run from command line:
Build started on: 25-10-2011 at 12:05.29
Build ended on: 25-10-2011 at 12:05.37
-------------- Build: Debug in e:\Excersizes\meta\Promote ---------------
g++ -Wall -fexceptions -g -Wshadow -Winit-self -Wredundant-decls -Wcast-align -Wundef -Wfloat-equal -Winline -Wunreachable-code -Wmissing-declarations -Wmissing-include-dirs -Wswitch-enum -Wswitch-default -Weffc++ -Wmain -pedantic-errors -pedantic -std=c++0x -Wfatal-errors -Wextra -Wall -g -ID:\Libraries\boost_1_47_0\boost_1_47_0 -IE:\Excersizes\meta -Ie:\Excersizes\meta -c E:\Excersizes\meta\Promote.h -o E:\Excersizes\meta\Promote.h.gch
g++ -Wall -fexceptions -g -Wshadow -Winit-self -Wredundant-decls -Wcast-align -Wundef -Wfloat-equal -Winline -Wunreachable-code -Wmissing-declarations -Wmissing-include-dirs -Wswitch-enum -Wswitch-default -Weffc++ -Wmain -pedantic-errors -pedantic -std=c++0x -Wfatal-errors -Wextra -Wall -g -ID:\Libraries\boost_1_47_0\boost_1_47_0 -Ie:\Excersizes\meta -Ie:\Excersizes\meta -c e:\Excersizes\meta\main.cpp -o obj\Debug\main.o
mingw32-g++.exe -LC:\boost_1_47_0 -o \\bin\Debug\e\Excersizes\meta\Promote.exe obj\Debug\main.o
c:/mingw32/bin/../lib/gcc/mingw32/4.6.1/../../../../mingw32/bin/ld.exe: cannot open output file \\bin\Debug\e\Excersizes\meta\Promote.exe: No such file or directory
collect2: ld returned 1 exit status
Process terminated with status 1 (0 minutes, 8 seconds)
1 errors, 0 warnings (0 minutes, 8 seconds)
Guys, that's the unfortunate header file which either doesn't want to get precompiled (with cb 7452) or gets precompiled (with cb 7500) but gives error. Can someone try to precompile it and see if it works for you? Thanks
#ifndef PROMOTE_H_INCLUDED
#define PROMOTE_H_INCLUDED
#include <type_traits>
#include <boost/mpl/vector.hpp>
#include <boost/mpl/find.hpp>
#include <boost/mpl/next.hpp>
#include <boost/mpl/deref.hpp>
template<class Int_T,class Int_Y>
struct are_same_size
{
enum {value = sizeof(Int_T) == sizeof(Int_Y)};
};
template<class Int_T>
struct Is_Char
{
enum {value = false};
};
template<>
struct Is_Char<char>
{
enum {value = true};
};
template<>
struct Is_Char<unsigned char>
{
enum {value = true};
};
template<>
struct Is_Char<signed char>
{
enum {value = true};
};
template<class Integral>
struct Promote
{
static_assert(std::is_integral<Integral>::value,"Non integral type is not allowed.");
typedef typename std::conditional<std::is_signed<Integral>::value,
boost::mpl::vector<char,short,int,typename std::conditional<!are_same_size<int,long>::value,long,long long>::type>,
boost::mpl::vector<unsigned char,unsigned short,unsigned int,typename std::conditional<!are_same_size<unsigned int,unsigned long>::value,long,long long>::type>>::type types;
typedef typename boost::mpl::find<types,
typename std::conditional<Is_Char<Integral>::value,
typename std::conditional<std::is_signed<Integral>::value,char,unsigned char>::type, Integral>::type>::type this_type;
typedef typename boost:: mpl::next<this_type>::type next_type;
typedef typename boost::mpl::deref<next_type>::type type;
};
#endif // PROMOTE_H_INCLUDED