mirror of
https://github.com/chris2511/xca.git
synced 2026-09-12 19:51:05 +05:00
Changes to compile on WIN32 platform
This commit is contained in:
parent
1d345e465f
commit
7a0aa8818c
@ -463,7 +463,12 @@ void MainWindow::newPath(QString str)
|
||||
|
||||
bool MainWindow::mkDir(QString dir)
|
||||
{
|
||||
#ifdef WIN32
|
||||
int ret = mkdir(dir.latin1());
|
||||
// in direct.h declare _CRTIMP int __cdecl mkdir(const char *);
|
||||
#else
|
||||
int ret = mkdir(dir.latin1(), S_IRUSR | S_IWUSR | S_IXUSR);
|
||||
#endif
|
||||
if (ret) {
|
||||
QString desc = " (";
|
||||
desc += strerror(ret);
|
||||
@ -473,5 +478,6 @@ bool MainWindow::mkDir(QString dir)
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
||||
}
|
||||
|
||||
|
||||
@ -104,10 +104,13 @@
|
||||
#include "lib/db_crl.h"
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#ifndef WIN32
|
||||
#ifdef WIN32
|
||||
#include <direct.h> // to define mkdir function
|
||||
#else
|
||||
#include <unistd.h>
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef MAINWINDOW_H
|
||||
#define MAINWINDOW_H
|
||||
|
||||
|
||||
38
NewX509.cpp
38
NewX509.cpp
@ -168,17 +168,8 @@ void NewX509::setRequest()
|
||||
changeDefault->setEnabled(false);
|
||||
changeDefault->setChecked(false);
|
||||
signerBox->setEnabled(false);
|
||||
startText=tr("\
|
||||
Welcome to the settings for certificate signing requests.
|
||||
A signing request needs a private key, so it will be created \
|
||||
if there isn't any unused key available in the key database. \
|
||||
This signing request can then be given to a Certification authority \
|
||||
while the private key of the request and of the resulting certificate \
|
||||
returned from the CA does never leave your computer.");
|
||||
endText=tr("\
|
||||
You are done with entering all parameters for generating a Certificate signing \
|
||||
request. The resulting request should be exported and send to an appropriate CA \
|
||||
for signing it.");
|
||||
startText=tr("Welcome to the settings for certificate signing requests. A signing request needs a private key, so it will be created if there isn't any unused key available in the key database. This signing request can then be given to a Certification authority while the private key of the request and of the resulting certificate returned from the CA does never leave your computer.");
|
||||
endText=tr("You are done with entering all parameters for generating a Certificate signing request. The resulting request should be exported and send to an appropriate CA for signing it.");
|
||||
tText=tr("Certificate request");
|
||||
setup();
|
||||
}
|
||||
@ -192,16 +183,8 @@ void NewX509::setTemp(pki_temp *temp)
|
||||
{
|
||||
setAppropriate(page1, false);
|
||||
finishButton()->setEnabled(true);
|
||||
startText=tr("\
|
||||
Welcome to the settings for Templates.
|
||||
This templates do not refer to any ASN.1 structure but are used to keep default \
|
||||
settings for signing requests and certificates. \
|
||||
When creating a Request or Certificate the template can preset the needed fields \
|
||||
with default settings.");
|
||||
endText=tr("\
|
||||
You are done with entering all parameters for the Template.
|
||||
After this step the template can be assigned to one of your CAs to be autoatically \
|
||||
applied when signing with this CA.");
|
||||
startText=tr("Welcome to the settings for Templates. This templates do not refer to any ASN.1 structure but are used to keep default settings for signing requests and certificates. When creating a Request or Certificate the template can preset the needed fields with default settings.");
|
||||
endText=tr("You are done with entering all parameters for the Template. After this step the template can be assigned to one of your CAs to be autoatically applied when signing with this CA.");
|
||||
tText=tr("Template");
|
||||
if (temp->getDescription() != "--") {
|
||||
description->setText(temp->getDescription().c_str());
|
||||
@ -214,17 +197,8 @@ applied when signing with this CA.");
|
||||
void NewX509::setCert()
|
||||
{
|
||||
finishButton()->setEnabled(true);
|
||||
startText=tr("\
|
||||
Welcome to the settings for Certificates.
|
||||
The information for the new Certificate can either be grabbed from a \
|
||||
given Certificate-request or be filled in by hand. \
|
||||
In the case of not signing a request there needs to be at least one unused key. \
|
||||
If this is not the case it will be created.
|
||||
If you want to self-sign a request (unusual but nevertheless possible) you need \
|
||||
the private key used to create the request.");
|
||||
endText=tr("\
|
||||
You are done with entering all parameters for creating a Certificate.
|
||||
");
|
||||
startText=tr("Welcome to the settings for Certificates. The information for the new Certificate can either be grabbed from a given Certificate-request or be filled in by hand. In the case of not signing a request there needs to be at least one unused key. If this is not the case it will be created. If you want to self-sign a request (unusual but nevertheless possible) you need the private key used to create the request.");
|
||||
endText=tr("You are done with entering all parameters for creating a Certificate.");
|
||||
tText=tr("Certificate");
|
||||
setup();
|
||||
}
|
||||
|
||||
211
xca.dsp
211
xca.dsp
@ -50,7 +50,7 @@ BSC32=bscmake.exe
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 /machine:IX86
|
||||
# ADD LINK32 $(QTDIR)\lib\qt-mt230nc.lib $(QTDIR)\lib\qtmain.lib kernel32.lib user32.lib gdi32.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib imm32.lib winmm.lib wsock32.lib winspool.lib delayimp.lib SSLeay32.lib libeay32.lib libdb40.lib /nologo /subsystem:windows /machine:IX86 /DELAYLOAD:comdlg32.dll /DELAYLOAD:oleaut32.dll /DELAYLOAD:winmm.dll /DELAYLOAD:wsock32.dll /DELAYLOAD:winspool.dll
|
||||
# ADD LINK32 $(QTDIR)\lib\qt-mt230nc.lib $(QTDIR)\lib\qtmain.lib kernel32.lib user32.lib gdi32.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib imm32.lib winmm.lib wsock32.lib winspool.lib delayimp.lib SSLeay32.lib libeay32.lib libdb41.lib /nologo /subsystem:windows /machine:IX86 /DELAYLOAD:comdlg32.dll /DELAYLOAD:oleaut32.dll /DELAYLOAD:winmm.dll /DELAYLOAD:wsock32.dll /DELAYLOAD:winspool.dll
|
||||
|
||||
!ELSEIF "$(CFG)" == "xca - Win32 Debug"
|
||||
|
||||
@ -73,7 +73,7 @@ BSC32=bscmake.exe
|
||||
# ADD BSC32 /nologo
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 /machine:IX86
|
||||
# ADD LINK32 $(QTDIR)\lib\qt-mt230nc.lib $(QTDIR)\lib\qtmain.lib kernel32.lib user32.lib gdi32.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib imm32.lib winmm.lib wsock32.lib winspool.lib SSLeay32.lib libeay32.lib libdb40.lib /nologo /subsystem:windows /incremental:no /debug /machine:IX86 /pdbtype:sept
|
||||
# ADD LINK32 $(QTDIR)\lib\qt-mt230nc.lib $(QTDIR)\lib\qtmain.lib kernel32.lib user32.lib gdi32.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib imm32.lib winmm.lib wsock32.lib winspool.lib SSLeay32.lib libeay32.lib libdb41.lib /nologo /subsystem:windows /incremental:no /debug /machine:IX86 /pdbtype:sept
|
||||
|
||||
!ENDIF
|
||||
|
||||
@ -90,6 +90,10 @@ SOURCE=lib\db_base.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\lib\db_crl.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=lib\db_key.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
@ -122,6 +126,10 @@ SOURCE=MainWindow.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\MainWindowCrl.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=MainWindowKeys.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
@ -186,6 +194,25 @@ SOURCE=lib\db_base.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\lib\db_crl.h
|
||||
|
||||
!IF "$(CFG)" == "xca - Win32 Release"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=.\lib\db_crl.h
|
||||
|
||||
"lib\moc_db_crl.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(QTDIR)\bin\moc lib\db_crl.h -o lib\moc_db_crl.cpp
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "xca - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=lib\db_key.h
|
||||
|
||||
!IF "$(CFG)" == "xca - Win32 Release"
|
||||
@ -310,16 +337,30 @@ SOURCE=.\ExportCert.h
|
||||
|
||||
!IF "$(CFG)" == "xca - Win32 Release"
|
||||
|
||||
# Begin Custom Build
|
||||
# PROP Ignore_Default_Tool 1
|
||||
# Begin Custom Build - MOCing ExportCert.h...
|
||||
InputDir=.
|
||||
InputPath=.\ExportCert.h
|
||||
InputName=ExportCert
|
||||
|
||||
"moc_ExportCert.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(QTDIR)\bin\moc ExportCert.h -o moc_ExportCert.cpp
|
||||
"$(InputDir)\moc_$(InputName).cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
%qtdir%\bin\moc.exe $(InputDir)\$(InputName).h -o $(InputDir)\moc_$(InputName).cpp
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "xca - Win32 Debug"
|
||||
|
||||
# PROP Ignore_Default_Tool 1
|
||||
# Begin Custom Build - MOCing ExportCert.h...
|
||||
InputDir=.
|
||||
InputPath=.\ExportCert.h
|
||||
InputName=ExportCert
|
||||
|
||||
"$(InputDir)\moc_$(InputName).cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
%qtdir%\bin\moc.exe $(InputDir)\$(InputName).h -o $(InputDir)\moc_$(InputName).cpp
|
||||
|
||||
# End Custom Build
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
@ -528,6 +569,78 @@ BuildCmds= \
|
||||
|
||||
!ELSEIF "$(CFG)" == "xca - Win32 Debug"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=.\CertExtend.ui
|
||||
InputName=CertExtend
|
||||
|
||||
BuildCmds= \
|
||||
%qtdir%\bin\uic.exe $(InputPath) -o $(InputDir)\$(InputName).h \
|
||||
%qtdir%\bin\uic.exe $(InputPath) -i $(InputName).h -o $(InputDir)\$(InputName).cpp \
|
||||
%qtdir%\bin\moc.exe $(InputDir)\$(InputName).h -o $(InputDir)\moc_$(InputName).cpp \
|
||||
|
||||
|
||||
"$(InputDir)\$(InputName).h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\$(InputName).cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\moc_$(InputName).cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\CrlDetail.ui
|
||||
|
||||
!IF "$(CFG)" == "xca - Win32 Release"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=.\CrlDetail.ui
|
||||
|
||||
BuildCmds= \
|
||||
$(QTDIR)\bin\uic CrlDetail.ui -o CrlDetail.h \
|
||||
$(QTDIR)\bin\uic CrlDetail.ui -i CrlDetail.h -o CrlDetail.cpp \
|
||||
$(QTDIR)\bin\moc CrlDetail.h -o moc_CrlDetail.cpp \
|
||||
|
||||
|
||||
"CrlDetail.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"CrlDetail.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"moc_CrlDetail.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "xca - Win32 Debug"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=.\CrlDetail.ui
|
||||
InputName=CrlDetail
|
||||
|
||||
BuildCmds= \
|
||||
%qtdir%\bin\uic.exe $(InputPath) -o $(InputDir)\$(InputName).h \
|
||||
%qtdir%\bin\uic.exe $(InputPath) -i $(InputName).h -o $(InputDir)\$(InputName).cpp \
|
||||
%qtdir%\bin\moc.exe $(InputDir)\$(InputName).h -o $(InputDir)\moc_$(InputName).cpp \
|
||||
|
||||
|
||||
"$(InputDir)\$(InputName).h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\$(InputName).cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\moc_$(InputName).cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
@ -559,6 +672,27 @@ BuildCmds= \
|
||||
|
||||
!ELSEIF "$(CFG)" == "xca - Win32 Debug"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=.\ExportCert_UI.ui
|
||||
InputName=ExportCert_UI
|
||||
|
||||
BuildCmds= \
|
||||
%qtdir%\bin\uic.exe $(InputPath) -o $(InputDir)\$(InputName).h \
|
||||
%qtdir%\bin\uic.exe $(InputPath) -i $(InputName).h -o $(InputDir)\$(InputName).cpp \
|
||||
%qtdir%\bin\moc.exe $(InputDir)\$(InputName).h -o $(InputDir)\moc_$(InputName).cpp \
|
||||
|
||||
|
||||
"$(InputDir)\$(InputName).h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\$(InputName).cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\moc_$(InputName).cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
@ -615,6 +749,57 @@ BuildCmds= \
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\ExportTinyCA_UI.ui
|
||||
|
||||
!IF "$(CFG)" == "xca - Win32 Release"
|
||||
|
||||
# Begin Custom Build
|
||||
InputPath=.\ExportTinyCA_UI.ui
|
||||
|
||||
BuildCmds= \
|
||||
$(QTDIR)\bin\uic ExportTinyCA_UI.ui -o ExportTinyCA_UI.h \
|
||||
$(QTDIR)\bin\uic ExportTinyCA_UI.ui -i ExportTinyCA_UI.h -o ExportTinyCA_UI.cpp \
|
||||
$(QTDIR)\bin\moc ExportTinyCA_UI.h -o moc_ExportTinyCA_UI.cpp \
|
||||
|
||||
|
||||
"ExportTinyCA_UI.h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"ExportTinyCA_UI.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"moc_ExportTinyCA_UI.cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ELSEIF "$(CFG)" == "xca - Win32 Debug"
|
||||
|
||||
# Begin Custom Build
|
||||
InputDir=.
|
||||
InputPath=.\ExportTinyCA_UI.ui
|
||||
InputName=ExportTinyCA_UI
|
||||
|
||||
BuildCmds= \
|
||||
%qtdir%\bin\uic.exe $(InputPath) -o $(InputDir)\$(InputName).h \
|
||||
%qtdir%\bin\uic.exe $(InputPath) -i $(InputName).h -o $(InputDir)\$(InputName).cpp \
|
||||
%qtdir%\bin\moc.exe $(InputDir)\$(InputName).h -o $(InputDir)\moc_$(InputName).cpp \
|
||||
|
||||
|
||||
"$(InputDir)\$(InputName).h" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\$(InputName).cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
|
||||
"$(InputDir)\moc_$(InputName).cpp" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
|
||||
$(BuildCmds)
|
||||
# End Custom Build
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=KeyDetail.ui
|
||||
|
||||
!IF "$(CFG)" == "xca - Win32 Release"
|
||||
@ -1055,6 +1240,14 @@ SOURCE=.\CertExtend.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\CrlDetail.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\CrlDetail.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\ExportCert_UI.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
@ -1095,6 +1288,14 @@ SOURCE=.\moc_CertExtend.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\moc_CrlDetail.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\lib\moc_db_crl.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=lib\moc_db_key.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
Loading…
Reference in New Issue
Block a user