[openrtm-commit:02458] r680 - in trunk/rtmtools/jp.go.aist.rtm.rtcbuilder: . icons src/jp/go/aist/rtm/rtcbuilder src/jp/go/aist/rtm/rtcbuilder/manager src/jp/go/aist/rtm/rtcbuilder/template/cmake src/jp/go/aist/rtm/rtcbuilder/template/cmake/cmake src/jp/go/aist/rtm/rtcbuilder/template/cmake/doc src/jp/go/aist/rtm/rtcbuilder/template/cmake/idl src/jp/go/aist/rtm/rtcbuilder/template/cmake/include src/jp/go/aist/rtm/rtcbuilder/template/cmake/src
openrtm @ openrtm.org
openrtm @ openrtm.org
2017年 2月 19日 (日) 13:59:13 JST
Author: ga
Date: 2017-02-19 13:59:13 +0900 (Sun, 19 Feb 2017)
New Revision: 680
Added:
trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/icons/rt_middleware_logo.bmp
trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/icons/rt_middleware_logo.ico
Removed:
trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/build.xml
Modified:
trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/Generator.java
trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/manager/CMakeGenerateManager.java
trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/CMakeLists.txt.vsl
trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/cmake/CMakeCMakeLists.txt.vsl
trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/doc/DocCMakeLists.txt.vsl
trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/idl/IdlCMakeLists.txt.vsl
trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/include/IncModuleCMakeLists.txt.vsl
trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/src/SrcCMakeLists.txt.vsl
Log:
Modified generated CMakeFile for CPack #2569
Deleted: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/build.xml
===================================================================
--- trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/build.xml 2017-02-14 06:43:50 UTC (rev 679)
+++ trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/build.xml 2017-02-19 04:59:13 UTC (rev 680)
@@ -1,127 +0,0 @@
-<project name="jp.go.aist.rtm.rtcbuilder" default="jar"
- xmlns:ant4eclipse="antlib:org.ant4eclipse"
- xmlns:antcontrib="antlib:net.sf.antcontrib" >
-
- <property name="target.name" value="jp.go.aist.rtm.rtcbuilder" />
-
- <taskdef name="manifesttask" classname="aist.ManifestTask" />
-
- <property name="source" value="src"/>
-
- <property name="dist.dir" value="jar" />
- <property name="build.dir" value="bin"/>
- <property name="icons.dir" value="icons"/>
- <property name="lib.dir" value="lib"/>
-
- <property environment="env"/>
- <property name="eclipse.home" value="${env.ECLIPSE_HOME}"/>
-<!--
- <taskdef resource="net/sf/ant4eclipse/antlib.xml" />
--->
- <taskdef uri="antlib:net.sf.antcontrib"
- resource="net/sf/antcontrib/antlib.xml" />
- <taskdef uri="antlib:org.ant4eclipse"
- resource="org/ant4eclipse/antlib.xml" />
-
-
- <property name="targetPlatformLocation" value="${eclipse.home}" />
- <property name="workspace" value="${basedir}/.." />
- <property name="project.name" value="jp.go.aist.rtm.rtcbuilder" />
- <tstamp>
- <format property="built.date" pattern="yyyy/MM/dd HH:mm:ss" />
- </tstamp>
-
- <target name="buildAll">
- <antcall target="clean" />
- <antcall target="compile" />
- <antcall target="jar" />
- </target>
-
- <target name="clean" description="ビルドで生成されたファイルを削除します">
- <delete includeEmptyDirs="true" quiet="true">
- <fileset dir="${build.dir}" includes="**/*.class" />
- <fileset dir="." includes="**/*.log" />
- </delete>
- <delete dir="${build.dir}/jp" quiet="true"/>
- <delete dir="${dist.dir}" quiet="true"/>
- </target>
-
- <target name="compile" description="ソースをコンパイルします">
-<!--
- <getEclipseClasspath
- workspace="${workspace}"
- projectname="${project.name}"
- pathid="build.classpath"
- targetplatformlocation="${targetPlatformLocation}"
- />
--->
- <ant4eclipse:targetPlatform id="eclipse-3.8">
- <location dir="${targetPlatformLocation}" />
- </ant4eclipse:targetPlatform>
- <ant4eclipse:jdtClassPathLibrary name="org.eclipse.jdt.junit.JUNIT_CONTAINER/4">
- <fileset dir="${eclipse.home}/plugins/org.junit_4.10.0.v4_10_0_v20120426-0900" />
- </ant4eclipse:jdtClassPathLibrary>
-
- <ant4eclipse:getJdtClassPath
- pathid="build.classpath"
- workspacedirectory="${workspace}"
- projectname="${project.name}" >
- <jdtclasspathcontainerargument key="target.platform" value="eclipse-3.8" />
- </ant4eclipse:getJdtClassPath>
-
- <javac srcdir="${source}" destdir="${build.dir}"
- classpathref="build.classpath" encoding="UTF-8" debug="on" />
- </target>
-
- <target name="jar" description="jarファイルを作成します">
- <copy file="${source}/jp/go/aist/rtm/rtcbuilder/nl/messages.properties" todir="${build.dir}/jp/go/aist/rtm/rtcbuilder/nl" />
- <copy todir="${build.dir}/jp/go/aist/rtm/rtcbuilder">
- <fileset dir="${source}/jp/go/aist/rtm/rtcbuilder">
- <include name="*Help.txt" />
- </fileset>
- </copy>
- <copy todir="${build.dir}/jp/go/aist/rtm/rtcbuilder/model">
- <fileset dir="${source}/jp/go/aist/rtm/rtcbuilder/model">
- <include name="component.ecore" />
- <include name="RTC.genmodel" />
- </fileset>
- </copy>
- <copy todir="${build.dir}/jp/go/aist/rtm/rtcbuilder/template">
- <fileset dir="${source}/jp/go/aist/rtm/rtcbuilder/template">
- <include name="cmake/**/**.vsl" />
- <include name="common/**.vsl" />
- <include name="cpp/**.vsl" />
- </fileset>
- </copy>
- <mkdir dir="${dist.dir}" />
- <delete>
- <fileset dir="${dist.dir}" includes="${target.name}_*.jar" />
- </delete>
- <!-- Version settings -->
- <manifesttask file="META-INF/MANIFEST.MF" key="Bundle-Version" property="manifest.project.version" />
- <condition property="project.version"
- value="${env.PROJECT_VERSION}"
- else="${manifest.project.version}">
- <isset property="env.PROJECT_VERSION" />
- </condition>
- <property name="jar.version" value="_${project.version}"/>
- <property name="jar.name" value="${target.name}${jar.version}"/>
- <!-- Updating MANIFEST.MF -->
- <manifest file="META-INF/MANIFEST.MF" mode="update">
- <attribute name="Bundle-Version" value="${project.version}"/>
- <attribute name="Built-By" value="${user.name}"/>
- <attribute name="Built-Date" value="${built.date}"/>
- </manifest>
- <!-- Creating a jar file -->
- <jar destfile="${dist.dir}/${jar.name}.jar" manifest="META-INF/MANIFEST.MF">
- <fileset dir="${build.dir}" />
- <fileset dir=".">
- <include name="icons/**.**" />
- <include name="lib/**.**" />
- <include name="plugin.xml" />
- <include name="plugin.properties" />
- </fileset>
- </jar>
- </target>
-
-</project>
Added: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/icons/rt_middleware_logo.bmp
===================================================================
(Binary files differ)
Property changes on: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/icons/rt_middleware_logo.bmp
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Added: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/icons/rt_middleware_logo.ico
===================================================================
(Binary files differ)
Property changes on: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/icons/rt_middleware_logo.ico
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/Generator.java
===================================================================
--- trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/Generator.java 2017-02-14 06:43:50 UTC (rev 679)
+++ trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/Generator.java 2017-02-19 04:59:13 UTC (rev 680)
@@ -1,13 +1,17 @@
package jp.go.aist.rtm.rtcbuilder;
import java.io.BufferedWriter;
-import java.io.ByteArrayInputStream;
import java.io.File;
import java.io.FileInputStream;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.OutputStreamWriter;
import java.io.StringReader;
+import java.net.URI;
+import java.net.URL;
+import java.nio.file.Files;
+import java.nio.file.Paths;
+import java.nio.file.StandardCopyOption;
import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.GregorianCalendar;
@@ -565,7 +569,25 @@
idlTarget.create(new FileInputStream(includedIdlFile), true, null);
}
}
+ //
+ //アイコン、ビットマップのコピー
+ copyFigure("icons/rt_middleware_logo.ico", project, "cmake/rt_middleware_logo.ico");
+ copyFigure("icons/rt_middleware_logo.bmp", project, "cmake/rt_middleware_logo.bmp");
}
+
+ private void copyFigure(String source, IProject outputProject, String dist) {
+ try {
+ URL bundleUrl = this.getClass().getClassLoader().getResource(source);
+ URL jarUrl = org.eclipse.core.runtime.FileLocator.toFileURL(bundleUrl);
+ URI uri = URI.create(jarUrl.toString().replace(File.separator, "/"));
+
+ File targetFile = new File(outputProject.getLocation().toOSString(), dist);
+
+ Files.copy(Paths.get(uri), Paths.get(targetFile.toURI()), StandardCopyOption.REPLACE_EXISTING);
+ } catch (IOException e) {
+ e.printStackTrace();
+ }
+ }
private void writeFile(GeneratedResult generatedResult, IProject outputProject,
MergeHandler handler) throws IOException {
@@ -621,11 +643,6 @@
}
}
}
-// try {
-// outputFile.create(new ByteArrayInputStream(generatedResult.getCode().getBytes("UTF-8")), false, null);
-// } catch (CoreException e) {
-// LOGGER.error("Fail to create file", e);
-// }
try {
String strFullPath = outputFile.getLocation().toOSString();
FileOutputStream fos = new FileOutputStream(strFullPath);
Modified: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/manager/CMakeGenerateManager.java
===================================================================
--- trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/manager/CMakeGenerateManager.java 2017-02-14 06:43:50 UTC (rev 679)
+++ trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/manager/CMakeGenerateManager.java 2017-02-19 04:59:13 UTC (rev 680)
@@ -139,7 +139,6 @@
result.add(gr);
gr = generateResourceWixXSL(contextMap);
result.add(gr);
- //TODO アイコン、ビットマップのコピー
//doc
gr = generateDocCMakeLists(contextMap);
Modified: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/CMakeLists.txt.vsl
===================================================================
--- trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/CMakeLists.txt.vsl 2017-02-14 06:43:50 UTC (rev 679)
+++ trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/CMakeLists.txt.vsl 2017-02-19 04:59:13 UTC (rev 680)
@@ -13,14 +13,17 @@
set(PROJECT_AUTHOR "${rtcParam.vender}")
set(PROJECT_AUTHOR_SHORT "${rtcParam.vender}")
+set(PROJECT_MAINTAINER "Noriaki Ando <n-ando at aist.go.jp>")
+set(PROJECT_TYPE "c++/opencv-rtcs")
+
${sharp} Add an "uninstall" target
CONFIGURE_FILE ("${dol}{PROJECT_SOURCE_DIR}/cmake/uninstall_target.cmake.in"
"${dol}{PROJECT_BINARY_DIR}/uninstall_target.cmake" IMMEDIATE @ONLY)
-ADD_CUSTOM_TARGET (uninstall "${dol}{CMAKE_COMMAND}" -P
+ADD_CUSTOM_TARGET (${dol}{PROJECT_NAME}_uninstall "${dol}{CMAKE_COMMAND}" -P
"${dol}{PROJECT_BINARY_DIR}/uninstall_target.cmake")
${sharp}option(BUILD_EXAMPLES "Build and install examples" OFF)
-option(BUILD_DOCUMENTATION "Build the documentation" ON)
+option(BUILD_DOCUMENTATION "Build the documentation" OFF)
${sharp}option(BUILD_TESTS "Build the tests" OFF)
${sharp}option(BUILD_TOOLS "Build the tools" OFF)
option(BUILD_IDL "Build and install idl" ON)
@@ -40,13 +43,13 @@
${sharp} Set up installation directories
-set(BIN_INSTALL_DIR "components/bin")
-set(LIB_INSTALL_DIR "components/lib")
-set(INC_INSTALL_DIR
- "components/include/${dol}{PROJECT_NAME_LOWER}-${dol}{PROJECT_VERSION_MAJOR}")
-set(SHARE_INSTALL_DIR
- "components/share/${dol}{PROJECT_NAME_LOWER}-${dol}{PROJECT_VERSION_MAJOR}")
-
+if(WIN32)
+ set(INSTALL_PREFIX "components/${dol}{PROJECT_TYPE}")
+else(WIN32)
+ set(OPENRTM_SHARE_PREFIX "share/openrtm-${dol}{PROJECT_VERSION_MAJOR}.${dol}{PROJECT_VERSION_MINOR}")
+ set(INSTALL_PREFIX "${dol}{OPENRTM_SHARE_PREFIX}/components/${dol}{PROJECT_TYPE}")
+endif(WIN32)
+
${sharp} Get necessary dependency information
find_package(OpenRTM)
Modified: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/cmake/CMakeCMakeLists.txt.vsl
===================================================================
--- trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/cmake/CMakeCMakeLists.txt.vsl 2017-02-14 06:43:50 UTC (rev 679)
+++ trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/cmake/CMakeCMakeLists.txt.vsl 2017-02-19 04:59:13 UTC (rev 680)
@@ -2,8 +2,6 @@
set(PKG_LIBS -l${dol}{PROJECT_NAME_LOWER})
set(pkg_conf_file ${dol}{CMAKE_CURRENT_BINARY_DIR}/${dol}{PROJECT_NAME_LOWER}.pc)
configure_file(${dol}{PROJECT_NAME_LOWER}.pc.in ${dol}{pkg_conf_file} @ONLY)
-install(FILES ${dol}{pkg_conf_file}
- DESTINATION ${dol}{LIB_INSTALL_DIR}/pkgconfig/ COMPONENT component)
${sharp} Install CMake modules
set(cmake_config ${dol}{CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME_LOWER}-config.cmake)
@@ -14,5 +12,4 @@
configure_file(${dol}{CMAKE_CURRENT_SOURCE_DIR}/${dol}{PROJECT_NAME_LOWER}-config-version.cmake.in
${dol}{cmake_version_config} @ONLY)
set(cmake_mods ${dol}{cmake_config} ${dol}{cmake_version_config})
-install(FILES ${dol}{cmake_mods} DESTINATION ${dol}{SHARE_INSTALL_DIR} COMPONENT library)
Modified: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/doc/DocCMakeLists.txt.vsl
===================================================================
--- trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/doc/DocCMakeLists.txt.vsl 2017-02-14 06:43:50 UTC (rev 679)
+++ trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/doc/DocCMakeLists.txt.vsl 2017-02-19 04:59:13 UTC (rev 680)
@@ -17,7 +17,7 @@
${sharp} Doxygen part
set(doxyfile "${dol}{CMAKE_CURRENT_BINARY_DIR}/doxyfile")
configure_file(doxyfile.in ${dol}{doxyfile})
- add_custom_target(doxygen_doc ${dol}{DOXYGEN_EXECUTABLE} ${dol}{doxyfile})
+ add_custom_target(${dol}{PROJECT_NAME}_doxygen_doc ${dol}{DOXYGEN_EXECUTABLE} ${dol}{doxyfile})
${sharp} Sphinx part
${sharp}set(conf_dir "${dol}{CMAKE_CURRENT_BINARY_DIR}/conf")
Modified: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/idl/IdlCMakeLists.txt.vsl
===================================================================
--- trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/idl/IdlCMakeLists.txt.vsl 2017-02-14 06:43:50 UTC (rev 679)
+++ trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/idl/IdlCMakeLists.txt.vsl 2017-02-19 04:59:13 UTC (rev 680)
@@ -49,7 +49,7 @@
OPENRTM_COMPILE_IDL_FILES(${dol}{idls})
set(ALL_IDL_SRCS ${dol}{ALL_IDL_SRCS} PARENT_SCOPE)
-FILTER_LIST(ALL_IDL_SRCS "hh${dol}" idl_headers)
+FILTER_LIST("${dol}{ALL_IDL_SRCS}" "hh${dol}" idl_headers)
install(FILES ${dol}{idl_headers}
DESTINATION ${dol}{INC_INSTALL_DIR}/${dol}{PROJECT_NAME_LOWER}/idl
COMPONENT headers)
Modified: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/include/IncModuleCMakeLists.txt.vsl
===================================================================
--- trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/include/IncModuleCMakeLists.txt.vsl 2017-02-14 06:43:50 UTC (rev 679)
+++ trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/include/IncModuleCMakeLists.txt.vsl 2017-02-19 04:59:13 UTC (rev 680)
@@ -1,10 +1,5 @@
set(hdrs ${rtcParam.name}.h
- PARENT_SCOPE
#foreach($providerIdlFile in ${rtcParam.providerIdlPathes})
${tmpltHelper.getFilenameNoExt(${providerIdlFile.idlFile})}${tmpltHelper.serviceImplSuffix}.h
#end
)
-
-install(FILES ${dol}{hdrs} DESTINATION ${dol}{INC_INSTALL_DIR}/${dol}{PROJECT_NAME_LOWER}
- COMPONENT library)
-
Modified: trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/src/SrcCMakeLists.txt.vsl
===================================================================
--- trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/src/SrcCMakeLists.txt.vsl 2017-02-14 06:43:50 UTC (rev 679)
+++ trunk/rtmtools/jp.go.aist.rtm.rtcbuilder/src/jp/go/aist/rtm/rtcbuilder/template/cmake/src/SrcCMakeLists.txt.vsl 2017-02-19 04:59:13 UTC (rev 680)
@@ -52,9 +52,6 @@
install(TARGETS ${dol}{PROJECT_NAME} ${dol}{PROJECT_NAME}Comp
EXPORT ${dol}{PROJECT_NAME}
- RUNTIME DESTINATION ${dol}{BIN_INSTALL_DIR} COMPONENT component
- LIBRARY DESTINATION ${dol}{LIB_INSTALL_DIR} COMPONENT component
- ARCHIVE DESTINATION ${dol}{LIB_INSTALL_DIR} COMPONENT component)
-install(EXPORT ${dol}{PROJECT_NAME}
- DESTINATION ${dol}{LIB_INSTALL_DIR}/${dol}{PROJECT_NAME}
- FILE ${dol}{PROJECT_NAME}Depends.cmake)
+ RUNTIME DESTINATION ${dol}{INSTALL_DIR} COMPONENT component
+ LIBRARY DESTINATION ${dol}{INSTALL_DIR} COMPONENT component
+ ARCHIVE DESTINATION ${dol}{INSTALL_DIR} COMPONENT component)
openrtm-commit メーリングリストの案内