remove flex.pri and bison.pri, replace with tweaks for MSYS

This commit is contained in:
Don Bright 2016-10-29 22:26:36 -07:00
parent 9316143829
commit d88b51d9cd
4 changed files with 10 additions and 77 deletions

View file

@ -1,45 +0,0 @@
{
bison.name = Bison ${QMAKE_FILE_IN}
bison.input = BISONSOURCES
bison.output = ${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}_yacc.cpp
bison.commands = bison -d -p ${QMAKE_FILE_BASE} -o ${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}_yacc.cpp ${QMAKE_FILE_IN}
bison.commands += && if [[ -e ${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}_yacc.hpp ]] ; then mv ${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}_yacc.hpp ${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}_yacc.h ; fi
bison.CONFIG += target_predeps
bison.variable_out = GENERATED_SOURCES
silent:bison.commands = @echo Bison ${QMAKE_FILE_IN} && $$bison.commands
QMAKE_EXTRA_COMPILERS += bison
bison_header.input = BISONSOURCES
bison_header.output = ${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}_yacc.h
bison_header.commands = sleep 2 && bison -d -p ${QMAKE_FILE_BASE} -o ${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}_yacc.cpp ${QMAKE_FILE_IN}
bison_header.commands += && if [ -e ${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}_yacc.hpp ]; then mv ${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}_yacc.hpp ${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}_yacc.h ; fi
bison_header.CONFIG += target_predeps no_link
silent:bison_header.commands = @echo Bison ${QMAKE_FILE_IN} && $$bison.commands
QMAKE_EXTRA_COMPILERS += bison_header
}
unix:linux* {
exists(/usr/bin/bison) {
QMAKE_YACC = /usr/bin/bison
}
}
freebsd* {
# on some BSD, /usr/local/bin/bison is newer than
# /usr/bin/bison, so try to prefer it.
exists(/usr/local/bin/bison) {
QMAKE_YACC = /usr/local/bin/bison
} else { # look in $PATH
QMAKE_YACC = bison
}
}
netbsd* {
exists(/usr/pkg/bin/bison) {
QMAKE_YACC = /usr/pkg/bin/bison
} else { # look in $PATH
QMAKE_YACC = bison
}
}
win32*msvc* {
}

View file

@ -1,25 +0,0 @@
{
flex.name = Flex ${QMAKE_FILE_IN}
flex.input = FLEXSOURCES
flex.output = ${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}.lexer.cpp
flex.commands = flex -P ${QMAKE_FILE_BASE} -o${QMAKE_FILE_PATH}/${QMAKE_FILE_BASE}.lexer.cpp ${QMAKE_FILE_IN}
flex.CONFIG += target_predeps
flex.variable_out = GENERATED_SOURCES
silent:flex.commands = @echo Lex ${QMAKE_FILE_IN} && $$flex.commands
QMAKE_EXTRA_COMPILERS += flex
}
unix:linux* {
exists(/usr/bin/flex) {
QMAKE_LEX = /usr/bin/flex
}
}
freebsd* {
QMAKE_LEX = /usr/local/bin/flex
}
netbsd* {
QMAKE_LEX = /usr/pkg/bin/flex
}

View file

@ -76,7 +76,9 @@ win* {
RC_FILE = openscad_win32.rc
QMAKE_CXXFLAGS += -DNOGDI
}
contains(OSNAME,Msys): {
QMAKE_CXXFLAGS -= -pipe # ctrl-c doesn't like pipes
}
RESOURCES = openscad.qrc
@ -95,8 +97,6 @@ CONFIG += boost
CONFIG += gettext
CONFIG += scintilla
include(flex.pri)
include(bison.pri)
include(cgal.pri)
include(opencsg.pri)
include(opengl.pri)
@ -111,8 +111,10 @@ PKGCONFIG += eigen3 glew fontconfig freetype2 harfbuzz glib-2.0 libxml-2.0
contains(OSNAME,Msys): {
PKGCONFIG += Qt5Core Qt5OpenGL Qt5Gui Qt5Concurrent
LIBS += -lopengl32 -lglu32
CONFIG += moc
}
#CONFIG += qt
QT += widgets core gui concurrent
# VERSION is a qmake keyword, do not use
@ -150,6 +152,7 @@ FORMS += src/MainWindow.ui \
LEXSOURCES += src/lexer.l
YACCSOURCES += src/parser.y
CONFIG += yacc lex
HEADERS += src/AST.h \
src/ModuleInstantiation.h \

View file

@ -380,10 +380,10 @@ cleanup_mxe()
rm -f ./debug/*
rm -rf $DEPLOYDIR/openscad-$VERSION
mkdir $DEPLOYDIR/openscad-$VERSION
touch -t 200012121010 $OPENSCADDIR/src/parser_yacc.h
touch -t 200012121010 $OPENSCADDIR/src/parser_yacc.cpp
touch -t 200012121010 $OPENSCADDIR/src/parser_yacc.hpp
touch -t 200012121010 $OPENSCADDIR/src/lexer_lex.cpp
#touch -t 200012121010 $OPENSCADDIR/src/parser_yacc.h
#touch -t 200012121010 $OPENSCADDIR/src/parser_yacc.cpp
#touch -t 200012121010 $OPENSCADDIR/src/parser_yacc.hpp
#touch -t 200012121010 $OPENSCADDIR/src/lexer_lex.cpp
}
call_make()