[Qt-interest] Problem with MFC to Qt migration using qt-vs-addin-1.0.2 in VisualStudio2005
Scott Aron Bloom
Scott.Bloom at sabgroup.com
Fri Sep 25 20:57:02 CEST 2009
While I don't know about the fortran..
What about qmake -project ?
Scott
-----Original Message-----
From: qt-interest-bounces at trolltech.com
[mailto:qt-interest-bounces at trolltech.com] On Behalf Of David Walthall
Sent: Friday, September 25, 2009 9:21 AM
To: qt-interest at trolltech.com
Subject: Re: [Qt-interest] Problem with MFC to Qt migration using
qt-vs-addin-1.0.2 in VisualStudio2005
Vanbrabant Martin wrote:
> Thanks John,
>
> the hard way to do it indeed (given the complexity of the project I'm
faced with...).
>
> Martin.
Here is a script that I wrote to simplify the generation of .pro files
when moving from MFC to Qt. It requires sh, so you can either run it on
linux or install cygwin
#! /bin/sh
## MakePri.sh
##
## USAGE: MakePri.sh [dir1 [dir2 [...]]]
## Generates .pro files for the listed directories, or for
## the current directory if no dirN are listed.
headers=""
sources=""
fortran=""
forms=""
if [ $# -eq 0 ] ; then
for d in "." ; do
headersTmp=`ls -1 $d/*.h* $d/*.H* 2> /dev/nul`
headers="$headers $headersTmp"
sourcesTmp=`ls -1 $d/*.c* $d/*.C* 2> /dev/nul`
sources="$sources $sourcesTmp"
fortranTmp=`ls -1 $d/*.f* $d/*.F* 2> /dev/nul`
fortran="$fortran $fortranTmp"
formsTmp=`ls -1 $d/*.ui 2> /dev/nul`
forms="$forms $formsTmp"
done
else
for d in $@ ; do
headersTmp=`ls -1 $d/*.h* $d/*.H* 2> /dev/nul`
headers="$headers $headersTmp"
sourcesTmp=`ls -1 $d/*.c* $d/*.C* 2> /dev/nul`
sources="$sources $sourcesTmp"
fortranTmp=`ls -1 $d/*.f* $d/*.F* 2> /dev/nul`
fortran="$fortran $fortranTmp"
formsTmp=`ls -1 $d/*.ui 2> /dev/nul`
forms="$forms $formsTmp"
done
fi
if [ "x$headers" != "x" ] ; then
echo "#Header files"
echo "HEADERS += \\"
for ff in $headers ; do
echo " $ff \\"
done
echo ""
fi
if [ "x$sources" != "x" ] ; then
echo "#Source files"
echo "SOURCES += \\"
for ff in $sources ; do
echo " $ff \\"
done
echo ""
fi
if [ "x$forms" != "x" ] ; then
echo "#Forms"
echo "FORMS += \\"
for ff in $forms ; do
echo " $ff \\"
done
echo ""
fi
if [ "x$fortran" != "x" ] ; then
echo "#Fortran files"
echo "F90_SOURCES += \\"
for ff in $fortran ; do
echo " $ff \\"
done
echo ""
fi
_______________________________________________
Qt-interest mailing list
Qt-interest at trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-interest
More information about the Qt-interest-old
mailing list